Rooms are the entities that contain all the copies, backgrounds, tile layers, and advanced entities, too. They are also referred to as maps and levels.
Rooms derive from PIXI.Container class, and inherit all its methods and properties.
The current room,
ct.room always points to the current room. If you have multiple rooms layered on top of each other,
ct.room will point to the initial room that was created at the start of a game, or after calling
UI and Gameplay rooms
Rooms can be put either into UI coordinate space or gameplay coordinate space. Gameplay rooms are managed by
ct.camera, and cannot be moved manually. But UI rooms can be: for example, to move smaller widgets around the viewport.
|A value from 0 to 1 that sets the room's opacity. You can use it, for example, to gradually fade in/fade out UI layers. |
|If set to |
|The location of a room. Changing these has no effect if the room is in gameplay coordinates (if its |