Stat Swap status ailment?

Triacular

Villager
Member
Joined
Jan 13, 2019
Messages
27
Reaction score
5
First Language
English
Primarily Uses
RMVXA
Like the title says, I want to know if there's a script there that allows an ailment to have the temporary effect of swapping a player's ATK with DEF in battle.
 

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
5,594
Reaction score
6,525
First Language
Indonesian
Primarily Uses
RMVXA
Code:
class Game_Battler
  alias :ori_atk :atk
  alias :ori_def :def
  def atk
    return ori_def if state?(<PUT STATE ID HERE>)
    return ori_atk
  end

  def def
    return ori_atk if state?(<PUT STATE ID HERE>)
    return ori_def
  end
end
May not displayed in the status screen. But it may work in the damage formula
 

Triacular

Villager
Member
Joined
Jan 13, 2019
Messages
27
Reaction score
5
First Language
English
Primarily Uses
RMVXA
Code:
class Game_Battler
  alias :ori_atk :atk
  alias :ori_def :def
  def atk
    return ori_def if state?(<PUT STATE ID HERE>)
    return ori_atk
  end

  def def
    return ori_atk if state?(<PUT STATE ID HERE>)
    return ori_def
  end
end
May not displayed in the status screen. But it may work in the damage formula
Thank you!
Finally got the effect to work.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Are we allowed to post about non-RPG Maker games?
I should realize that error was produced by a outdated version of MZ so that's why it pop up like that
Ami
i can't wait to drink some ice after struggling with my illness in 9 days. 9 days is really bad for me,i can't focus with my shop and even can't do something with my project
How many hours have you got in mz so far?

A bit of a "sparkle" update to the lower portion of the world map. :LZSexcite:

Forum statistics

Threads
105,883
Messages
1,017,236
Members
137,608
Latest member
Arm9
Top