Things constantly breaking and fixing itself?

So I am really confused with what is going on with my project, I posted up before about not being able to go up and down through platforms anymore, and no one understood why. It started working again. I built my “ground pound” function and added a loading screen, and everything was working. When loading player or enemies couldn’t move loading would stop and they then could move. My ground pound would get enemies within a certain range they would slowly rise, randomize a rotation, then come falling down. Then, the next day I return to my project, I can no longer fall through platforms again, still execute code the same way firing the same way it did when it worked, my enemies will not move now, look in my loading screen set up, still the same, and my ground pound stop effecting all enemies within range and picks 1 random enemy within range.

In such cases, first thing that programmer learns is it usually you and your code, not compiler or engine.
You made something wrong, you need to fix it.

And best method for fixing bugs is splitting your code into parts then checking each part if they cause errors.
Do not split them (ie. do not unplug execution), just test your code step by step.

Ther are 2 methods of testing blueprints:

  • adding print and printing out values then comparing to what you expect. This is quite bad method because i usually forget to remove those print nodes.
  • second method is using built in visual debugger.

well what I’m talking about never changes and works and one point then doesn’t the next. My platforms for instance, very simple line trace to floor to make sure your hitting a platform and not the bottom of the map, and if holding down and pressing spacebar it disables collision that’s it. pretty hard to mess that up, especially considering I watch the code execute through the blueprints, and watch it fire to no collision THE SAME EXACT PROCESS IT DID BEFORE AND WORKED. all of these things worked before I shut the engine down, so how could it be something in the code if it worked, before it was ever tweaked with? That makes 0 sense.

Believe me there are always ways to mess things up. Some are hard, some so easy that you probably do not even check for that. And that is usually where bugs happily dwell.
For eg, are you sure that when you start game collision is always turned on? It may be so it remembers state of when you ended last game EMULATION in editor. So when you press space it turns if off, when you release it turns it on.
And for finding such stuff debug is best, so on event tick get reference to any platform, get its collision, and print that state. Rule out every possible cause of those bugs one at a time.

Also if your code is good then why all that is not working? Really first step to debug code is admitting that your code may be not so well done.

I’ll admit my code is not well done, when it doesn’t work right, but not when it works right, then doesn’t without anything being changed. I still don’t think you are understanding that, and if collision was turned off period the player would go falling through the map at the beginning of play

The problem is in your code. Check it one more time.:confused:

I have already watched it fire, it fires to turning collision off but doesn’t turn collision thanks, your post was SUPER helpful I never thought to recheck the code

and ONCE AGAIN, this all worked perfectly fine saved shutdown, opened up my project at a later time and all this happened, so it would be impossible for me to break it adding/modifying anything

This conversation is pointless if no one can see the code in question, to see whats wrong.

there is really not much to see for the collision, I have posted before for the collision problems. And no one seems to ever have any ideas. I have said every node in the dropping through platforms, line trace down and player holds down key and presses spacebar collision turns off. Same thing as going up with the only thing being a line trace up and hitting causes turning collision off. I can jump you through it but not down. I have watched the blueprint fire, and it fires to no collision just like my up one, but does not disable my collision.