The Lost Egg - Interacting with Items

Throughout the game, the player is required to interact with certain items like mushrooms, the parent's corpses, and the sister's skull.

One way to do this would be to constantly check the distance from the player to the item and display on the UI if the player is close enough to interact. However, this could eventually cause a lot of lag on some devices because there are calculations happening every frame. Instead, interactable items have a trigger around them and set a Boolean to true, and display the control for interacting with an item on the screen when the player walks into the trigger.



3 views0 comments

Recent Posts

See All