Advertisement
Guest User

Untitled

a guest
Sep 21st, 2017
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.37 KB | None | 0 0
  1. #--------------------------------------------------------------------------
  2. # * Start Actor Command Selection
  3. #--------------------------------------------------------------------------
  4.  
  5. class Scene_Battle < Scene_Base
  6.  
  7. def start_actor_command_selection
  8. @party_command_window.active = false
  9. @actor_command_window.setup(@active_battler)
  10. @actor_command_window.active = true
  11. @actor_command_window.visible = true
  12. @actor_command_window.index = 0
  13. @actor_command_window.x = 0
  14. @actor_command_window.y = 220
  15. @actor_command_window.width = 546
  16. @actor_command_window.height = 70
  17.  
  18.  
  19. end
  20.  
  21. #--------------------------------------------------------------------------
  22. # * Update Actor Command Selection
  23. #--------------------------------------------------------------------------
  24. def update_actor_command_selection
  25. @status_window.visible = true
  26. if Input.trigger?(Input::C )
  27. case @actor_command_window.index
  28.  
  29. when 0 # Attack
  30. Sound.play_decision
  31. start_skill_selection
  32. when 1 # Item
  33. Sound.play_decision
  34. start_item_selection
  35. when 2 # Run
  36. if $game_troop.can_escape == false
  37. Sound.play_buzzer
  38. return
  39. end
  40. Sound.play_decision
  41. process_escape
  42. end
  43. end
  44. end
  45. end
  46.  
  47. #==============================================================================
  48. # * Window_ActorCommand
  49. #------------------------------------------------------------------------------
  50. # This process starts the actor command window.
  51. #==============================================================================
  52. class Window_ActorCommand < Window_Command
  53.  
  54. #--------------------------------------------------------------------------
  55. # * Setup
  56. #--------------------------------------------------------------------------
  57. def setup(actor)
  58.  
  59. s1 = Vocab::attack
  60. s2 = Vocab::item
  61. s3 = Vocab::escape
  62.  
  63. if actor.class.skill_name_valid
  64. s1 = actor.class.skill_name
  65. end
  66.  
  67. # @actor_command_window = Window_Command.new(546, [s1, s2, s3], 3)
  68. # @actor_command_window.y = 220
  69. # @actor_command_window.height = 70
  70. @commands = [s1, s2, s3]
  71. @column_max = 3
  72. @item_max = 3
  73. @spacing = -5
  74. refresh
  75. self.index = 0
  76. end
  77. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement