Hi all! I’m currently working on a project to try and better get to grips with blueprint scripting, but I’ve hit a wall as of late.
I currently have a system in place within my project where a box trace emitting from the player character searches for actors I’ve flagged as pick up-able items, the player can then pick up these items and throw them, or put them down on the floor. This part works fine, below is the scripting for this mechanic.
What I want to do now is have the same box trace also search for a different set of actors flagged as pushable (Think how you can push and drag furniture in Animal Crossing) I initially tried to add on code to the branch at the end, the code was essentially a repeat of the same code for Pick Up-able items, but with a Cast to the Blueprint Class for Pushable items and other references changed to an equivalent for pushable items, however, this did not work.
My second attempt involved creating a separate line trace to just search for pushable items, but that didn’t work either as I couldn’t work out how to make an event tick go to multiple traces. I also don’t like this idea as ideally, I want to keep all the searching to a single box trace, as I think I feel it would make things simpler.
If anyone has any suggestions as to what I should do it would be greatly appreciated, I’m really stuck on this and really want it to work out. If any further elaboration is needed on anything I’ll be glad to provide it, thanks!