Page 1 of 1

Trigger and Script Question?

Posted: Thu Oct 16, 2003 2:41 pm
by MillesManson
Hi all,
my english isn?t very good so i hope someone understands me.

I have a part of script which starts by a trigger in my map.
It is a multiple-trigger with the entity setthread OpenShutters.

The Sript part is this one :

OpenShutters:

$stall open $mg42_gunner
$stall delete
//$stall notsolid
$shutters_open show
$mg42 show
$mg42a show
//$mg42_gunner exec global/enable_ai.scr
$mg42_gunner show

end

The trigger and script work fine.
I want that the trigger will not be active when i walk trough,but
when i have entered a jeep an the jeep is driving through the trigger.
For the jeep i have this script:

jeep_enter:
$pilot lookat NULL
$jeep2 thread player_turret
$mission1_ende triggerable
wait 2

$jeep2 drive jeep2_path2 200 60 40 128
wait 2

thread lastsoldiers

$jeep2 waittill movedone
$jeep2 waittill movedone
$jeep2 waittill movedone
thread jeep_end
end

This script also work correct, but the problem is that the trigger gets active when i walk through befor i have entered the jeep.

Do i need an other Trigger for that, or can i activate the trigger in the jeep script, so that the "OpenShutters- scrpitpart" don?t start before when i walk trough?

Thx everybody for help!
Greetz Milles

Posted: Thu Oct 16, 2003 3:12 pm
by jv_map
Use nottriggerable and triggerable commands to turn your trigger 'on' at the right time.

Example:

At map startup -> $[triggername] nottriggerable
(you can also add this as a key without value in Radiant)

When the jeep is entered -> $[triggername] triggerable

Good luck :)

Posted: Thu Oct 16, 2003 3:28 pm
by williewisp
you cud use another trigger, and put it in the jeep.

give the trigger in the game a targetname
targetname shutters (or whatever you want / this is the trigger for the shutters

using the trigger in the jeep. have it
setthread activte_trigger

top of script or somewhere in it
$shutters nottriggerable

the thread called from the trigger in the jeep
activte_trigger:
$shutters triggerable
end

there is prob an easier way?

Posted: Thu Oct 16, 2003 3:56 pm
by MillesManson
Wow i like this forum,
fast help!

Thx jv_map it?s working!

Greetz Milles