Page 1 of 1
[1.0] help - how do I call phyiscal damage increase?
Posted: Sun Feb 03, 2013 12:41 pm
by jenx
Can I simply do this?
Code: Select all
local dam_inc_physical = self.inc_damage["PHYSICAL"]
If not, how do I retrieve the physical damage increase?
And do I need to check first if there even is such a value, when it equals 0?
Re: [1.0] help - how do I call phyiscal damage increase?
Posted: Sun Feb 03, 2013 5:45 pm
by lukep
jenx wrote:And do I need to check first if there even is such a value, when it equals 0?
You can just add "or 0" at the end for that. I believe that that's what's done in some other places.
Re: [1.0] help - how do I call phyiscal damage increase?
Posted: Sun Feb 03, 2013 9:55 pm
by jenx
I"ve tried that, but the line I proposed returns zero, even when physical damage increase is 10%. So I must have the notation wrong.
Any help?
Re: [1.0] help - how do I call phyiscal damage increase?
Posted: Sun Feb 03, 2013 10:01 pm
by jenx
I"ve found this notation in the code, which I think might work:
Code: Select all
self.inc_damage[DamageType.PHYSICAL]
Re: [1.0] help - how do I call phyiscal damage increase?
Posted: Sun Feb 03, 2013 11:27 pm
by jenx
it does!