Class: RPG::Map
- Inherits:
-
Object
- Object
- RPG::Map
- Defined in:
- lib/rpg/map.rb,
lib/rpg/map/encounter.rb
Defined Under Namespace
Classes: Encounter
Instance Attribute Summary collapse
-
#autoplay_bgm ⇒ Object
Returns the value of attribute autoplay_bgm.
-
#autoplay_bgs ⇒ Object
Returns the value of attribute autoplay_bgs.
-
#battleback1_name ⇒ Object
Returns the value of attribute battleback1_name.
-
#battleback2_name ⇒ Object
Returns the value of attribute battleback2_name.
-
#bgm ⇒ Object
Returns the value of attribute bgm.
-
#bgs ⇒ Object
Returns the value of attribute bgs.
-
#data ⇒ Object
Returns the value of attribute data.
-
#disable_dashing ⇒ Object
Returns the value of attribute disable_dashing.
-
#display_name ⇒ Object
Returns the value of attribute display_name.
-
#encounter_list ⇒ Object
Returns the value of attribute encounter_list.
-
#encounter_step ⇒ Object
Returns the value of attribute encounter_step.
-
#events ⇒ Object
Returns the value of attribute events.
-
#height ⇒ Object
Returns the value of attribute height.
-
#note ⇒ Object
Returns the value of attribute note.
-
#parallax_loop_x ⇒ Object
Returns the value of attribute parallax_loop_x.
-
#parallax_loop_y ⇒ Object
Returns the value of attribute parallax_loop_y.
-
#parallax_name ⇒ Object
Returns the value of attribute parallax_name.
-
#parallax_show ⇒ Object
Returns the value of attribute parallax_show.
-
#parallax_sx ⇒ Object
Returns the value of attribute parallax_sx.
-
#parallax_sy ⇒ Object
Returns the value of attribute parallax_sy.
-
#scroll_type ⇒ Object
Returns the value of attribute scroll_type.
-
#specify_battleback ⇒ Object
Returns the value of attribute specify_battleback.
-
#tileset_id ⇒ Object
Returns the value of attribute tileset_id.
-
#width ⇒ Object
Returns the value of attribute width.
Instance Method Summary collapse
-
#initialize(width, height) ⇒ Map
constructor
A new instance of Map.
Constructor Details
#initialize(width, height) ⇒ Map
Returns a new instance of Map.
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/rpg/map.rb', line 3 def initialize(width, height) @display_name = '' @tileset_id = 1 @width = width @height = height @scroll_type = 0 @specify_battleback = false @battleback_floor_name = '' @battleback_wall_name = '' @autoplay_bgm = false @bgm = RPG::BGM.new @autoplay_bgs = false @bgs = RPG::BGS.new('', 80) @disable_dashing = false @encounter_list = [] @encounter_step = 30 @parallax_name = '' @parallax_loop_x = false @parallax_loop_y = false @parallax_sx = 0 @parallax_sy = 0 @parallax_show = false @note = '' @data = Table.new(width, height, 4) @events = {} end |
Instance Attribute Details
#autoplay_bgm ⇒ Object
Returns the value of attribute autoplay_bgm.
37 38 39 |
# File 'lib/rpg/map.rb', line 37 def autoplay_bgm @autoplay_bgm end |
#autoplay_bgs ⇒ Object
Returns the value of attribute autoplay_bgs.
39 40 41 |
# File 'lib/rpg/map.rb', line 39 def autoplay_bgs @autoplay_bgs end |
#battleback1_name ⇒ Object
Returns the value of attribute battleback1_name.
35 36 37 |
# File 'lib/rpg/map.rb', line 35 def battleback1_name @battleback1_name end |
#battleback2_name ⇒ Object
Returns the value of attribute battleback2_name.
36 37 38 |
# File 'lib/rpg/map.rb', line 36 def battleback2_name @battleback2_name end |
#bgm ⇒ Object
Returns the value of attribute bgm.
38 39 40 |
# File 'lib/rpg/map.rb', line 38 def bgm @bgm end |
#bgs ⇒ Object
Returns the value of attribute bgs.
40 41 42 |
# File 'lib/rpg/map.rb', line 40 def bgs @bgs end |
#data ⇒ Object
Returns the value of attribute data.
51 52 53 |
# File 'lib/rpg/map.rb', line 51 def data @data end |
#disable_dashing ⇒ Object
Returns the value of attribute disable_dashing.
41 42 43 |
# File 'lib/rpg/map.rb', line 41 def disable_dashing @disable_dashing end |
#display_name ⇒ Object
Returns the value of attribute display_name.
29 30 31 |
# File 'lib/rpg/map.rb', line 29 def display_name @display_name end |
#encounter_list ⇒ Object
Returns the value of attribute encounter_list.
42 43 44 |
# File 'lib/rpg/map.rb', line 42 def encounter_list @encounter_list end |
#encounter_step ⇒ Object
Returns the value of attribute encounter_step.
43 44 45 |
# File 'lib/rpg/map.rb', line 43 def encounter_step @encounter_step end |
#events ⇒ Object
Returns the value of attribute events.
52 53 54 |
# File 'lib/rpg/map.rb', line 52 def events @events end |
#height ⇒ Object
Returns the value of attribute height.
32 33 34 |
# File 'lib/rpg/map.rb', line 32 def height @height end |
#note ⇒ Object
Returns the value of attribute note.
50 51 52 |
# File 'lib/rpg/map.rb', line 50 def note @note end |
#parallax_loop_x ⇒ Object
Returns the value of attribute parallax_loop_x.
45 46 47 |
# File 'lib/rpg/map.rb', line 45 def parallax_loop_x @parallax_loop_x end |
#parallax_loop_y ⇒ Object
Returns the value of attribute parallax_loop_y.
46 47 48 |
# File 'lib/rpg/map.rb', line 46 def parallax_loop_y @parallax_loop_y end |
#parallax_name ⇒ Object
Returns the value of attribute parallax_name.
44 45 46 |
# File 'lib/rpg/map.rb', line 44 def parallax_name @parallax_name end |
#parallax_show ⇒ Object
Returns the value of attribute parallax_show.
49 50 51 |
# File 'lib/rpg/map.rb', line 49 def parallax_show @parallax_show end |
#parallax_sx ⇒ Object
Returns the value of attribute parallax_sx.
47 48 49 |
# File 'lib/rpg/map.rb', line 47 def parallax_sx @parallax_sx end |
#parallax_sy ⇒ Object
Returns the value of attribute parallax_sy.
48 49 50 |
# File 'lib/rpg/map.rb', line 48 def parallax_sy @parallax_sy end |
#scroll_type ⇒ Object
Returns the value of attribute scroll_type.
33 34 35 |
# File 'lib/rpg/map.rb', line 33 def scroll_type @scroll_type end |
#specify_battleback ⇒ Object
Returns the value of attribute specify_battleback.
34 35 36 |
# File 'lib/rpg/map.rb', line 34 def specify_battleback @specify_battleback end |
#tileset_id ⇒ Object
Returns the value of attribute tileset_id.
30 31 32 |
# File 'lib/rpg/map.rb', line 30 def tileset_id @tileset_id end |
#width ⇒ Object
Returns the value of attribute width.
31 32 33 |
# File 'lib/rpg/map.rb', line 31 def width @width end |