• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Few Trigger questions

Status
Not open for further replies.
Level 4
Joined
Jul 9, 2005
Messages
49
Ok What I want is to know how to set up a trigger for a Secret code Teleport kind of thing.


For example you stand in a certain region, and type a specific phrase which teleports you to another area. How do I set this up?


Another question. Last time this wasn't solved:

I currently have Humans in my Jurassic park map win condition to reach the safety docks, but no dinosaur condition.

I want it to be.....Dinos kill all humans for victory.

When I tried to set this up I did

Events
A unit owned by player 1 Red dies
....Player 2
....player 3 and so forth till all humans are listed
Condidtions
Triggering unit equal to Survivor
Actions
Humans - Defeat
Dino teams - Victory

but when I tested it, Dinosaurs won when ONE human died.

How do I get it tha player 1-8 has to die so player 9, 10 and 11,12 win?

Last question

I'm using the RDZ Stronghold model which is a great looking gate thats huge. but when you select to build it, the green square that shows the minimum space required is a 1x1 box, which is waaaaayyyy too small for this kind of model. And units can just walk through it defeating the purpose

Also the model is more wide, I would say 6x1 Squares, so I want the green selection thing to match its width. How do I do this? Also is there any way to make it that I can open the gate? my guess is make an ability that makes its collision size 0? But I don't think that can be done.


Help is thanked in advance :)
 

Rui

Rui

Level 41
Joined
Jan 7, 2005
Messages
7,550
For the first one; create 3 triggers. One named Secret Teleport, the other named Active Teleport and the third named Reset Status (or give them a name yourself). The Reset Status and Secret Teleport triggers and initially OFF. Create a Variable which is a player (player) named OwnerOfEnteringUnit, and create another named EnteringUnit, which is a unit (unit).

Active Teleport

Events:
-Unit/Unit enters Region: A unit enters "Region of Secret Teleport"

Conditions:
(Optional)

Actions:
-Set Variable: SetOwnerOfEnteringUnit(variable name) = (Owner of (Entering Unit))
-Set Variable: Set EnteringUnit = (Entering Unit)
-Trigger/Turn On: Turn On Reset Status
-Trigger/Turn On: Secret Teleport
-Trigger/Turn Off: (This trigger)


Secret Teleport

Events:
-Player/Chat Message: OwnerOfEnteringUnit types a chat message containing -teleport as an exact match

Conditions:
(Optional)

Actions:
-Move Unit (Instantly): Instantly move EnteringUnit (variable) to "Secret Area"
-Trigger/Turn On: Turn On Active Teleport
-Trigger/Turn Off: Turn Off Reset Status
-Trigger/Turn Off: Turn Off (this trigger)


There. But the unit, can leave the region, so we must create the Reset Status trigger.

Reset Status

Events:
Unit/Unit leaves region: A unit leaves "Region of Secret Teleport"

Conditions:
Unit Comparison: (Leaving Unit) equal to EnteringUnit (variable)

Actions:
-Set Variable: Set EnteringUnit (variable) = No unit (preset)
-Trigger/Turn On: Turn On Active Teleport
-Trigger/Turn Off: Turn Off Secret Teleport
-Trigger/Turn Off: Turn Off (this trigger)

I hope this helps o_O :wink:

-Rui
 
Level 18
Joined
Mar 7, 2005
Messages
824
for the second question:
change your trigger to this:

EVENT: -a unit dies (generic unit event)

CONDITION: and (multiple conditions)
---> triggering unit is owned by player 1 red of unit-type surviver
---> triggering unit is owned by player 2 blue od unit-type surviver
---> and so on and so on, do this with all of your 8 players the action is your normal one

ACTION: Humans - Defeat
Dinos - Victory


thats all, good luck for your map
 
Level 4
Joined
Jul 9, 2005
Messages
49
Tr!kzZ - What specific condition do I use? I can't find the one that has (Triggering Unit) owned by Player 1 (Red) is Survivor
Which exact condition is it?
EDIT: nevermind got it, it wasn't word to word as you posted, and had to go a bit deep, at least like 5 or 6 screens :p


Rui

Everything I copied exactly, but in the Secret Teleport Trigger, when I try to make the Event I can't set the player as a variable and I can only make it player 1 (red) Player 2 (blue) and so forth. Whats wrong there?
 
Level 6
Joined
Mar 18, 2005
Messages
153
about the teleport thing... is there only 1 unit per player in the map? if not... should all units in the region be teleported or just one? if its just 1 unit u can make a single trigger to solve this. use that entered message as event and boolean comparison to check if the unit is in that area.

as for the survivors...
use integer comparison as condition: use unit-count living units owned by player (u can specify their unittype there too)

as for that door... no idea about those squares at ground. i guess its no doodad? doodad-doors could be opened via trigger and u could also adjust their collisionsize so i suggest using the door as doodad...
 
Level 4
Joined
Jul 9, 2005
Messages
49
The thing for the teleport is...

I want any number of humans OR dinos to be able to enter the secret area.

Meaning for example

One Survivor walks up, types the code and gets teleported to the island.

Now a dino is searching, also types the code and goes to that island.

Get my drift?

I copied Rui's triggers exactly, only adding the text code, I cant set it as a variable.

Can I just go ahead and make it player wise?

12 triggers is heafty but its simplier, or does it HAVE to be OwnerOfEnteringUnit in the event for it to work?
 

Rui

Rui

Level 41
Joined
Jan 7, 2005
Messages
7,550
I copied Rui's triggers exactly, only adding the text code, I cant set it as a variable.

Can I just go ahead and make it player wise?

12 triggers is heafty but its simplier, or does it HAVE to be OwnerOfEnteringUnit in the event for it to work?

I detected the problem. But I can't reach a solution..... maybe you would have to create a trigger for each player's chat message.

Events:
Unit/Unit enters Region: A Unit enters "region of secret teleport"

Conditions:
(optional)

Actions:
If/Then/Else:

If = Boolean Comparison: Entering Unit is in units owned by player 1 (red)
Then = Trigger/Turn On: Turn on Teleport Message for Player 1
Else = Do Nothing

You will have to create one If/Then/Else for each player that can teleport. The "teleport message for player" you already know how to do. Hope that works.

-Rui
 
Level 4
Joined
Jul 9, 2005
Messages
49
Still won't work.

I was thinking only two triggers could do it simply.

Active Teleport1

Events - Unit enters Region Secret1
Conditions(none)
Actions - Trigger - turn on TeleMsg1
Trigger - turn off (this trigger)

TeleMsg1
Events - Unit Enters Region Secret 1
Player 1-12 Chat message contains "phrase here"
Conditions(none)
Actions - Move instantly to SecretA
-Trigger - Turn on Active Teleport1
Trigger - Turn off (this trigger)

won't that work?
 
Status
Not open for further replies.
Top