The data class for common events.
The event ID.
The event name.
The event trigger (0: none, 1: autorun; 2: parallel).
The condition switch ID.
A list of event commands. An RPG::EventCommand array.
Determines whether the event is an autorun event. Returns true if the value of the trigger is 1.
Determines whether the event is a parallel event. Returns true if the value of the trigger is 2.
class RPG::CommonEvent
def initialize
@id = 0
@name = ''
@trigger = 0
@switch_id = 1
@list = [RPG::EventCommand.new]
end
def autorun?
@trigger == 1
end
def parallel?
@trigger == 2
end
attr_accessor :id
attr_accessor :name
attr_accessor :trigger
attr_accessor :switch_id
attr_accessor :list
end