Attack Detection

jhnam95

Active Member
Reaction score
12
Is it possible to use GDD and detect attacks only? No spells or immolation or anything like that. Just attacks.
 

mapguy

New Member
Reaction score
46
you can use GDD if all your item and spell damage is dealed by dummy units. so, any damage that is not caused by dummy will be attack damage.
 

Ayanami

칼리
Reaction score
288
You could easily do it with the aid of buff placers, or you could probably do it like how mapguy mentioned. However, I believe J4L's Damage System is the best way to go.
 

mapguy

New Member
Reaction score
46
You could easily do it with the aid of buff placers, or you could probably do it like how mapguy mentioned. However, I believe J4L's Damage System is the best way to go.

if u detect with buff placer then your attacks will all be orb effects...
 

Ayanami

칼리
Reaction score
288
if u detect with buff placer then your attacks will all be orb effects...

Well, yes I do know. And by the way, Buff Placers and Orb Effects are different. Buff Placers (ex. Envenomed Spears) stacks with Orb Effects (ex. lifesteal). That's why I said, J4L's Damage is the easiest way to go.
 

Ayanami

칼리
Reaction score
288
J4L's Damage said:
JASS:

//          function Damage_IsPhysical takes nothing returns boolean
//          function Damage_IsSpell takes nothing returns boolean
//          function Damage_IsPure takes nothing returns boolean
//              - Wrappers to simply check if Damage_GetType is certain types.
//
//          function Damage_IsAttack takes nothing returns boolean
//              - Checks if the damage is from a physical attack (so you can deal
//                physical damage without it being registered as an actual attack).

Thus, you can see that yes, you can detect if the damage is physical, spell or pure. You can also detect if the physical damage was an attack or triggered by using "function Damage_IsAttack".
 

mapguy

New Member
Reaction score
46
yeah...allright.
I just dont use it cause my map is 50% ready and all damage is dealed by dummy here...
 

jhnam95

Active Member
Reaction score
12
Sigh... I'm not much of a Jasser. So I just use that function as I would do for any other event, right?
 

Ayanami

칼리
Reaction score
288
Sigh... I'm not much of a Jasser. So I just use that function as I would do for any other event, right?

Erm, it'll be a bit different. You would require a bit of JASS knowledge, at least know how to call functions.
 

Jedi

New Member
Reaction score
63
You need do deal all your damage with triggers, if you want to use them.(I might edit this post later)
 

mapguy

New Member
Reaction score
46
Sigh... I'm not much of a Jasser. So I just use that function as I would do for any other event, right?

If you are not good at JASS just use my way.

all magical damage is dealed by trigger, so, every damage dealed by a unit will be attack damage.

example, If a hero deals damage, this is an attack.
If a dummy unit deals damage, this is a magical attack.
you can make all your dummy units ancients, so, you can check if the damage source is ancient.
 

Accname

2D-Graphics enthusiast
Reaction score
1,464
If he wants to read a tutorial...some people just don't want.

OFF-TOPIC: your new avatar is really funny:D

the method you describe is not really good, using dummy units will slow down performance alot, creating a unit is one of the slowest functions in wc3.
either use this only with a global dummy unit or better switch to some other method such as J4L's damage system.
 

jhnam95

Active Member
Reaction score
12
Well I personally don't mind learning JASS. It's just it looks so complicated :(

And how does creating a unit slow down performance? Does it create lag and how much? I'm creating a lot of dummy units and I don't want huge spikes 10 minutes into the game ):
 

Accname

2D-Graphics enthusiast
Reaction score
1,464
its just a slow function compared to others. it takes its time to create a new unit. of course it wouldnt be like DAOMFGMEGALAGLIKEHELL!!!!! but still its not the most efficient way to go.
 

jhnam95

Active Member
Reaction score
12
Ohhh okay.. You freaked me out there for a minute. I thought it would be like, after you create 300 dummy units, your map has an FPS of 2 or something. I think I'm just going to leave it as is. I don't really mind if a few spells trigger it, or at least not for now. I'll try learning JASS and get j4l's detector working for my map.
 

mapguy

New Member
Reaction score
46
Do like I did in my map.

In the far top right corner of my map, an invisible dummy is there.
when I want to deal Skill damage, I change the owner of the dummy and causes this dummy to damage that unit :thup:
no units created!
no lag resulted!
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      • Ghan
        Administrator - Servers are fun

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top