Object not following player correctly

I tried to make a lighting system in the ui layer, following grazer’s simple lighting example.
it keeps going off screen once the player moves a certain amount.
???
Video
Link

1 Like

Ah.
Here’s what’s happening:
UI position is different than game position. Game position changes relative to the camera, but UI position stays the same.
Basically, the UI doesn’t move with the camera.
To fix this, simply make your lighting an object (non-solid, no collsions) in the game layer and set it to a higher layer than anything else.

1 Like