- 16
- Posts
- 5
- Years
- Seen Aug 1, 2023
I'm trying to make an attack that sets up a thunderstorm (electric terrain and rain). However, the moves acts like a "Status" moves instead of an attack. So no damage was inflicted, only the weather was set up.
How do I make it hurt my opponent then set up a weather? Similar how to Max Flare sets up sunny day.
Here's the move.txt:
Here's the MoveEffects script:
Thanks in advance.
How do I make it hurt my opponent then set up a weather? Similar how to Max Flare sets up sunny day.
Here's the move.txt:
XXX,MONSOON,Monsoon,301,100,ELECTRIC,Special,95,5,0,00,0,bef,"The user summoned a storm of thunders at the foe. Causing a thunderstorm for 5 turns."
Here's the MoveEffects script:
Code:
################################################################################
# Starts thunderstorm weather. (Monsoon)
################################################################################
class PokeBattle_Move_301 < PokeBattle_Move
def pbEffect(attacker,opponent,hitnum=0,alltargets=nil,showanimation=true)
case @battle.weather
when PBWeather::HEAVYRAIN
@battle.pbDisplay(_INTL("There is no relief from this heavy rain!"))
return -1
when PBWeather::HARSHSUN
@battle.pbDisplay(_INTL("The extremely harsh sunlight was not lessened at all!"))
return -1
when PBWeather::STRONGWINDS
@battle.pbDisplay(_INTL("The mysterious air current blows on regardless!"))
return -1
end
pbShowAnimation(@id,attacker,nil,hitnum,alltargets,showanimation)
@battle.field.effects[PBEffects::GrassyTerrain]=0
@battle.field.effects[PBEffects::MistyTerrain]=0
@battle.field.effects[PBEffects::ElectricTerrain]=5
@battle.field.effects[PBEffects::ElectricTerrain]=8 if attacker.hasWorkingItem(:DAMPROCK)
@battle.weather=PBWeather::RAINDANCE
@battle.weatherduration=5
@battle.weatherduration=8 if attacker.hasWorkingItem(:DAMPROCK)
@battle.pbCommonAnimation("Rain",nil,nil)
@battle.pbDisplay(_INTL("A thunderstrom brewed in!"))
return 0
end
end
Thanks in advance.
Last edited: