MissionCleanup Problem
by Richard_H · in Torque Game Engine · 11/10/2006 (7:30 pm) · 1 replies
Hi,
for my game I have been experimenting with scripted-ai and all of the sudden part of my script starts complaining about MissionCleanup and think (a function that was already there and working).
Here is what I have:
Any help would be apreciated.
for my game I have been experimenting with scripted-ai and all of the sudden part of my script starts complaining about MissionCleanup and think (a function that was already there and working).
Here is what I have:
function AIPlayer::spawn(%name,%spawnPoint)
{
// Create the demo player object
%player = new AiPlayer() {
dataBlock = TestPlayer;
path = "";
};
echo("Spawned!");
MissionCleanup.add(%player);
%player.setShapeName(%name);
%player.name = %name;
%player.setTransform(%spawnPoint);
%player.think();
return %player;
}This error happened after I moved the spawnpoint the aiplayer spawned at, which seems to be working fine. The only errors are with MissionCleanup and think.Any help would be apreciated.
About the author
Torque Owner Richard_H