Post your scripting questions / solutions here
Moderator: Moderators
7th Es Cyborg
First Lieutenant
Posts: 189 Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:
Post
by 7th Es Cyborg » Fri Jun 20, 2003 6:00 am
Code: Select all
spawn trigger_use "targetname" "my_trigger" "origin" "123 456 789"
how can I set the size of the trigger...
Code: Select all
$my_trigger setsize (0 0 0) (18 18 18)
??? or am i way off here......
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Fri Jun 20, 2003 9:05 am
That is ok but it will make your trigger appear near (0 0 0).
You'll have to move it later.
tltrude
Chuck Norris
Posts: 4774 Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:
Post
by tltrude » Fri Jun 20, 2003 8:48 pm
What would happen if you did this?
Code: Select all
spawn trigger_use "targetname" "my_trigger" "origin" "123 456 789" "scale" "2"
Tom Trude,
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Sat Jun 21, 2003 7:28 am
You cannot scale a trigger since it's not a model.
Maybe you could scale it if it has a size though.
Like:
local.trigger = spawn trigger_use origin (123 456 789)
local.trigger setsize (0 0 0) (18 18 18)
local.trigger scale 2
IvanTheTerrible
Sergeant
Posts: 55 Joined: Thu Jun 26, 2003 7:35 pm
Location: Upland, CA
Post
by IvanTheTerrible » Fri Jun 27, 2003 7:18 pm
Will this message thread help me to add usable weapons to existing MOHAA DM maps using only scripting?
7th Es Cyborg
First Lieutenant
Posts: 189 Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:
Post
by 7th Es Cyborg » Fri Jun 27, 2003 7:56 pm
to add in weapons do this:
local.spawnweapon1 = spawn models/weapons/weapon.tik
local.spawnweapon1.origin = ( xxx.xx xxx.xx xxx.xx ) use coord to find where you want to spawn it
local.spawnweapon1.angle = -90 direction you want it to face
local.spawnweapon1 cnt 1 total times you want the weapon to respawn, if you want it to keep popping back up don't include this line
IvanTheTerrible
Sergeant
Posts: 55 Joined: Thu Jun 26, 2003 7:35 pm
Location: Upland, CA
Post
by IvanTheTerrible » Fri Jun 27, 2003 10:43 pm
Thanks for the info Cyborg, but I need to add a static weapon (Flak88). I need to do this using only scripting. I tried the code as you specified, but the weapon gets added and is not usable. I'm guessing I need to spawn a trigger somehow.
7th Es Cyborg
First Lieutenant
Posts: 189 Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:
Post
by 7th Es Cyborg » Sat Jun 28, 2003 7:17 am
a standard flak88 isn't useable by default, there is a mod floating around some where that will make it useable for multiplayer.
mohaa_rox
Field Marshal
Posts: 2760 Joined: Mon Nov 11, 2002 7:05 am
Contact:
Post
by mohaa_rox » Sat Jun 28, 2003 1:29 pm
this useable flak tut is no more, but ask surg.
Live to map, not map to live.
-mohaa_rox, .map
moderator