Basically my master tile uses a spawn function. It spawns based off 3 arrow positions, one for each lane. I have all of this working already.
It’s very simple in that it has a probability of spawning an obstacle, and when I hit this obstacle of course my character dies. The issue I am having is, and I know it’s happening because I have print strings involved: The obstacles are being spawned in invisibly and killing my player. He will be running on a blank lane and die with the print string after the death function is called, after collision with said obstacle.
When I go into my only spawning function and change it so it’s just powerups/pickups, I don’t die. As soon as I spawn an object in for ONE lane, and I of course stay away from said lane, I will die and get the print string at totally random intervals. I am guesing the weighted function is carrying over to the invisible spawn - what I don’t get is why there are multiple and invisible versions spawning.
For this example I set it as an electricity obstacle that moves back and forth. Again, even if I clear it, it will kill me further down (and not even be there). For death to happen, I have to touch the cube.
Here is the actor BP:
The death function literally just disables input/plays anim/brings up game over.
As for the collission, I have checked the settings right but the issue is that they are all okay, in fact I’m going to upload a quick video of the problem to show it:
Can’t really say anything else from this other than your obstacle might be spawning under the track.
Try this: Add a print node that warns you when an obstacle spawns. Press F8 and pause the game. Look for it in the outliner and see where it spawned. It might have been moved under the track by something that was spawned or was there before spawning.
Another issue might be with the obstable itself and collisions with other actors on the lane, like the coins, but I would try the above first.
So I tried the it spawning in under or around the track but nothing, what do you mean by this part? “Another issue might be with the obstable itself and collisions with other actors on the lane, like the coins, but I would try the above first.”
I checked everything that calls it and was still nothing, and then I FINALLY clocked it and fixed it. Basically my player had a net (a collision box that deleted any actors on contact) behind them called “deleter”. When I unplugged the nodes for the testing, I was dying because I would pass the obstacle fine, but then the NET that was so big it covered everything behind me would touch the obstacle after I passed it and because it was unplugged? It was killing me. I deleted the net and it works fine now. Drove me insane but feel wonderful knowing I at least fixed it.