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

[JASS/AI] An Attack (Missile type) that does not generate alerts to the enemy. (Tutorial still in testing )

Level 7
Joined
Mar 14, 2021
Messages
43
I am posting this test map of a method that surely many found but took it as an error (as I did), so it is really known. Most projectile systems are based on immediate normal type attacks that with damage systems, you can make this damage captured from the attack to 0, but it cannot prevent the enemy unit from reacting to this damage alert event (for example, that generates an alert noise, alert ping, flee, etc). The idea is that this does not happen and simply when the fictional missile of a projectile system is the one that does this. So I do this topic to expand a little more the topic of the concept of attacks and alerts.

The method:
barrage.gif


It is simply based on the Barrage ability, which you can use on a unit that has a missile-type attack. The Barrage ability will only take effect on one unit, and this will be the same unit that attacks (Self). Using a damage system like Bribe's, you can see that the attacking unit takes the damage from the Barrage ability first, and then the damage to the attacked unit. If the missile of the attacking unit its impact speed is 0, in the same way this happens, Barrage will always hit the attacking unit first.

Barrage Data.jpg


So with this concept, one can try the following examples, if the unit that is attacked dodges the attack? This is what happens, the Barrage deals damage to the attacker unit, and then the launched missile is dodged by the attacked unit. At this point you will realize that you have a way of knowing when a missile attack is about to be launched through a damage system. (Thing that I did not see that it could, well now it can).

The use that can be given ... For example.

- How to generate that the attack does not give alerts of damage to an enemy. We know that the attack generated by Barrage is first, using a Damage system for example Damage Engine (by Bribe), we can do the following, we capture the damage of the missile by Barrage then we use this.
JASS:
call SetPlayerAlliance (GetOwningPlayer (atker), GetOwningPlayer (atked), ALLIANCE_PASSIVE, true)        
call SetPlayerAlliance (GetOwningPlayer (atked), GetOwningPlayer (atker), ALLIANCE_PASSIVE, true)
- Sure if it's an enemy. Then when our missile hits the attacked unit we just do the opposite.
JASS:
call SetPlayerAlliance (GetOwningPlayer (atker), GetOwningPlayer (atked), ALLIANCE_PASSIVE, false)
call SetPlayerAlliance (GetOwningPlayer (atked), GetOwningPlayer (atker), ALLIANCE_PASSIVE, false)

During this process, the speed given is quite fast, taking into account that the attacker's missile has a speed of 0 so that the impact is immediate. What gives with certainty that within receiving a damage, and the damage caused turns ALLIANCE_PASSIVE on and off quickly.

Tests and tests.

This section is to ask for a little help from the community and to know if this method generates errors, such as that a spell is not cast on the enemy caused by ALLIANCE_PASSIVE, second problems like what happens if the unit dodges the attack? -> (The shortest solution if this happens use a timer with 0 ticks once, if there is no impact on the attacked unit), (perhaps there is a better way of insurance), thirdly there may be strange behaviors in enemy units when attacking ?, until now I did not try much the first and second option.

What can be done if it works correctly?

In this case, having this the following can apply:
- A distant attack that is not detected by an enemy, even hidden in fog of war, that does not generate alerts, this is for camper units lol (if the fog in game constants is 0, so that an attacker does not generate vision.)
Attack in Fog.jpg


Attack in Fog 2.jpg
  • The silent attacks, as in this case a well-known example, the Reaver of Sc 1, that simply the enemy unit must react if it receives the damage of a dummy missile, but of course with the same damage of the attack. This also includes units like lurker, carrier, zealot, firebat, valkyria, etc.
  • Complement the projectile systems, if not the unit ignores you for not receiving damage from attacking, it will do so for receiving damage from a dummy.
  • Many other things that I can think of but this would take a long time to do on this list haha.
