Class: Game_Map
Overview
Describe the Map processing
Constant Summary collapse
- MACH_BIKE_BGM =
Audiofile to play when the player is on mach bike
RPG::AudioFile.new('09 Bicycle', 100, 100)
- ACRO_BIKE_BGM =
Audiofile to play when the player is on acro bike
MACH_BIKE_BGM.clone
- PATH_FINDING_ENABLED =
If the Path Finding system is enabled
true
- CenterPlayer =
If the player is always on the center of the screen
Configs.display.is_player_always_centered
- NUM_TILE_VIEW_Y =
Number of tiles the player can see in x
15
- NUM_TILE_VIEW_X =
Number of tiles the player can see in y
20
- FOLLOWER_ID_REGEXP =
Regular expression catching follower id
/\[follow=([0-9]+)\]/
- TERRAIN_TAGS_TABLE =
Convert terrain tag to location symbol
{GameData::SystemTags::TGrass => :grass, GameData::SystemTags::TTallGrass => :grass, GameData::SystemTags::HeadButt => :grass, GameData::SystemTags::TSnow => :snow, GameData::SystemTags::TPond => :shallow_water, GameData::SystemTags::TWetSand => :shallow_water, GameData::SystemTags::SwampBorder => :shallow_water, GameData::SystemTags::DeepSwamp => :shallow_water, GameData::SystemTags::TSand => :desert, GameData::SystemTags::TCave => :cave, GameData::SystemTags::TMount => :cave, GameData::SystemTags::TIce => :icy_cave, GameData::SystemTags::TSea => :water, GameData::SystemTags::WaterFall => :water, GameData::SystemTags::RapidsL => :water, GameData::SystemTags::RapidsD => :water, GameData::SystemTags::RapidsU => :water, GameData::SystemTags::RapidsR => :water, GameData::SystemTags::Whirlpool => :water}
- IVAR_TO_REMOVE_FROM_SAVE_FILE =
List of variable to remove in order to keep the map data safe
%i[@map @tileset_name @autotile_names @panorama_name @panorama_hue @fog_name @fog_hue @fog_opacity @fog_blend_type @fog_zoom @fog_sx @fog_sy @battleback_name @passages @priorities @terrain_tags @events @common_events @system_tags]
Instance Attribute Summary collapse
-
#autotile_names
タイルセット ファイル名.
-
#battleback_name
フォグ SY.
-
#display_x
バトルバック ファイル名.
-
#display_y
表示 X 座標 * 128.
-
#event_erased ⇒ Boolean
If an event has been erased (helps removing it).
-
#events ⇒ Hash{Integer => Game_Event}
readonly
地形タグ テーブル.
-
#events_sym_to_id ⇒ Hash<Symbol, Integer>
Return the hash of symbol associate to event id.
-
#fog_blend_type
フォグ 不透明度.
-
#fog_hue
フォグ ファイル名.
-
#fog_name
パノラマ 色相.
-
#fog_opacity
フォグ 色相.
-
#fog_ox
readonly
Returns the value of attribute fog_ox.
-
#fog_oy
readonly
フォグ 原点 X 座標.
-
#fog_sx
フォグ 拡大率.
-
#fog_sy
フォグ SX.
-
#fog_tone
readonly
フォグ 原点 Y 座標.
-
#fog_zoom
フォグ ブレンド方法.
-
#maplinker_disabled ⇒ Boolean
readonly
フォグ 色調.
-
#need_refresh
表示 Y 座標 * 128.
-
#panorama_hue
パノラマ ファイル名.
-
#panorama_name
オートタイル ファイル名.
-
#passages
readonly
リフレッシュ要求フラグ.
-
#priorities
readonly
通行 テーブル.
-
#system_tags ⇒ Table
readonly
The system_tags linked to each tiles of the tileset.
-
#terrain_tags
readonly
プライオリティ テーブル.
-
#tileset_name
Returns the value of attribute tileset_name.
Instance Method Summary collapse
-
#autoplay
Auto play bgm and bgs of the map if defined.
-
#begin_save
Method that prevent non wanted data save of the Game_Map object.
-
#bush?(x, y) ⇒ Boolean
Tells if the tile is a bush tile.
-
#counter?(x, y) ⇒ Boolean
カウンター判定 (no idea, need GTranslate).
-
#data ⇒ Table
Returns the tile matrix of the Map.
-
#encounter_list
deprecated
Deprecated.
Not used by the Core of PSDK because not precise enough to be used
-
#end_save
Method that end the save state of the Game_Map object.
-
#get_tile(x, y) ⇒ Integer
Retrieve the id of a specific tile.
-
#height ⇒ Integer
Returns the height of the map.
-
#initialize ⇒ Game_Map
constructor
Initialize the default Game_Map object.
-
#jump_passable?(x, y, d) ⇒ Boolean
Check if the player can jump a case with the acro bike.
-
#load_systemtags
Loads the SystemTags of the map.
-
#location_type(x, y) ⇒ Symbol
Return the current location type.
-
#map_id ⇒ Integer
Returns the ID of the Map.
-
#passable?(x, y, d, self_event = nil) ⇒ Boolean
Tells if the tile front/current tile is passsable or not.
-
#refresh
Refresh events and common events of the map.
-
#rmxp_encounter_steps ⇒ Integer
Returns the encounter steps from RMXP data.
-
#scroll_down(distance, is_priority = false)
Scrolls the map down.
-
#scroll_left(distance, is_priority = false)
Scrolls the map left.
-
#scroll_right(distance, is_priority = false)
Scrolls the map right.
-
#scroll_up(distance, is_priority = false)
Scrolls the map up.
-
#scrolling? ⇒ Boolean
is the map scrolling ?.
-
#setup(map_id)
setup the Game_Map object with the right Map data.
-
#start_fog_opacity_change(opacity, duration)
Starts a fog opacity change process.
-
#start_fog_tone_change(tone, duration)
Starts a fog tone change process.
-
#start_scroll(direction, distance, speed, x_priority = false, y_priority = false)
Starts a scroll processing.
-
#system_tag(x, y) ⇒ Integer
Retrieve the ID of the SystemTag on a specific tile.
-
#system_tag_here?(x, y, tag) ⇒ Boolean
Check if a specific SystemTag is present on a specific tile.
-
#terrain_tag(x, y) ⇒ Integer?
Returns the tag of the tile.
-
#update
Update the Map processing.
-
#valid?(x, y) ⇒ Boolean
Tells if the x,y coordinate is valid or not (inside of bounds).
-
#width ⇒ Integer
Returns the width of the map.
Constructor Details
#initialize ⇒ Game_Map
Initialize the default Game_Map object
3214 3215 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3214 def initialize end |
Instance Attribute Details
#autotile_names
タイルセット ファイル名
3166 3167 3168 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3166 def autotile_names @autotile_names end |
#battleback_name
フォグ SY
3186 3187 3188 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3186 def battleback_name @battleback_name end |
#display_x
バトルバック ファイル名
3188 3189 3190 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3188 def display_x @display_x end |
#display_y
表示 X 座標 * 128
3190 3191 3192 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3190 def display_y @display_y end |
#event_erased ⇒ Boolean
If an event has been erased (helps removing it)
3353 3354 3355 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3353 def event_erased @event_erased end |
#events ⇒ Hash{Integer => Game_Event} (readonly)
地形タグ テーブル
3201 3202 3203 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3201 def events @events end |
#events_sym_to_id ⇒ Hash<Symbol, Integer>
Return the hash of symbol associate to event id
3204 3205 3206 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3204 def events_sym_to_id @events_sym_to_id end |
#fog_blend_type
フォグ 不透明度
3178 3179 3180 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3178 def fog_blend_type @fog_blend_type end |
#fog_hue
フォグ ファイル名
3174 3175 3176 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3174 def fog_hue @fog_hue end |
#fog_name
パノラマ 色相
3172 3173 3174 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3172 def fog_name @fog_name end |
#fog_opacity
フォグ 色相
3176 3177 3178 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3176 def fog_opacity @fog_opacity end |
#fog_ox (readonly)
Returns the value of attribute fog_ox.
3205 3206 3207 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3205 def fog_ox @fog_ox end |
#fog_oy (readonly)
フォグ 原点 X 座標
3207 3208 3209 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3207 def fog_oy @fog_oy end |
#fog_sx
フォグ 拡大率
3182 3183 3184 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3182 def fog_sx @fog_sx end |
#fog_sy
フォグ SX
3184 3185 3186 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3184 def fog_sy @fog_sy end |
#fog_tone (readonly)
フォグ 原点 Y 座標
3209 3210 3211 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3209 def fog_tone @fog_tone end |
#fog_zoom
フォグ ブレンド方法
3180 3181 3182 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3180 def fog_zoom @fog_zoom end |
#maplinker_disabled ⇒ Boolean (readonly)
フォグ 色調
3212 3213 3214 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3212 def maplinker_disabled @maplinker_disabled end |
#need_refresh
表示 Y 座標 * 128
3192 3193 3194 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3192 def need_refresh @need_refresh end |
#panorama_hue
パノラマ ファイル名
3170 3171 3172 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3170 def panorama_hue @panorama_hue end |
#panorama_name
オートタイル ファイル名
3168 3169 3170 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3168 def panorama_name @panorama_name end |
#passages (readonly)
リフレッシュ要求フラグ
3194 3195 3196 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3194 def passages @passages end |
#priorities (readonly)
通行 テーブル
3196 3197 3198 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3196 def priorities @priorities end |
#system_tags ⇒ Table (readonly)
The system_tags linked to each tiles of the tileset
3356 3357 3358 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3356 def @system_tags end |
#terrain_tags (readonly)
プライオリティ テーブル
3198 3199 3200 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3198 def @terrain_tags end |
#tileset_name
Returns the value of attribute tileset_name.
3164 3165 3166 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3164 def tileset_name @tileset_name end |
Instance Method Details
#autoplay
Auto play bgm and bgs of the map if defined
3245 3246 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3245 def autoplay end |
#begin_save
Method that prevent non wanted data save of the Game_Map object
3402 3403 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3402 def begin_save end |
#bush?(x, y) ⇒ Boolean
Tells if the tile is a bush tile
3288 3289 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3288 def bush?(x, y) end |
#counter?(x, y) ⇒ Boolean
カウンター判定 (no idea, need GTranslate)
3294 3295 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3294 def counter?(x, y) end |
#data ⇒ Table
Returns the tile matrix of the Map
3242 3243 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3242 def data end |
#encounter_list
Not used by the Core of PSDK because not precise enough to be used
Returns the encounter list
3234 3235 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3234 def encounter_list end |
#end_save
Method that end the save state of the Game_Map object
3406 3407 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3406 def end_save end |
#get_tile(x, y) ⇒ Integer
Retrieve the id of a specific tile
3381 3382 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3381 def get_tile(x, y) end |
#height ⇒ Integer
Returns the height of the map
3230 3231 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3230 def height end |
#jump_passable?(x, y, d) ⇒ Boolean
Check if the player can jump a case with the acro bike
3389 3390 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3389 def jump_passable?(x, y, d) end |
#load_systemtags
Loads the SystemTags of the map
3374 3375 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3374 def end |
#location_type(x, y) ⇒ Symbol
Return the current location type
3393 3394 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3393 def location_type(x, y) end |
#map_id ⇒ Integer
Returns the ID of the Map
3222 3223 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3222 def map_id end |
#passable?(x, y, d, self_event = nil) ⇒ Boolean
Tells if the tile front/current tile is passsable or not
3282 3283 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3282 def passable?(x, y, d, self_event = nil) end |
#refresh
Refresh events and common events of the map
3248 3249 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3248 def refresh end |
#rmxp_encounter_steps ⇒ Integer
Returns the encounter steps from RMXP data
3238 3239 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3238 def rmxp_encounter_steps end |
#scroll_down(distance, is_priority = false)
Scrolls the map down
3253 3254 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3253 def scroll_down(distance, is_priority = false) end |
#scroll_left(distance, is_priority = false)
Scrolls the map left
3258 3259 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3258 def scroll_left(distance, is_priority = false) end |
#scroll_right(distance, is_priority = false)
Scrolls the map right
3263 3264 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3263 def scroll_right(distance, is_priority = false) end |
#scroll_up(distance, is_priority = false)
Scrolls the map up
3268 3269 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3268 def scroll_up(distance, is_priority = false) end |
#scrolling? ⇒ Boolean
is the map scrolling ?
3312 3313 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3312 def scrolling? end |
#setup(map_id)
setup the Game_Map object with the right Map data
3218 3219 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3218 def setup(map_id) end |
#start_fog_opacity_change(opacity, duration)
Starts a fog opacity change process
3322 3323 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3322 def start_fog_opacity_change(opacity, duration) end |
#start_fog_tone_change(tone, duration)
Starts a fog tone change process
3317 3318 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3317 def start_fog_tone_change(tone, duration) end |
#start_scroll(direction, distance, speed, x_priority = false, y_priority = false)
Starts a scroll processing
3308 3309 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3308 def start_scroll(direction, distance, speed, x_priority = false, y_priority = false) end |
#system_tag(x, y) ⇒ Integer
Retrieve the ID of the SystemTag on a specific tile
3362 3363 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3362 def system_tag(x, y) end |
#system_tag_here?(x, y, tag) ⇒ Boolean
Check if a specific SystemTag is present on a specific tile
3370 3371 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3370 def system_tag_here?(x, y, tag) end |
#terrain_tag(x, y) ⇒ Integer?
Returns the tag of the tile
3300 3301 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3300 def terrain_tag(x, y) end |
#update
Update the Map processing
3325 3326 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3325 def update end |
#valid?(x, y) ⇒ Boolean
Tells if the x,y coordinate is valid or not (inside of bounds)
3274 3275 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3274 def valid?(x, y) end |
#width ⇒ Integer
Returns the width of the map
3226 3227 |
# File 'docs/4_Systems_003_Map_Engine.rb', line 3226 def width end |