Destiny.
The Absol Master
- 163
- Posts
- 14
- Years
- Seen Oct 31, 2019
Could someone a little more experienced give me feedback?
What I'm trying to do here is implementing Pixilate. I copied and pasted the lines out of Normalize. I noticed that with normalize, we've got if type >= 0 (Which I think corresponds to, if the type is bigger than or equal to 0 (normal)). Am I doing anything wrong?
(I'm also not sure what the ||0 line means. A little bit of reading suggests that it's or, but what would it mean in the context of the script?)
Code:
def pbType(type,attacker,opponent)
if type=0 && isConst?(attacker.ability,PBAbilities,:PIXILATE)
type=getConst(PBTypes,:FAIRY) || 0
basedmg=(basedmg*1.333).floor
end
(I'm also not sure what the ||0 line means. A little bit of reading suggests that it's or, but what would it mean in the context of the script?)