Call Common Event Via Scripting?

Would it be possible for me to call a common event (That I created) via rgss?
That depends on where the common event is to occur.

The fieldmap and the default battlesystem are capable of performing common events. Map systems have no mechanism built in to render them.

Now while you can use the [Call Common Event] event command to run a common event, you CAN script something in place like this:

Spoiler
Code:
#==============================================================================
# ** Scene_Battle
#------------------------------------------------------------------------------
#  This class performs battle screen processing.
#==============================================================================

class Scene_Battle
  #--------------------------------------------------------------------------
  # * Public Instance Variables
  #--------------------------------------------------------------------------
  attr_accessor :common                   # common event option
  #--------------------------------------------------------------------------
  # * Alias Listings
  #--------------------------------------------------------------------------
  alias simple_common_event_update_phase4_step6 update_phase4_step6
  #--------------------------------------------------------------------------
  # * Frame Update (main phase step 6 : refresh)
  #--------------------------------------------------------------------------
  def update_phase4_step6
    # If we have a valid value, apply to common event
    if @common != nil
      if @common.is_a(Numeric)
        @common_event_id = @common
      end
      @common = nil
    end
    # Perform the original call
    simple_common_event_update_phase4_step6
  end
end

With that pasted under your battlesystem, you could make a simple script call within a troops page like "$scene.common = 2" and it will run the 2nd common event.

So you CAN run common events via scripts, but it depends on what you are trying to achieve.

OH... and it will only run one common event at a time. There's no 'stacking' of common events.

Original thread: https://forums.rpgmakerweb.com/threads/call-common-event-via-scripting.112200/