wrote if thens on z_index for >= to  500 and <= zero