Thoughts on Interfaces

Currently I wonder what the best practice for “regular interaction” might be.
Let’s say we have a loot chest, an NPC or a lever.

My assumption would be to put those objects on an “interactable” or “world” Layer and create an Interface “IInteractable” with an “Interact()” Method so when the player clicks on the Object it fires the method. Perhaps the player should be in an appropriate radius?

Any ideas?

Privacy & Terms