• Do not use Discord to host any images you post, these links expire quickly! You can learn how to add images to your posts here.
  • Eevee Expo's webhost has been having technical issues since Nov. 20th and you might be unable to connect to our site. Staff are also facing issues connecting, so please send a DM to Cat on-site or through Discord directly for faster service!

Toxic Spikes Damaging Move Help?

HeroicAlter

Rookie
Member
Joined
Mar 7, 2024
Posts
2
I'm trying to make a signature move for a Water/Poison Croconaw Regional evo, and my idea was that it deals damage but also lays down Toxic Spikes, like the move of the same name. However, I'm having trouble making the new battle effect that allows it to create the Toxic Spikes. I tried copying "AddToxicSpikesToFoeSide" from Toxic Spikes, then realized that that battle effect doesn't allow for damage, so I'm making a new one, but it isn't working.

Here's my current code:

Ruby:
Expand Collapse Copy
class Battle::Move::DamageAndAddToxicSpikes < Battle::Move
  def pbMoveFailed?(user, targets)
    if user.pbOpposingSide.effects[PBEffects::ToxicSpikes] >= 2
      @battle.pbDisplay(_INTL("But it failed!"))
      return true
    end
      return false
    end
  def pbAdditionalEffect(user, target)
  return if target.damageState.substitute
    def pbEffectGeneral(user)
      user.pbOpposingSide.effects[PBEffects::ToxicSpikes] += 1
      @battle.pbDisplay(_INTL("Poison spikes were scattered all around {1}'s feet!",
                              user.pbOpposingTeam(true)))
    end
  end
end

I added the code on lines 9, 10, and 16.
 

Penelope

Trainer
Member
Joined
Sep 15, 2023
Posts
87
maybe delete line 9, 10, and 16 just ok. i am not sure what method is the most suitable, maybe you need to set the effect chance to 100.
 
Back
Top