Tutorial Help (brush button n)

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

Post Reply
Wolfish King

Tutorial Help (brush button n)

Post 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! :?: :?:
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Post 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.
User avatar
Wolfish King
Corporal
Posts: 48
Joined: Wed Dec 18, 2002 10:43 pm
Location: The Netherlands

Where may i put this script?

Post by Wolfish King »

Look:

Hello> Key:sdad
Value:ijijij

Bye> Key and value are the same?!

But um where can i put the script?
Wolfish King is th@ Master!
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Post 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
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

loadout

Post 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

-------
Tom Trude,

Image
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post 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.
Image
Post Reply