Page 1 of 1

Tutorial Help (brush button n)

Posted: Wed Dec 18, 2002 10:31 pm
by Wolfish King
In a tutorial (First Objective) you must build a brush with a trigger.

Then while it is still selected press the n key select trigger_multiple (double click). Give it a key setthread give it a value objective1. (This will trigger our objective within the script as you will soon learn).

Right deselect and place a script_origin near the trigger give it a key $targetname give it a value obj1 (This entity will give the direction for our in game compass for objective direction)

But the key and value will be the same!

Help! :?: :?:

Posted: Thu Dec 19, 2002 4:59 am
by mohaa_rox
The value for the script origin is "obj1". Script it down:

waitthread global/objectives.scr::add_objectives 1 2 "Step on the trigger." $obj1.origin // this will make the compass point to the trigger multiple.

Where may i put this script?

Posted: Thu Dec 19, 2002 12:24 pm
by Wolfish King
Look:

Hello> Key:sdad
Value:ijijij

Bye> Key and value are the same?!

But um where can i put the script?

Posted: Thu Dec 19, 2002 2:32 pm
by mohaa_rox
Put the script in the same folder as your map. If it's SP, put them in the mohaa\main\maps folder. If dm, put them in the mohaa\main\maps\dm folder. If objective, put them in the mohaa\main\maps\obj folder. You also have to edit the script like:

exec global/loadout.scr maps/yourmapname.scr //SP
exec global/loadout.scr maps/dm/yourmapname.scr //dm
exec global/loadout.scr maps/obj/yourmapname.scr //objective

loadout

Posted: Thu Dec 19, 2002 2:55 pm
by tltrude
mohaa_rox - You don't need the loadout lines in a deathmatch or objective script because it is coverd by "exec global/DMprecache.scr". Also, any map in the deathmatch or objective folders will have weapons even if there is no script.

But, you are right about singleplay maps needing a script with that loadout line for the weapons.

-------

ok for the trigger:

Key: setthread
Value: objective1

-------

for the script_origin:

Key: $targetname
Value: obj1

-------

Posted: Thu Dec 19, 2002 3:32 pm
by jv_map
tltrude wrote:But, you are right about singleplay maps needing a script with that loadout line for the weapons.
That's assumption rather than experience or knowledge. The loadout.scr is a stupid script that has a list of all weapons to be loaded for the mohaa single player maps, listed by map name. Thus, it will only work if you use one of the original map names: you'll get the same loadout.

In my opinion it wasn't a smart a decision of the mohaa developers to put the loadout of ALL maps into ONE script, but well, they never used to do very clever things where scripting is concerned.

If you don't use the name of any of the original maps, the call to loadout.scr is completely useless. It's those '$player item <weaponname>' lines that actually give the player weapons.