• 🏆 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!

Dummy Units With No Vision

Status
Not open for further replies.
Level 10
Joined
Feb 7, 2005
Messages
409
Hey guys, I recently discovoured that my dummy units won't cast abilities on targets if they do not have vision of it. For example, I made a spell that tracks down an enemy unit on the map, the caster does not have vision of the projectile for this ability (for example, he can only see this projectile if one of his units is close to it) once the projectile hits the enemy unit, it casts an ability on it.

My problem is, if the owner of the casting unit does not have clear vision of the targetted unit, the dummy spell is not casted, thus making the spell useless, since it's supposed to track them and give vision of them, which is uneeded if they're already right beside you... heh.

Does anyone know how I can get the dummy units to cast their abilities without having vision of the area?
 
Level 7
Joined
Jul 18, 2009
Messages
272
Does anyone know how I can get the dummy units to cast their abilities without having vision of the area?
I think that's not possible.

Maybe you can give the projectile to another player with whom you don't share vision, and give the projectile a sight range. (You could give the projectile a dummy ability with 12 levels, and set the level so that you know to which player it belongs.)
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
Though if the dummy unit gets a kill for any reason it will not give the casting player the appropriate gold bounty. What spell is it that you want to cast on the "tracked" unit? Perhaps you could somehow make it an area of effect and then simply use the "tracked" unit's x/y coordinates.
 
Level 10
Joined
Feb 7, 2005
Messages
409
The ability I wish to cast is faerie fire or w.e that one is, the ability that gives vision of the target unit for a short time. The goal of the ability is to cast the projectile, the projectile hunts a target, then if the projectile hits the target the caster gets vision of said target for 5 seconds.

In this instance the dummy unit NEEDS to be owned by the caster, as the dummy ability will only grant vision to the owner of the dummy unit.

This isn't the only ability that's causing this.

I have another ability that fires a ball with infinite range, the ball will continue to travel untill it makes contact with an enemy. Upon contact, it will stun the target it collides with. Since the caster doesn't have vision of said ball, the dummy unit won't stun the target.

I have other abilities as well where this is happening.
 
Level 8
Joined
Apr 30, 2009
Messages
338
when it gets in contact with an eligible target, create another dummy that gives vision in a small aoe with like 0.25 second timed life, and make sure the cast point and backswing of the unit that casts faerie fire is set to 0.
 
Level 10
Joined
Feb 7, 2005
Messages
409
Pharaoh in this case, the missile is also a dummy unit. The ability itself is a self instant cast with no target that produces a dummy unit with no vision, this dummy unit is then ordered to move to the location of the enemy unit. Upon reaching the enemy unit, the dummy unit casts faerie fire. The dummy unit is owned by the caster of the self instant cast so when faerie fire is casted, the caster gets sight of the target. However the dilemma occurs when the caster does not have vision of the target, as the dummy unit will not cast.

If a dummy is created for the target and casts faerie fire on the target, by nature of faerie fire it will grant vision of the target to the target, not the caster of the instant self cast.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
Why don't you try converting the target unit to match the player of the caster. Then, apply the Faerie Fire buff (the targets will need to be adjusted to include Friendly units) to the recently allied unit. Once it has been applied, convert the unit back to the enemy player.

I don't know if this works, I'm going to test it out myself and get back to you.

No, that doesn't work. I forgot that it takes time for the Fog of War to fadeout before a unit can be casted on.

I'm running out of options, but there is always the option of just applying some random buff to the unit (in some other manner) and then triggering the visibility using fog modifiers.

Oh, I got it to work. Nice.

Basically, use a different dummy-unit with 400 sight (300 doesn't seem to work) and create it on top of the "tracked" unit. Make sure that your dummy unit caster has the faerie fire ability and simply order the dummy to cast "faeriefire" on the tracked unit. Then immediately remove the unit. Make sure your dummy-caster's cast backswing 'n such is set to 0.00.

It seems that having a 400-sight-radius will be an instant enough visibility modification for the dummy unit to be able to cast on the desired target. Good thing, too.

Here's an attached map with what you need. If you want to test it, type "fire" in-game to faerie fire a random enemy (none of the map is visible to begin with).
 

Attachments

  • FaerieFireDummy.w3x
    13.5 KB · Views: 38
Last edited:
Level 10
Joined
Jul 12, 2009
Messages
318
Does anyone know how I can get the dummy units to cast their abilities without having vision of the area?
It's simple:

  • [...]
    • Unit - Grant shared vision of Target to (Owner of Dummy)
    • Unit - Order Dummy to <<<Cast spell>>> Target
    • Unit - Deny shared vision of Target to (Owner of Dummy)
This will allow the dummy to cast, yet will not reveal the target unit nor any map around it to the casting player.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
Weep said:
This will allow the dummy to cast, yet will not reveal the target unit nor any map around it to the casting player.

This works. I was actually looking for this function but for some reason I couldn't find it --I hate it when that happens. This works too.

MortAr- said:
Um.. just make a dummy that cast 'Faerie Fire' onto the target, 'cause the buff gives vision over the target.

Obviously you haven't tried it, because if you go into my test-map and give the dummy 0 vision it won't work.
 
Level 10
Joined
Feb 7, 2005
Messages
409
Aha! thank you very much for your collective input, this will be very useful to my future endeavors. I'll try out both ways, prolly starting with weeps as the coding and editing seems smaller, and see which one works the best according to my needs.

Thanks everyone, I'll edit this post later with my results.

Edit: Ha hey! it worked! thanks again guys
 
Last edited:
Status
Not open for further replies.
Top