Game Development Community

some dude help me ? (rookie need somehelp )

by qiubowei · in Torque Game Builder · 08/04/2010 (2:32 pm) · 4 replies

I start to study TGB for a few days,still a rookie.

thx if u can help

i get a problem while im testing my project,here is it:

i create a obj named 'A'(use the level builder) in sceneA.t2d
then i load another scene SceneB.t2d,i want to use the obj'A' in
it,but seems it automatically deleted .

so,how can i use the same obj (created by level builder)in different scene?


#1
08/04/2010 (2:39 pm)
Try changing the scenegraph in code:
objA.scenegraph=sceneB; //you have to use the correct name for it to work

This also assumes you have an event coded where this change will happen and make sense.
#2
08/04/2010 (2:50 pm)
Ok doood, here goes:

->Click on the object
->On the right hand side, under 'Edit' select 'Scripting'
->Select the the checkbox 'Persist'
->Tada!
#3
08/04/2010 (2:58 pm)
thx doood ! it works

but... unfortunately the behavior i used on the 'A' doesnt work when i check'persist' why??
#4
08/05/2010 (5:39 am)
maybe that behaviour depends on objects which are not created in other levels...just a guess