GameMaker (2.0 - 2.2.x)

GMS Event Framework


You must be logged in to obtain assets


GMS2 Event Framework

Implement Event-driven Architecture in Game Maker!

Event-driven Architecture is perfect for ensuring that: - Events (significant changes in program state) are checked for only once (as opposed to multiple times from different instances)

  • Single Responsibility Principle can be applied, avoid to perform several non-related tasks in a checking object.

In a nutshell, using events ensures that one instance emits an event, and all responsible instances are alerted so they can perform their tasks for that event occurrence.

V1.2 UPDATES - Replaced Event object with ds_map - Added possibility to listen to events emitted from specific instance/object, from lists and maps of instances/objects - Replaced Event Data array which argument list for more natural callback handling - Fixed bugs and optimized data structures

How it works 0. The programmer (you) sets up Event Types in an enum (initEventTypes script) for any kind of event of relevance

  1. One or several instances listen for occurrences of an Event Type (e.g. a mouse click), providing a callback script for the event

  2. An instance emits an event of a specific type, including related data

  3. The EventManager triggers the callback for all listeners for that event

Docs: Usage Example:

End User Licence Agreement (EULA).

Age Rating: 4+


GMS2 - Version 1.2.2. Published January 19, 2020

Loading, please wait

Package contents

Loading, please wait

What is the issue?

Loading, please wait