Class: Game_Actor
- Inherits:
-
Game_Battler
- Object
- Game_Battler
- Game_Actor
- Defined in:
- scripts/00600 Script_RMXP/00600 Game_Battler.rb
Overview
Describe a player
Instance Attribute Summary collapse
-
#battler_name
readonly
Returns the value of attribute battler_name.
-
#character_hue
readonly
Returns the value of attribute character_hue.
-
#character_name
readonly
Returns the value of attribute character_name.
-
#exp
Returns the value of attribute exp.
-
#level
Returns the value of attribute level.
-
#name
Returns the value of attribute name.
-
#skills
readonly
Returns the value of attribute skills.
Attributes inherited from Game_Battler
#animation_hit, #animation_id, #battler_hue, #blink, #critical, #damage, #hidden, #hp, #sp, #states, #white_flash
Instance Method Summary collapse
-
#id ⇒ Integer
id of the Game_Actor in the database.
-
#index ⇒ Integer?
index of the Game_Actor in the $game_party.
-
#initialize(actor_id) ⇒ Game_Actor
constructor
Initialize a new Game_Actor.
-
#screen_x
deprecated
Deprecated.
will be removed.
-
#screen_y
deprecated
Deprecated.
will be removed.
-
#screen_z
deprecated
Deprecated.
will be removed.
-
#set_graphic(character_name, character_hue, battler_name, battler_hue)
Update the graphics of the Game_Actor.
-
#setup(actor_id)
setup the Game_Actor object.
Methods inherited from Game_Battler
#agi, #atk, #dead?, #dex, #eva, #exist?, #hit, #int, #mdef, #pdef, #str
Constructor Details
#initialize(actor_id) ⇒ Game_Actor
Initialize a new Game_Actor
174 175 176 177 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 174 def initialize(actor_id) super() setup(actor_id) end |
Instance Attribute Details
#battler_name (readonly)
Returns the value of attribute battler_name.
167 168 169 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 167 def battler_name @battler_name end |
#character_hue (readonly)
Returns the value of attribute character_hue.
166 167 168 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 166 def character_hue @character_hue end |
#character_name (readonly)
Returns the value of attribute character_name.
165 166 167 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 165 def character_name @character_name end |
#exp
Returns the value of attribute exp.
169 170 171 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 169 def exp @exp end |
#level
Returns the value of attribute level.
168 169 170 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 168 def level @level end |
#name
Returns the value of attribute name.
164 165 166 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 164 def name @name end |
#skills (readonly)
Returns the value of attribute skills.
170 171 172 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 170 def skills @skills end |
Instance Method Details
#id ⇒ Integer
id of the Game_Actor in the database
193 194 195 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 193 def id return @actor_id end |
#index ⇒ Integer?
index of the Game_Actor in the $game_party.
199 200 201 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 199 def index return $game_party.actors.index(self) end |
#screen_x
will be removed.
229 230 231 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 229 def screen_x return 0 end |
#screen_y
will be removed.
234 235 236 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 234 def screen_y return 464 end |
#screen_z
will be removed.
239 240 241 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 239 def screen_z return 0 end |
#set_graphic(character_name, character_hue, battler_name, battler_hue)
Update the graphics of the Game_Actor
221 222 223 224 225 226 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 221 def set_graphic(character_name, character_hue, battler_name, battler_hue) @character_name = character_name @character_hue = character_hue @battler_name = battler_name @battler_hue = battler_hue end |
#setup(actor_id)
setup the Game_Actor object
181 182 183 184 185 186 187 188 189 |
# File 'scripts/00600 Script_RMXP/00600 Game_Battler.rb', line 181 def setup(actor_id) actor = $data_actors[actor_id] @actor_id = actor_id @name = actor.name @character_name = actor.character_name @character_hue = actor.character_hue @battler_name = actor.battler_name @battler_hue = actor.battler_hue end |