Particle emitter crash on game start
by Ronald J Nelson · in Torque Game Engine Advanced · 12/25/2007 (1:24 pm) · 8 replies
This is probably not a bug, but it it happens everytime I try to load my game. I recently converted from TGE 1.5.2 to TGEA and am still working out the bugs.
This is the message I keep getting:
particleemitter.cpp @ 605) Error, could not find ClientMissionCleanup group
Can someone tell me why I am getting this?
This is the message I keep getting:
particleemitter.cpp @ 605) Error, could not find ClientMissionCleanup group
Can someone tell me why I am getting this?
#2
12/25/2007 (2:53 pm)
No I have always added to the old MissionCleanup as far as I know. I never had this problem before my port to TGEA, so I have no idea why it would do it now. Also, I tested the game by just using the original TGEA executable that came precompiled, it does not give me this error. I have gone over my code numerous times and I am beginning to think that the changes to the particle system must have been more extreme than just converting the stuff in code.
#3
12/25/2007 (5:57 pm)
Don't quote me on this, but as far as I remember the engine tries to add each emitter to the Mission Cleanup group inside it's onAdd () function or possibly onNewDatablock (). The line suggested in your message should lead you to where it is, obviously.
#4
12/25/2007 (9:20 pm)
Well I have tried something I saw in another section in regards to a similar which was commenting out the error code. It actually works, but I have no idea why it is having the problem in the first place.
#5
First off the ClientMissionCleanup is created in:
That is what is not happening. But is wierd is that the function that calls the client command is working. It is the following:
So now I am stumped. Why is it crashing before the client command can be called to create that which it crashes for? It seems something is out of sequence.
12/26/2007 (1:21 am)
OK I used a bunch of echos to track down in script where the problem is.First off the ClientMissionCleanup is created in:
function clientCmdMissionStart(%seq)
{
// The client recieves a mission start right before
// being dropped into the game.
new SimGroup( ClientMissionCleanup );
}That is what is not happening. But is wierd is that the function that calls the client command is working. It is the following:
function GameConnection::startMission(%this)
{
// Inform the client the mission starting
commandToClient(%this, 'MissionStart', Server.mission_Sequence);
}This function is being called and since clientCmdMissionStart is doing anything with %seq which was Server.mission_Sequence, it should not even matter what that was. I also did a check to see if the %client ID was correct, it was. So now I am stumped. Why is it crashing before the client command can be called to create that which it crashes for? It seems something is out of sequence.
#6
12/26/2007 (4:30 pm)
I found the problem. Now maybe one of you can tell me why the tire emitters don't work any more?
#7
I posted this as a bug too.
http://www.garagegames.com/mg/forums/result.thread.php?qt=67855
For me it happens when I add an object to the mission file that contains particle emitters. In my case it was a vehicle with tires that had particle emitters. And then it only happened with a debug build.
My theory is that the ClientMissionCleanup group does not exist yet, the first time ParticleEmitter::onAdd() is called in this case.
I just commented out the code causing the error in ParticleEmitter::onAdd().
If you are really determined to find the answer, you might try having clientCmdMissionStart() call a Console Function so you can catch a breakpoint on the engine side. And then set a breakpoint on ParticleEmitter::onAdd() and see which breakpoint hits first.
12/26/2007 (4:33 pm)
Ron,I posted this as a bug too.
http://www.garagegames.com/mg/forums/result.thread.php?qt=67855
For me it happens when I add an object to the mission file that contains particle emitters. In my case it was a vehicle with tires that had particle emitters. And then it only happened with a debug build.
My theory is that the ClientMissionCleanup group does not exist yet, the first time ParticleEmitter::onAdd() is called in this case.
I just commented out the code causing the error in ParticleEmitter::onAdd().
If you are really determined to find the answer, you might try having clientCmdMissionStart() call a Console Function so you can catch a breakpoint on the engine side. And then set a breakpoint on ParticleEmitter::onAdd() and see which breakpoint hits first.
#8
12/26/2007 (4:57 pm)
Thanks Mary. I didn't realize this was only happening in DEBUG mode. You fix is fine by me so it works now. Thanks again.
Torque Owner Shaderman