• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

On selecting units...

Status
Not open for further replies.
Level 4
Joined
Aug 17, 2011
Messages
119
I want to make certain of a computer controlled players units selectable to ally players in game and allow these players to activate (cast at target area) a single ability of the selected unit.

Player 9 is my base defenders, the base has catapults that fire randomly into regions every 10 seconds. I want the other hero's (player 1 - 6) to be able to select one of player 9's catapults and have it fire a single shot at a target area.

How would you do this?
 
Level 4
Joined
Aug 17, 2011
Messages
119
nope, multiple shots by multiple different players. ability cool-down of 20s to prevent spamming.

"single shot" refers to the ability. (heavy damage, area effect, maybe fire.. blabla..)
 
Level 12
Joined
Sep 11, 2011
Messages
1,176
the only way i could think is to create the catapult for player 10 or any player that is not used, change the color of the catapult to player 9's color (gray) and then share the unit to all the players.

something like this.

  • Untitled Trigger 002
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set tempPoint = (Center of (Playable map area))
      • Unit - Create 1 Siege Engine for Player 10 (Light Blue) at tempPoint facing Default building facing degrees
      • Unit - Change color of (Triggering unit) to Gray
      • For each (Integer A) from 1 to 6, do (Actions)
        • Loop - Actions
          • Player - Make Player 10 (Light Blue) treat (Player((Integer A))) as an Ally with shared vision and full shared units
          • Player - Make (Player((Integer A))) treat Player 10 (Light Blue) as an Ally with shared vision and full shared units
      • Custom script: call RemoveLocation (udg_tempPoint)
 
Status
Not open for further replies.
Top