Game Development Community

CLOSE

by Tim Tebow · in Torque Game Builder · 10/05/2008 (11:54 am) · 4 replies

--

#1
10/05/2008 (12:11 pm)
You can add behaviors like this:

_behavior0 = "NameOfTheBehavior Field1 Value1 ... FieldN ValueN";
_behavior1 = "NameOfTheBehavior Field1 Value1 ... FieldN ValueN";
.
.
.

Everything between the quotes needs to be TAB separated.
#2
10/05/2008 (1:59 pm)
So just to make sure( I am going to try it here in a bit getting ready to take off) but I put that inside the

new t2dStaticSprite() {

or inside a data block.
#3
10/05/2008 (2:17 pm)
Yeah inside the braces, look at your .t2d level file and find an object that you added a behavior too via the editor. It looks just like he posted.


Another way is to do this.

%obj = new t2dStaticSprite()
{
...
};

%beh = BehaviorTemplatename.createInstance();
%beh.fields = what you want;
...

%obj.addBehavior( %beh );
#4
10/05/2008 (2:19 pm)
Ok Ill give that a try, thanks alot



I think im on your favorite list....Or your a stalker ;)