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

Ignore Orders or Disable Single Unit

Status
Not open for further replies.
Level 3
Joined
May 3, 2008
Messages
44
So here's my problem:

I'm making a map, where a few super powerful units enter the map, then use regions to navigate a path through the map and attack anything within 400 distance of them. THAT works, but it would be very unbalanced if a player could get the unit off of its set path.

I've already got a trigger that clears the selection of the unit if it's selected, but if you drag select it and quickly click you have enough time to issue an order, thus getting them off of their paths and keeping them in the game. I've thought about testing to determine exactly how long the unit needs to travel its path and then set an expiration timer on it, but that just doesnt seem as realistic as I'd like.

The units can't be computer controlled, because their job is to kill creeps - generating money for the player. Unless you can transfer a bounty from a computer controlled player to the player who triggered the spawn of the units I dont see this as a solution

So I guess my question is: Can I disable control of a single unit when it enters the map, because the only other option I see is disabling the player's control while the units are on the map; which puts that player at a big disadvantage.
 
Level 17
Joined
Apr 13, 2008
Messages
1,608
Edit: Oops, sorry, I skipped a sentence in your post and wrote redundant stuff (past bedtime here).

Okay, I don't know about any way to disable the player's controls over a unit, there might be, I didn't search, but:
Why don't you issue the unit's original orders again after deselecting it?

If you tried this and still not working then give your killing-machine to the computer and generate a fake bounty what you give to the player according to the unit it killed.
 
Last edited:
Level 3
Joined
May 3, 2008
Messages
44
Hmm, well if that's the case I guess I'll just see what happens when I release it to beta testing.

and the super-creep-killing-money-making-route is just an airstrike of stealth bombers, I just didnt want them making the bombers like hover over the creep spawn and not leave lol. If worse comes to worse I'll just add an expiration timer
 
Level 17
Joined
Apr 13, 2008
Messages
1,608
Meh, I have spent half an hour looking for a function to disable user control over a single unit or to get a unit's bounty, but I couldn't find any.

By the way, I forgot to mention if you make a trigger based on the event - "unit is issued an order", you have to pause your unit, wait 0.01 sec, unpause it and issue the new orders afterwards.
If you just issue an order without waiting a little, it won't work.
 
Level 11
Joined
Aug 25, 2006
Messages
971
Ok, I would give the units to a computer. Then for each kill the units get, give the bounty to the player. To determine the bounty, simple spawn a unit, spawn another (dummy unit). Use the dummy unit to instantly kill the spawned unit, measure the gold increase.
 
Status
Not open for further replies.
Top