Skip to content

Implement an Action

Refer to the StartupRoom.ts in the backend for an example.

  1. Make sure you first created a game object.
  2. Make sure the Action you wish to implement exists.
  3. Add one or more implements for the actions you wish to support, for example: class DungeonRoom extends Room implements Smell, Push.
  4. Implement the required abstract functions and return a type of ActionResult from the functions or undefined.

Relevante instructievideo