Note: the idea was to perform a custom attack for a specific unit, but apparently trying some things that it looks like when a unit attacks and takes damage from the dummy build, this is the next line (that's from what I see), in this In this case, it could be abused using this trick, to launch attacks, which would help to replicate others but in a correct way, which could not be done with a normal system, all that remains is to know if the call SetPlayerAlliance is not desynchronized, since it can be a Disadvantageous if it deals damage or marks a unit when a unit is in a neutral alliance. : / so i would need some help for this uhmm

A Damage system with this method.

You can use the Barrage ability to also ensure that another unit receives the damage apart from the attacker, for example a Ward-type Structure, it does not exist but hey, this will serve as my damage receiver, so that at least I have an idea of how much damage it did. the original attack. It is enough to just put a unit on the map that is seen by every player and we can have a dummy that receives all the damage done by the units that make use of this method.

Barrage Data Ward Struct.jpg


A request: If someone knows if there is a way that a unit can attack quickly without requiring it to use the fire arrows method and its attack recharge time is less than 0.1, to apply benefits and other things using as a dummy a illusion, it would be of an extra help to complement this jethod.

Extras of this Method.
- It can also be used to determine whether a unit launched a projectile or dodged an attack.

Leaving an example map:
Here I attach a map with what was explained above, if there are problems, it can be helpful to know if this system is 100% functional or not.
(Within this is an attack like the Reaver from Sc1, Credits Bribe for his damage system, and Frank for Faux hash) (The idea is to have a general method so that it works in various versions of war 3)

Test Barrage Missile Reaver.jpg
 

Attachments

  • An Attack Detect.w3x
    65.3 KB · Views: 57
  • Test Barrage Missile Reaver.jpg
    Test Barrage Missile Reaver.jpg
    134.1 KB · Views: 87
Last edited:
Level 7
Joined
Mar 14, 2021
Messages
43
is this like a mini tutorial? if so you should post it in the tutorials section, it will just get lost here...
It can really be a tutorial, but the idea was to carry out more tests with the help of the community, to see if this is 100% functional. If there is no problem, you can go to the tutorials area, but you need an Admin to move you to that section. Greetings...
 
Level 21
Joined
Mar 29, 2020
Messages
1,237
this is where you submit tutorials: Tutorial Submission
posting them here and hoping a mod will randomly notice and move it to the tutorial section is... interesting.

If you are looking for assistance with something, I suggest opening with that. I don't think I'm the only one who didn't get to the request on account of the wall of text before it.

greetings and good luck!
 
Level 5
Joined
Sep 6, 2010
Messages
91
I've long wanted to know when an attack missile fires. :smile:


Ok, I was testing your idea and apparently if it works in a "normal" way. Although I had multiple units attacking at the same time, there are no apparent errors. And above all that projectiles are usually slower than immediate attacks, in the case of spells, I did not see that there was any desynchronization between allies, especially using Silent, although I did not know that ALLIANCE_PASSIVE respects attack intervals in attack, even using a timer of 0 ticks, unless a negative effect occurs within this 0.0001 second interval, there may be a glicht. Uhmmm ... Better to wait if someone finds a bug.
 
Level 3
Joined
Jul 7, 2019
Messages
6
Bro, first of all I want to thank you for opening my eyes to such a feature as catching a missile using Barrage. I am not realy interested in the enemy alert, but here are the things I learned during tests:
1) Multishots stack independently of their copies (If you have 2 multishots at the same time, 2 projectiles will fly at each unit)
2) At the same time you can have 'Aroc' (multishot) + 'Afra' (cold debuf) + 'ACsa' (autocast arrows), and they work together. This makes it possible to catch the moment of launching a projectile (multishot), the moment of causing damage from the hand (cold debuf), and also allows you to do all this with autocast abilities (based on ACsa).
Maybe someone will find this useful.
 
Level 7
Joined
Mar 14, 2021
Messages
43
And about the topic - do natives UnitIgnoreAlarm or UnitIgnoreAlarmToggled work?
Yes it works, but they do not prevent a unit attacked by an enemy from reacting, in addition to generating a red attack flashing on the minimap at the unit's point. The idea is that an enemy unit does not react to enemy damage and does something.
 
Top