Skip to content
Sebioff edited this page Sep 4, 2020 · 13 revisions

Deco objects are static objects that serve no other purpose than for decoration. For example trees, vases and other plants or deco objects.

Color settings

Every object support custom colors. Check this page for more info on custom color settings.

Placement settings

Build on grid: whether this object can only be built on the grid (on) or can be placed freely (off).

Snaps to center: whether this objects is snapped to the center of a tile (on) or the corner (off) by default.

Grid subdivision: by default the placement grid of an object is the same size as 1 tile. This setting can make the placement grid smaller than a tile. A value of 3 will create a 3x3 grid within 1 tile.

Height delta: the step size when the player raises/lowers the object. Most objects included with the game use a value of 0.25, so to make sure everything fits nicely together your custom objects should only change this if there's a good reason for it.

Size settings

Is resizable: whether this object is resizable.

If Is resizable is enabled, players can resize the object in the game. The object will always have a size of 1 by default which is the same size as shown in the asset editor.

Min size: Any value lower than 1 will mean that the player can make the object smaller by a maximum of this value. For example: a value of 0.2 means the player can make the object 5 times smaller.

Max size: Any value higher than 1 will mean that the player can make the object larger by a maximum of this value. For example: a value of 7 means the player can make the object 7 times larger.

Visibility settings

Can see through: whether guests can "see through" this object (on) or whether it blocks the view (off). Should be on for most objects, especially small props or details. Only walls or bigger deco objects that roughly fill an entire tile should disable this to block the view.

Blocks rain: whether guests are protected from rain while they are under this object (on) or not (off). Should be disabled for most objects. Only roofs or objects that fulfill a similar purpose (e.g. pavillions) should enable this.

Animations

It is possible to trigger animations with the Effects Controller, for example when a person walks across a path or a train crosses a track segment. To make your animations able to get triggered, you need to:

  1. make sure that your object has an Animator at its root (add an Animator component in the Inspector tab for your object if it does not have one yet)
  2. assign a Controller to the Animator. There is an example Controller located at Assets/Resources/Triggered Objects/TriggeredObjectAnimator.controller that you can duplicate or modify.
  3. Put your animation into the "Run" state, and assign another animation to the "Idle" state if you want. There are two trigger parameters that get sent to your controller: TriggerStart whenever your animation gets triggered, and TriggerEnd whenever the trigger for your animation is finished. In this example controller only TriggerStart is used to transition from the Idle to the Run state. TriggerEnd is not being used, the controller simply returns to the Idle state once the animation in the Run state is finished (especially if you're using a looping animation with a duration that can be configured by the player you should use TriggerEnd to return to the Idle state). You can modify this if you want (for example by adding multiple states to play a different animation each time the object gets triggered or similar things).
  4. In the asset editor for your deco object, an "Animation trigger" section is available for objects that have an Animator component. Simply check the Animation can be triggered checkbox to make your object triggerable. If you want players to be able to change how long the animation can be played (which is mostly useful for looping animations) you can also check the Customizable animation duration checkbox.

Your animation controller also receives a float value named TriggerRandom. This value is set to a new random value between 0 and 1 each time your animation gets triggered. You could for example use this to randomly play a different animation each time your object gets triggered.

Clone this wiki locally