Game Development Community

Bug with exec("./aiPlayer.cs")

by Justin Woods · in Torque Game Engine · 01/14/2006 (12:42 am) · 5 replies

So the relavent my load function in server/scripts/game.cs looks like this:

// Load up all datablocks, objects etc.  This function is called when
   // a server is constructed.
   exec("./audioProfiles.cs");
   exec("./camera.cs");
   exec("./markers.cs"); 
   exec("./triggers.cs"); 
   exec("./inventory.cs");
   exec("./shapeBase.cs");
   exec("./item.cs");
   //exec("./health.cs");
   exec("./staticShape.cs");
   exec("./weapon.cs");
   exec("./radiusDamage.cs");
   //exec("./crossbow.cs");
   exec("./player.cs");
   exec("./chimneyfire.cs");
   exec("./aiPlayer.cs");

For some reason if I comment out that last line about aiPlayer, my game runs fine. However, I need it because I want to use the AIPlayer::Spawn function. So when I take off my comments (as seen above) it crashes my whole game when I try and join a level.

We have had that file commented out for a very long time, but just needed to add it back in (for the NPCDialouge Resource). What are other relavent files I should check for to make sure they weren't deleted?

My aiPlayer.cs is just the stock version that comes with 1.3 (I am using all 1.3 files). My game is fairly along in development, so if you have specific questions just ask.

Need an answer ASAP, please.

#1
01/14/2006 (6:29 am)
Set Trace to true(Trace(1);) before you load the mission, then with Trace on, load the mission, the when it crashes, go check your console log
#2
01/16/2006 (3:11 pm)
Copy all the text from your console.log and post it here.
#3
01/16/2006 (5:59 pm)
I'm sorry guys. One of the other programmers in my group made a change that I didn't know about. That is what lead to this. It's all peachy now. Thanks for offers to help :)
#4
01/16/2006 (8:10 pm)
Let me guess, he executed the aiplayer before the player.cs file? Thats what i did :)
#5
01/16/2006 (8:14 pm)
I hate if I have a particle effect in back of emmiter that makes it angry also.