Advertisement
Guest User

Untitled

a guest
Nov 14th, 2019
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.74 KB | None | 0 0
  1. p=thismove.priority
  2. if USENEWBATTLEMECHANICS
  3. p+=1 if user.hasWorkingAbility(:PRANKSTER) && thismove.pbIsStatus?
  4. p+=1 if user.hasWorkingAbility(:GALEWINGS) && isConst?(thismove.type,PBTypes,:FLYING)
  5. p+=3 if user.hasWorkingAbility(:TRIAGE) && thismove.isHealingMove? &&
  6. !isConst?(thismove.id,PBMoves,:AQUARING) &&
  7. !isConst?(thismove.id,PBMoves,:GRASSYTERRAIN) &&
  8. !isConst?(thismove.id,PBMoves,:INGRAIN) &&
  9. !isConst?(thismove.id,PBMoves,:LEECHSEED) &&
  10. !isConst?(thismove.id,PBMoves,:PAINSPLIT) &&
  11. !isConst?(thismove.id,PBMoves,:PRESENT) &&
  12. !isConst?(thismove.id,PBMoves,:POLLENPUFF)
  13. end
  14. if p>0 && thismove.target!=PBTargets::AllOpposing && thismove.target!=PBTargets::BothSides
  15. for i in 0...4; battler=@battle.battlers[i]
  16. if @battle.field.effects[PBEffects::PsychicTerrain]>0 && !user.isAirborne?
  17. PBDebug.log("Psychic Terrain prevented #{user.pbThis}'s priority move")
  18. @battle.pbDisplay(_INTL("The psychic terrain prevented the use of priority moves!"))
  19. return false
  20. elsif !user.hasMoldBreaker && pbIsOpposing?(i) && (battler.hasWorkingAbility(:QUEENLYMAJESTY) ||
  21. battler.hasWorkingAbility(:DAZZLING))
  22. thismove.pp -=1
  23. @battle.pbDisplay(_INTL("{1} cannot use {2}!",user.pbThis,PBMoves.getName(thismove)))
  24. return false
  25. end
  26. end
  27. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement