- Home /
Inconsistant onTrigger AND button is pressed calls!?
What I want is a system where the player walks next to a box (both have slightly large collides so they can overlap/enter each other) they can press "e" and have it run the diging function (if you look at the code you can probably gather that). My issue is pressing "e" only sometimes works. I press it rapidly like 5 times for it to work once, but sometimes it works every time? Does anyone else have the issue/a fix? Thanks!
Answer by AdityaViaxor · Sep 21, 2018 at 04:19 AM
i guess you code is not so complicated or difficult to solve problem what you really need to do is Debug try and put Debug Everywhere in every function and check what is happening i guess code is not getting some values in if statement.some time it get value sometime it doesnt get value so its happening nothing else try and debug also wanted to tell you that do not simply past big code unnecessarily.
Your answer
Follow this Question
Related Questions
Activate trigger if items colected 1 Answer
Ignore collisions with self but still trigger with self 2 Answers
OnTriggerStay with multiple collision parameters 1 Answer
Multiple triggers/collisions 1 Answer
get only one colliding body 3 Answers