• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Waygate ?

Status
Not open for further replies.
Level 11
Joined
Jul 28, 2007
Messages
920
Any idea how to make some kind of system like a waygate, or set to waygate to be unable to telemport specific players units, i need for waygate to telemport all units except player 11 and player 12. Waygate has an ability when i click on another side of map hero will automaticly go thru waygate to the other side of map.
 
Level 2
Joined
Apr 8, 2009
Messages
21
Hm, y, when you play melee map, and if you have 2 waygates, each on one side of map, and you click with your army on other side of map, they will go thru waygate, they wont walk to other side.
I think that will help you

  • Waygate
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
    • Actions
      • Set gate1 = *Region1*
      • Set gate2 = *Region2*
      • Set pickedunits = (Picked unit)
      • Unit Group - Pick every unit in (Units in gate1) and do (Unit - Move pickedunits instantly to (Center of gate2))
      • Custom script: call RemoveLocation(udg_gate2_Point)
      • Custom script: call RemoveLocation(udg_gate1_Point)
      • Custom script: DestroyGroup( udg_pickedunits )
gate1 and gate2 are regions and pickedunits is unit
 
Level 18
Joined
Mar 13, 2009
Messages
1,411
Hm, interesting. This is something I would also like to know for my map. I can work a little bit with waygates, but to make a waygate that AND teleports only units for 1 team AND makes units move to it when you click on the other side of the map is something I would not know how to do. :sad: Whoever can help will get at least rep from me.
My map is using a triggered teambased waygate spell, but units won't automatically move to it when it's closer to take the waygate as it is to walk to a spot.
 
Level 2
Joined
Apr 8, 2009
Messages
21
Hm, interesting. This is something I would also like to know for my map. I can work a little bit with waygates, but to make a waygate that AND teleports only units for 1 team AND makes units move to it when you click on the other side of the map is something I would not know how to do. :sad: Whoever can help will get at least rep from me.
My map is using a triggered teambased waygate spell, but units won't automatically move to it when it's closer to take the waygate as it is to walk to a spot.

I saw you're focusing on the clicking,you want when you click on the other side of the map your army to go on the waygate,right? I think you can also do it.For example if the distance between your army and the point that your clicked is bigger than the distance between your army and the gate to move your units to the gate if it's the opposite to go on the point where you've clicked.
 
This may desync, not tested.

  • Actions
    • -------- This allows a certain waygate for players 1-5 --------
    • Set waygate = Way Gate 0000 <gen>
    • Custom script: call WaygateActivate(udg_waygate, false)
    • For each (Integer A) from 1 to 5, do (Actions)
      • Loop - Actions
        • Set player = (Player((Integer A)))
        • Custom script: if GetLocalPlayer() == udg_player then
        • Custom script: call WaygateActivate(udg_waygate, true)
        • Custom script: endif
 
Level 9
Joined
Aug 1, 2008
Messages
453
You could just use a trigger to see if Team 1 owns the units and if they do teleport, and create the effect, and pan camera the units to the other waygate.

  • Waygate
    • Events
      • Unit - A unit comes within 100.00 of Peasant 0000 <gen>
    • Conditions
      • (Owner of (Entering unit)) Equal to Player 1 (Red)
    • Actions
      • Unit - Move (Entering unit) instantly to (Position of Peasant 0001 <gen>)
      • Camera - Pan camera for (Owner of (Entering unit)) to (Position of (Entering unit)) over 2.50 seconds
 
Level 18
Joined
Mar 13, 2009
Messages
1,411
You could just use a trigger to see if Team 1 owns the units and if they do teleport, and create the effect, and pan camera the units to the other waygate.

  • Waygate
    • Events
      • Unit - A unit comes within 100.00 of Peasant 0000 <gen>
    • Conditions
      • (Owner of (Entering unit)) Equal to Player 1 (Red)
    • Actions
      • Unit - Move (Entering unit) instantly to (Position of Peasant 0001 <gen>)
      • Camera - Pan camera for (Owner of (Entering unit)) to (Position of (Entering unit)) over 2.50 seconds
I knew that, but that will not make your units go to the closest waygate instead of moving to the other side of the map.:confused:

This may desync, not tested.

  • Actions
    • -------- This allows a certain waygate for players 1-5 --------
    • Set waygate = Way Gate 0000 <gen>
    • Custom script: call WaygateActivate(udg_waygate, false)
    • For each (Integer A) from 1 to 5, do (Actions)
      • Loop - Actions
        • Set player = (Player((Integer A)))
        • Custom script: if GetLocalPlayer() == udg_player then
        • Custom script: call WaygateActivate(udg_waygate, true)
        • Custom script: endif
I don't get that trigger (not used to the calls, only with leak-removing :sad:).
 
When you place a waygate, and you double click it, you can select which waygate it will teleport to.

That wasn't the OP's question.

I don't get that trigger (not used to the calls, only with leak-removing ).

You don't need to know how it works, just do it.

Theres a chance it may cause a desync, not tested.
 
Level 18
Joined
Mar 13, 2009
Messages
1,411
That wasn't the OP's question.

You don't need to know how it works, just do it.

Theres a chance it may cause a desync, not tested.

Oh, hi there!
There is a guide on how to use those calls, because it makes me interested in them? :D
I wanted to know it, because the Waygate in my map is a bit different from the one needed by the bboy-tiger-, it might however be useful to him.
 
Status
Not open for further replies.
Top