• 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.

[Trigger] Teleporting

Status
Not open for further replies.
Level 3
Joined
Apr 23, 2009
Messages
58
Could you people help me out ???

I wanted to have this command " -enter "
And " -out "

So when you enter region number 1 and than type " -enter "
You get to region number 2 and when you type " -out "
You get back to region number 1

NOTE : the " doesn't below in the command

btw its for a portal

Thanks already, if im asking a dumb questions where there is a old version, please give me the link or tell me it, thanks agian already

~Gm Skiller~ :pal:
 
Level 9
Joined
Oct 17, 2007
Messages
547
Just write a trigger using the event Player type msg or something like that. Check for the exact command phrase at the conditions section. As for the actions, just set every unit in that region in a temporary Unit Group, create a temp location at the destination location and move all of them over. Remember to destroy the unit group and the temp location that you created to prevent leaks.
 
Level 28
Joined
Jan 26, 2007
Messages
4,789
I think it's something like this...

  • Teleport
  • Events
    • Player - Player 1 (Red) types a chat message containing -enter as An exact match
  • Conditions
    • ("Region 1" contains (Random unit from (Units in "Region 1" owned by (Triggering player)))) Equal to True
  • Actions
    • Set TempLoc = (Center of "Region 2")
    • Set TempUGroup = (Units in "Region" owned by (Triggering player))
    • Unit Group - Pick every unit in TempUGroup and do (Actions)
      • Loop - Actions
        • Unit - Move (Picked unit) instantly to TempLoc
        • Special Effect - Create a special effect attached to the chest of (Picked unit) using "Your choice"
        • Special Effect - Destroy (Last created special effect)
    • Camera - Pan camera for (Triggering player) to TempLoc over 0.00 seconds
    • Custom script: call RemoveLocation(udg_TempLoc)
That's basically it, the same goes for "-out", just change the regions.
If it doesn't work, it mgiht be the condition, but I think it works :)
 
Level 3
Joined
Apr 23, 2009
Messages
58
Can you help me out somemore ??

im not so good in making variables can you help me out with the TempLoc & the TempUGroup ??

------
And is the special effect needed ??

------
and could you type the Custom script over, but than not in code but just write it ??

------
Btw i have done some triggerin before, srry for not being master add it

~Gm_Skiller~
 
Level 6
Joined
Apr 24, 2008
Messages
174
The special effects are not needed.
The variables he did are made to make sure the spell wont leak.
If you dont do thise variables, the points will remain and leaks/bugs
can apear.

The variables here are "Region" and "Unit Group", the region sets the location
of your in-game region, just to make sure it does not leak. The unit group is
made so all your units in that region gets moved without any problems.
 
Status
Not open for further replies.
Top