Game Development Community

Null?

by Neil Marshall · in Torque Game Engine · 08/18/2002 (6:10 pm) · 2 replies

In my game, I apply a ScriptObject to a variable in my player, like so...

%this.team = $TeamRed;

Now, when they leave the team, I want to remove that assignment altogether. I searched all the files for the use of null but the result came up empty. How do I un-assign something like that?

%this.team = "";
%this.team = null;

#1
08/18/2002 (6:19 pm)
why not have something like
-1 = no team
1 = team 1
2 = team 2

then you can set %this.team = -1; and you could should do a little case/if-else etc or what have you.
#2
08/18/2002 (6:42 pm)
Because it holds all of the information that is needed about the team. I'm following http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=2312 as I do this.