In this lesson we learn about raycasting, which is the process of sending out an invisible beam (« ray ») to check if something is at a certain location or not. We’ll implement a very basic version of a pick up and drop system in the process.
Here is UE4’s official documentation about raycasting/tracing: https://docs.unrealengine.com/en-US/Gameplay/HowTo/UseRaycasts/index.html
HOMEWORK
One simple thing you can try is to have the « placement indicator » we made at the end actually move based on where the player’s reticle is located. Using the same code we used to handle identifying which object we want to pick up, can you make this switch?
Another thing you can try to exercise your class inheritance skills: Make some more pick-uppable and droppable objects using the PickupItem parent class! Maybe even give the PickupItem parent class a Text component which identifies what object it is– you should see all the children classes adopt this same editable text component, too 🙂
NEW TUNES:
Wii Shop Bling: https://www.youtube.com/watch?v=gYOEyzBFYa4&t=0s&list=PLXCYDZvwSZzKTg1NnQ3CKW_C8eiDPlbUZ
Source