Fixed Magic Guard not being checked for damage from Shadow Sky weather/Spiky Shield/Dry Skin/Solar Power, fixed As One not having Unnerve's effect, fixed Gulp Missile paralysing the wrong Pokémon, added message for obtaining multiple machine items at once

This commit is contained in:
Maruno17
2023-04-20 18:04:15 +01:00
parent b9bf3e8b83
commit 4bab130785
6 changed files with 41 additions and 21 deletions

View File

@@ -669,7 +669,13 @@ def pbItemBall(item, quantity = 1)
if item == :DNASPLICERS
pbMessage("\\me[#{meName}]" + _INTL("You found \\c[1]{1}\\c[0]!", itemname) + "\\wtnp[30]")
elsif item.is_machine? # TM or HM
pbMessage("\\me[#{meName}]" + _INTL("You found \\c[1]{1} {2}\\c[0]!", itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
if quantity > 1
pbMessage("\\me[#{meName}]" + _INTL("You found {1} \\c[1]{2} {3}\\c[0]!",
quantity, itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
else
pbMessage("\\me[#{meName}]" + _INTL("You found \\c[1]{1} {2}\\c[0]!",
itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
end
elsif quantity > 1
pbMessage("\\me[#{meName}]" + _INTL("You found {1} \\c[1]{2}\\c[0]!", quantity, itemname) + "\\wtnp[30]")
elsif itemname.starts_with_vowel?
@@ -683,7 +689,11 @@ def pbItemBall(item, quantity = 1)
end
# Can't add the item
if item.is_machine? # TM or HM
pbMessage(_INTL("You found \\c[1]{1} {2}\\c[0]!", itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
if quantity > 1
pbMessage(_INTL("You found {1} \\c[1]{2} {3}\\c[0]!", quantity, itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
else
pbMessage(_INTL("You found \\c[1]{1} {2}\\c[0]!", itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
end
elsif quantity > 1
pbMessage(_INTL("You found {1} \\c[1]{2}\\c[0]!", quantity, itemname) + "\\wtnp[30]")
elsif itemname.starts_with_vowel?
@@ -708,7 +718,13 @@ def pbReceiveItem(item, quantity = 1)
if item == :DNASPLICERS
pbMessage("\\me[#{meName}]" + _INTL("You obtained \\c[1]{1}\\c[0]!", itemname) + "\\wtnp[30]")
elsif item.is_machine? # TM or HM
pbMessage("\\me[#{meName}]" + _INTL("You obtained \\c[1]{1} {2}\\c[0]!", itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
if quantity > 1
pbMessage("\\me[#{meName}]" + _INTL("You obtained {1} \\c[1]{2} {3}\\c[0]!",
quantity, itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
else
pbMessage("\\me[#{meName}]" + _INTL("You obtained \\c[1]{1} {2}\\c[0]!",
itemname, GameData::Move.get(move).name) + "\\wtnp[30]")
end
elsif quantity > 1
pbMessage("\\me[#{meName}]" + _INTL("You obtained {1} \\c[1]{2}\\c[0]!", quantity, itemname) + "\\wtnp[30]")
elsif itemname.starts_with_vowel?