I'm making dust2 for custom zombies WAW. I had no problem with it and I'm so close to finish it but now I have a problem. I had error called "G_spawn no free entities" it means something like I have lots of things in my map, so I removed some. Now when I want to try my map it is always stuck in activision screen after logo activison it stays black I don't know how to fix it. Anyone who has experience with moding and fixing erros please help me. Anyone who helps me I will add your name on the board in the map. Here is my map how it is going, please I'm asking for help to continue. http://steamcommunity.com/app/10090/discussions/0/133261907138187333/
Your issue is most likely that you removed script entities but you didn't disable the scripts using them. Because the script doesn't find these entities, it will cause a small freeze (infinite loop error). You probably have them so much that the game is unable to remove the threads which causes the crash.
You have to go through your scripts and remove/modify all the functions that refer to the deleted entities
Your issue is most likely that you removed script entities but you didn't disable the scripts using them. Because the script doesn't find these entities, it will cause a small freeze (infinite loop error). You probably have them so much that the game is unable to remove the threads which causes the crash.
You have to go through your scripts and remove/modify all the functions that refer to the deleted entities
yes still I need help. Maybe you are right but I don't know how to fix it .
yes still I need help. Maybe you are right but I don't know how to fix it .
This is how you define an entity in script.
Code Snippet
Plaintext
entity = GetEnt("NameOfTargetname","targetname");
And then you could have something like
Code Snippet
Plaintext
while(1) { //entity does something
Basically the game causes this infinite loop error because the entity you have defined is not found since you have deleted it. So it is trying to do things on an entity that doesn't exist. The game solves this by removing the thread, which is seen as a small freeze in game.
The issue what you're having is caused by these. The game is trying to remove the multiple issues with these models that can't be found. This results in the game crashing.
Solution is to modify/delete these lines of code from the scripts.
Basically the game causes this infinite loop error because the entity you have defined is not found since you have deleted it. So it is trying to do things on an entity that doesn't exist. The game solves this by removing the thread, which is seen as a small freeze in game.
The issue what you're having is caused by these. The game is trying to remove the multiple issues with these models that can't be found. This results in the game crashing.
Solution is to modify/delete these lines of code from the scripts.
You don't put these anywhere. This was just an example of what can cause this error. You have to check if your own scripts have these definitions. Then you have to check if you have your defined entity in your map file (in radiant). If it doesn't exist in radiant, you either have to make the desired entity or modify/delete the lines of code that use this entity in your script. Post the script here if you can't figure it out.
I did it and it sayd this: Error, script runtime error ( see console for detials ) undefined is not a feild object
You can open the console then, and it will state the full error and the script it's located in. You prob need to fix a shitload of smaller error's before you get to the actual problem though..
Quote
You don't put these anywhere. This was just an example of what can cause this error. You have to check if your own scripts have these definitions. Then you have to check if you have your defined entity in your map file (in radiant). If it doesn't exist in radiant, you either have to make the desired entity or modify/delete the lines of code that use this entity in your script. Post the script here if you can't figure it out.
tbh, and undefined ent hardly ever gives an infinite loop. It can cause problems ofc, for example because the ent is undefined and checking against something undefined will Always return true. But infinite loops are pretty much Always loops without a wait statement.
To the OP: do you have a lot of custom scripts in your map? What you could do is create a new map with a script placer, and then save your dust2.map over it so it's using 100% stock scripts. Then try to load it, and if it works add your custom scripts one by one till you find the one causing problems.. If your not really into scripting that might be easier then going through all the developer-errors to fix them.
You can open the console then, and it will state the full error and the script it's located in. You prob need to fix a shitload of smaller error's before you get to the actual problem though..
tbh, and undefined ent hardly ever gives an infinite loop. It can cause problems ofc, for example because the ent is undefined and checking against something undefined will Always return true. But infinite loops are pretty much Always loops without a wait statement.
To the OP: do you have a lot of custom scripts in your map? What you could do is create a new map with a script placer, and then save your dust2.map over it so it's using 100% stock scripts. Then try to load it, and if it works add your custom scripts one by one till you find the one causing problems.. If your not really into scripting that might be easier then going through all the developer-errors to fix them.