Advertisement
Dekita

Untitled

Jul 9th, 2014
569
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.16 KB | None | 0 0
  1. #===============================================================================
  2. # dekitarpg.wordpress.com
  3. #===============================================================================
  4. module Removal_Thing
  5. #===============================================================================
  6. #-----------------------------------------------------------------------------
  7. # State ID to remove at end of turns
  8. #-----------------------------------------------------------------------------
  9. State_To_Remove = [12,13,14]
  10. #-----------------------------------------------------------------------------
  11. # Item that is required to remove state ID.
  12. #-----------------------------------------------------------------------------
  13. Item_That_Removes = 10
  14. #-----------------------------------------------------------------------------
  15. #
  16. #-----------------------------------------------------------------------------
  17. end
  18. #===============================================================================
  19. class Game_Battler < Game_BattlerBase
  20. #===============================================================================
  21. #-----------------------------------------------------------------------------
  22. #
  23. #-----------------------------------------------------------------------------
  24. alias :rem_state_if_key_item :update_state_turns
  25. #-----------------------------------------------------------------------------
  26. #
  27. #-----------------------------------------------------------------------------
  28. def update_state_turns
  29. rem_state_if_key_item
  30. states.each do |state|
  31. a = Removal_Thing::State_To_Remove
  32. b = $game_party.has_item?($data_items[Removal_Thing::Item_That_Removes])
  33. remove_state(state.id) if a.include?(state.id) && b && self.is_a?(Game_Actor)
  34. end
  35. end
  36. #-----------------------------------------------------------------------------
  37. #
  38. #-----------------------------------------------------------------------------
  39. end
  40. #===============================================================================
  41. # dekitarpg.wordpress.com
  42. #===============================================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement