Class: RPG::CommonEvent
- Inherits:
-
Object
- Object
- RPG::CommonEvent
- Extended by:
- RgssDb::JsonableConstructor
- Includes:
- RgssDb::Jsonable
- Defined in:
- lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb,
lib/rgss_db/model/rpg_maker_data/xp/rpg/common_event.rb,
lib/rgss_db/model/rpg_maker_data/vx_ace/rpg/common_event.rb
Overview
The data class for common events.
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#list ⇒ Object
Returns the value of attribute list.
-
#name ⇒ Object
Returns the value of attribute name.
-
#switch_id ⇒ Object
Returns the value of attribute switch_id.
-
#trigger ⇒ Object
Returns the value of attribute trigger.
Instance Method Summary collapse
- #autorun? ⇒ Boolean
-
#initialize ⇒ CommonEvent
constructor
A new instance of CommonEvent.
- #parallel? ⇒ Boolean
- #to_s ⇒ Object
Methods included from RgssDb::JsonableConstructor
Methods included from RgssDb::Jsonable
Constructor Details
#initialize ⇒ CommonEvent
Returns a new instance of CommonEvent.
11 12 13 14 15 16 17 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 11 def initialize @id = 0 @name = "" @trigger = 0 @switch_id = 1 @list = [RPG::EventCommand.new] end |
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 23 def id @id end |
#list ⇒ Object
Returns the value of attribute list.
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 23 def list @list end |
#name ⇒ Object
Returns the value of attribute name.
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 23 def name @name end |
#switch_id ⇒ Object
Returns the value of attribute switch_id.
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 23 def switch_id @switch_id end |
#trigger ⇒ Object
Returns the value of attribute trigger.
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 23 def trigger @trigger end |
Instance Method Details
#autorun? ⇒ Boolean
19 20 21 |
# File 'lib/rgss_db/model/rpg_maker_data/vx_ace/rpg/common_event.rb', line 19 def autorun? @trigger == 1 end |
#parallel? ⇒ Boolean
23 24 25 |
# File 'lib/rgss_db/model/rpg_maker_data/vx_ace/rpg/common_event.rb', line 23 def parallel? @trigger == 2 end |
#to_s ⇒ Object
19 20 21 |
# File 'lib/rgss_db/model/rpg_maker_data/vx/rpg/common_event.rb', line 19 def to_s @name.to_s end |