I am using this script to trigger a common event by pressing a key, and it works fine! But now my question is this: is there anyway to assign a different key to trigger a different common event? (i.e: Pressing L triggers common event 7, pressing R trigger common event 8, and so on).
This is the script:
class Scene_Map < Scene_Base # Common Event trigger key CallCommonEventKey = Input::L # Common Event ID to trigger CallCommonEventID = 7 # Frame Update alias sawnik_update :update def update sawnik_update update_common_event_trigger end # Update Common Event Trigger Check def update_common_event_trigger if not $game_message.visible and Input.trigger?(CallCommonEventKey) $game_temp.common_event_id = CallCommonEventID end endendThank you so much in advance for your time 🙂
This is the script:
class Scene_Map < Scene_Base # Common Event trigger key CallCommonEventKey = Input::L # Common Event ID to trigger CallCommonEventID = 7 # Frame Update alias sawnik_update :update def update sawnik_update update_common_event_trigger end # Update Common Event Trigger Check def update_common_event_trigger if not $game_message.visible and Input.trigger?(CallCommonEventKey) $game_temp.common_event_id = CallCommonEventID end endendThank you so much in advance for your time 🙂