Is it possible to have triggers aimed at only one team?

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

Moderator: Moderators

Post Reply
User avatar
Axion
Major General
Posts: 683
Joined: Mon Sep 29, 2003 5:14 am
Location: Northern California
Contact:

Is it possible to have triggers aimed at only one team?

Post by Axion »

For instance, would I be able to make a trigger that causes damage to just Axis players?
"The work of a thousand years is nothing but rubble."
- Dr. Carl Goerdeler (1943)
Visit my mapping site: http://www.freewebs.com/axion9
Image
crunch
Major
Posts: 348
Joined: Sat Jun 14, 2003 2:34 pm
Location: USA
Contact:

Post by crunch »

Yes, it is.
It would need to be scripted.

name_of_your_thread:

local.player = parm.other
if (local.player.dmteam != "allies")
{
self nottriggerable
Do something
}
wait X
self triggerable

end


In this scenario, the trigger would fire if an Axis touched/used/shot it.
( != is "does not equal") so != "allies" is axis.

Of course, your trigger would have setthread/name_of_your_thread
Image
User avatar
Axion
Major General
Posts: 683
Joined: Mon Sep 29, 2003 5:14 am
Location: Northern California
Contact:

Post by Axion »

Awesome, thanks for the help. Now, one more question- Would it be possible to spawn said trigger through scripting in a stock map?
"The work of a thousand years is nothing but rubble."
- Dr. Carl Goerdeler (1943)
Visit my mapping site: http://www.freewebs.com/axion9
Image
User avatar
diego
Captain
Posts: 245
Joined: Sun Dec 21, 2003 10:47 pm

Post by diego »

Hey, Great Idea! But can you take it further?

I'd like set up a trigger that only affects players with a specific weapon --- The Shottie.

As a joke, I want to make a small area of my map that is kind of like a "Shottie Free" zone. Anyone going in that area with one will have something bad happen.
Diego
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Axion wrote:Awesome, thanks for the help. Now, one more question- Would it be possible to spawn said trigger through scripting in a stock map?

Code: Select all

// Create the trigger
local.trigger = spawn trigger_multiple "setthread" "name_of_your_thread"
// Set where it should be
local.trigger.origin = ( 0.0 100.0 0.0 )
// Set the size of it
local.trigger setsize ( -50 -50 -50 ) ( 50 50 50 )
Admin .MAP Forums
Image
Head above heels.
User avatar
Axion
Major General
Posts: 683
Joined: Mon Sep 29, 2003 5:14 am
Location: Northern California
Contact:

Post by Axion »

You guys are fantastic! :D
"The work of a thousand years is nothing but rubble."
- Dr. Carl Goerdeler (1943)
Visit my mapping site: http://www.freewebs.com/axion9
Image
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Axion wrote:You guys are fantastic! :D
And as if that was not enough: were good looking as well ;)

Just kidding, glad to help.
Admin .MAP Forums
Image
Head above heels.
User avatar
Axion
Major General
Posts: 683
Joined: Mon Sep 29, 2003 5:14 am
Location: Northern California
Contact:

Post by Axion »

Hahahaha!

I kinda walked right into that one, I suppose...
"The work of a thousand years is nothing but rubble."
- Dr. Carl Goerdeler (1943)
Visit my mapping site: http://www.freewebs.com/axion9
Image
Post Reply