Page 1 of 1

Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 11:09 am
by Deschain
1. Requirment: IDDS (Dusk's Intricate Damage Detection System). How would one make damage subtractive. For example If a hero deals 11 damage (from any source, but I'm specifically interested in attack.) and the shield is 3 how would I make so that damage dealt to hero would be only 8? I would have to add hardened skins that allows 0.01 damage (so it can be detected but doesn't reduce ally hit points) to all units, right? And then somehow trigger the damage, right? But how would I make it
2. Requirement: IDDS. Is there any way to connect a damage type (example Chaos ) that unit causes to a IDDS custom damage type (example Fire) we made?
3. Is there some bonus mod or trigger that can increase a hero's base attack (Agility, Intelligence and Strength do not contribute to attack in any possible way) without creating green bonus letters (I would prefer not to use upgrades to add base attack since it looks ugly).

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 11:46 am
by Rising_Dusk
It's the Intuitive Damage Detection System, not Intricate. :p
Deschain wrote:1. Requirment: IDDS (Dusk's Intricate Damage Detection System). How would one make damage subtractive. For example If a hero deals 11 damage (from any source, but I'm specifically interested in attack.) and the shield is 3 how would I make so that damage dealt to hero would be only 8? I would have to add hardened skins that allows 0.01 damage (so it can be detected but doesn't reduce ally hit points) to all units, right? And then somehow trigger the damage, right? But how would I make it
Well, I was working on a shield system mod for the IDDS lately. If you want it to be perfect, it's rather complicated, which was why I was going to make it. You'd probably be better off waiting until I'm not lazy and do it myself, but meh. If you used the hardened skin method, you'd need to have some information attached to the unit to tell you its attack damage range. Use UnitIndexingUtils or Table or something for that.
Deschain wrote:2. Requirement: IDDS. Is there any way to connect a damage type (example Chaos ) that unit causes to a IDDS custom damage type (example Fire) we made?
Sure, it's an easy mod to make. Just create an iconless ability and add it to units with "chaos" damage attack type. Then on the IDDS callback check GetTriggerDamageType() == DAMAGE_TYPE_ATTACK and GetUnitAbilitylevel(GetTriggerDamageSource(), 'A000') > 0 where A000 is the raw of that iconless ability.
Deschain wrote:3. Is there some bonus mod or trigger that can increase a hero's base attack (Agility, Intelligence and Strength do not contribute to attack in any possible way) without creating green bonus letters (I would prefer not to use upgrades to add base attack since it looks ugly).
Look up UnitProperties at WC3C.

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 12:55 pm
by Deschain
Nice idea duskeh.

I know about unit properties, I just don't know if there is an ability that changes base attack without displaying green letters.

PS. If you do make the shield system could you make it global in some way so it would resemble Starcraft.

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 1:12 pm
by Rising_Dusk
Deschain wrote:PS. If you do make the shield system could you make it global in some way so it would resemble Starcraft.
I will, no doubts there. Anyways, it would be global and have the capacity to work as a flat reduction or percent.

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 1:33 pm
by Deschain
Than IDDS will become IDE (Intuitive Damage Engine ) :P

As for that ability that changes base attack (as in increases the damage range of attack without adding green text, i.e. 12-13 becomes 13-15 and not 12-13+2). Any ideas? I would really hate to have to use upgrades for something as trivial as that.

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 1:36 pm
by Rising_Dusk
There is nothing other than attributes or upgrades that change the base number of the attack value.

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 1:53 pm
by Deschain
Problems solved then...

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 9:09 pm
by Fledermaus
Sure there is, 'AIaa' (Item Permanent Damage Gain).

Re: Damage Questions (IDDS related)

Posted: Thu Feb 12, 2009 9:49 pm
by Rising_Dusk
Wait, is that a tome? That exists? Oo
Learn something new everyday..

Re: Damage Questions (IDDS related)

Posted: Fri Feb 13, 2009 2:01 am
by Deschain
Tnx Fledermaus, you are a life saver.

PS. I tried to add ability to a hero but to no avail. On init I use the global variable MK to set it to my Mountain King unit

Code: Select all

function Trig_add_Actions takes nothing returns nothing
    call DisplayTextToForce( GetPlayersAll(), "Add" )
    call UnitAddAbility( udg_MK, 'AImh' )
    call UnitAddAbility( udg_MK, 'AIaa' )
endfunction

//===========================================================================
function InitTrig_add takes nothing returns nothing
    set gg_trg_add = CreateTrigger(  )
    call TriggerRegisterPlayerChatEvent( gg_trg_add, Player(0), "add", true )
    call TriggerAddAction( gg_trg_add, function Trig_add_Actions )
endfunction
Am I doing something wrong or is the ability in such way it can't be added through triggers?

Re: Damage Questions (IDDS related)

Posted: Fri Feb 13, 2009 4:04 pm
by Greenspawn
Is is possible to create a spell that deals the caster's attack damage when it hits units? I'm not talking about Rikter's Whirlwind, where the attack is simulated. I mean detecting the caster's attack damage and dealing that damage to the targets of the spell.

Re: Damage Questions (IDDS related)

Posted: Fri Feb 13, 2009 8:28 pm
by Fledermaus
Deschain wrote:PS. I tried to add ability to a hero but to no avail. On init I use the global variable MK to set it to my Mountain King unit
Am I doing something wrong or is the ability in such way it can't be added through triggers?
Not sure, try creating a tome with the ability and giving the unit that instead?

Re: Damage Questions (IDDS related)

Posted: Fri Feb 13, 2009 9:24 pm
by Rising_Dusk
Greenspawn wrote:Is is possible to create a spell that deals the caster's attack damage when it hits units? I'm not talking about Rikter's Whirlwind, where the attack is simulated. I mean detecting the caster's attack damage and dealing that damage to the targets of the spell.
There is no native for getting a unit's damage or armor. If you use some BonusMod derivative for your bonus attack damage and somehow keep track of (Map-specifically) the base damage, you can do it by some formula. This is how I do a skill like Rikter's that takes his attack damage into consideration.

Re: Damage Questions (IDDS related)

Posted: Sat Mar 14, 2009 11:16 am
by Here-b-Trollz
Deschain wrote:1. Requirment: IDDS (Dusk's Intricate Damage Detection System). How would one make damage subtractive. For example If a hero deals 11 damage (from any source, but I'm specifically interested in attack.) and the shield is 3 how would I make so that damage dealt to hero would be only 8? I would have to add hardened skins that allows 0.01 damage (so it can be detected but doesn't reduce ally hit points) to all units, right? And then somehow trigger the damage, right? But how would I make it
You can do it without hardened skin. The most common method is just to add life (in this case 3) when the unit takes damage, since EVENT_UNIT_DAMAGED actually fires just before the unit takes damage. In some instances, though, if you are blocking the damage, you might need to use a 0. second timer and an uber life bonus ability.

Re: Damage Questions (IDDS related)

Posted: Sun Mar 15, 2009 12:43 pm
by Rising_Dusk
Hardened Skin is the method by which one would trigger every attack in the map. This way, if you can back-calculate a unit's attack damage, you can run it through your DDS (in my case the IDDS) and still show the unit's attack damage on the command card. You don't need the Hardened Skin trick for general damage detection, though, Trollzies is right.