Dream is a mystery themed package which allows you to change the whole world state dynamically!
Creare multiple realities, multi-dimensinal universes or detective stories. It’s up to your imagination how the Dream can be used.
Made for Build Jam - Science Fair
Author: Elfwy
Features
- UNLIMITED WORLDS - Count of worlds you want to create in your game is unlimited. Each world state is a separate script dragged into the User template.
- TRANSITION EFFECT - Meet the first nice transition - spooky bats covering the screen to make world change process seamless.
- API - The first version of the package contains everything necessary to communicate with it excluding any problems.
Installation & Easy setup
2. Drag 'Dream' from templates tab to the User template.
3. Drag 'DreamTriggerExample' to the layout.
Your test level is ready!
Scripts
-
dreamScriptUser / SCRIPT — This is the core script, contains most logic and API. Use on user only.
-
dreamState / SCRIPT — This is a state declaration. Drag this script to the User template and get it a name. Now you can edit all its properties as you wish, they will automatically apply on update. Each new script is a separate state.
-
dreamEntityFlag / SCRIPT — Drag this script to an entity and it will become a part of the state system. Use one or multiple state names in the stateName property and the whole hierarchy will be appeared when the state(s) are active. Supported: CharacterBase, Effect, Light, Locator, Mesh, Shape, Sound, Trigger, VoxelMesh.
API
-
Dream_UpdateState — Set current state.
user.DreamScriptUser:Dream_UpdateState(stateName String)
-
Dream_SwitchState — Switch between two states. If current is not one of those, set to the first.
user.DreamScriptUser:Dream_SwitchState(firstState String, secondState String)
-
Dream_GetState — Get current state.
user.DreamScriptUser:Dream_GetState()
-
Dream_GetEntities — Get all active entities for given state.
user.DreamScriptUser:Dream_GetEntities(stateName String)
Note
- The package doesn’t support changing local states for each player separately yet.