- Code: Select all
memset(myarray, 0, sizeof(myarray));
This should reset myarray, no matter what dimensions. The problem does not seem to be oriented in dimension, and actually it does set the subs to 0, setting it to null. It seems gameEditor or just some part of my code keeps the chars within the array alive. I found this not using text and strcpy, but I used this to show the problem in a simple setup, meaning it is not due to the text. In this, the actor moves and shows text, which does not make sense knowing how I set it up. For some reason, the char[] maintains its text whilst being NULL, so it is NULL and has text... Is this an error on my part, or is something else happening?