Hello everybody. I just started off with UE4 and gamedesign in general, so pls don’t blame me for my inexperience
I followed Romeros Blueprint Tut blog in order to get started and after finishing the simple blueprint game where you collect statues, I noticed that the game is generating 2 overlap events when walking into a statue.
These are my blueprints:
It is always creating 2 overlap events and therefor it doubles the amount that is added to variables ‘Score’, ‘StatueCollected’ etc.
I tried to fix this by using a triggerbox around the statue to trigger the overlap event → problem persisted, I deleted it. Then I toggled the ‘generate overlap event’ variable as you can see here:
→ problem persisted, deleted it. After that I set a ‘destroy actor’ node, just to see if it still does 2 overlap events:
and voilá, it only does it once. But, of course, this doesn’t solve the problem, because the actor is no longer available.
Does anybody have an idea how to fix this?
Big thanks, CCrunch
Got a workaround now. I connected ‘InitStatue’ function to an ‘EndOverlap’ event and added 2 ‘Set Actor Hidden in Game’ nodes, because I want the statues to disappear at the time you step into it. It works as expected, but I still want to understand why it didn’t work the other way.
Are you checking overlap with statue’s static mesh collision or only some primitive like capsule? Sometimes people add static mesh with collision and then extra collision object and don’t switch off overlap events on static mesh.
Checking this only with statue’s static mesh collision. I will try to use a primitive to check for overlap condition and report back.
I disconnected the ‘Set Actor Hidden in Game’ nodes, deactivated the ‘Generates Overlap Events’ var of SM_Statue and added a capsule to the statue for overlapcheck:
Still the same. 2 overlap events when walking into the statue.
What about your character? Single capsule and no overlap events on skeletal mesh?
I had a conversation with Marcos Romeros, who created the tutorial and it turns out to be an issue that has something to do with the ‘Set Actor Location’ function in UE 4.10. He experienced the same and solved it by using DoOnce and Delay nodes.