Server Events

From Tygron Preview Support Wiki
Jump to navigation Jump to search
Please note: This page is currently being updated.

Template:Learned

What is a Server Event

Main article: Events

Server events are events which are communicated to the server, and may affect all stakeholders. An example of this is the activation of a measure. These events may affect the 3D world and the indicator scores.

How do Server Events relate to the Tygron Engine

Server Events can be used in multiple locations in the Tygron Engine; as part of a measure, at the start of a level, as part of a larger event bundle in the action menu, etc. Server Events allow for events to be triggered during a session, which will result in a reaction from the server.

Different Server Event types

There are two flavors of Server Events: Logic Events and Player Events. The difference between these is that for Player Events at least one dedicated stakeholder needs to be assigned to the Server Event. A good example of this is the asking for or receiving of a money transfer (MONEY_TRANSFER_ASK & MONEY_TRANSFER_GIVE) as a Server Event. Logic Events do not require such a dedicated stakeholder and can be fired without one being assigned as property. A good example of this is the activation of a specific terrain type (TERRAIN_SET_ACTIVE) when creating a flooding as part of a measure.

Logic Event Types

ACTION_MENU_SET_FUNCTION_AVAILABLE

ACTION_MENU_SET_MEASURE_AVAILABLE

ACTION_MENU_SET_UPGRADE_AVAILABLE

BEAMER_SET_LAYER

CINEMATIC_STAKEHOLDER_START

CINEMATIC_STAKEHOLDER_STOP

LEVEL_SET_ACTIVE

MEASURE_UPDATE_CUSTOM

MESSAGE_ACTIVATE

MESSAGE_REVOKE

MESSAGE_RESET

SETTINGS_ALLOW_GAME_INTERACTION

SETTINGS_SET_MESSAGE_AUTO_RESPOND

SPECIAL_EFFECT_SET_ACTIVE

TERRAIN_SET_ACTIVE

TERRAIN_SET_POLYGON

TIME_SET_SIM_MULTIPLIER

UNIT_SET_ACTIVE

WEATHER_SET_DATA

ZOOMLEVEL_SET_ACTIVE

Player Event Types

ACTION_MENU_SET_ACTIVE

MEASURE_CANCEL_CONSTRUCTION

MEASURE_PLAN_CONSTRUCTION

MESSAGE_NEW

MONEY_TRANSFER_ASK

MONEY_TRANSFER_GIVE

SETTINGS_SET_ALLOWED_WATER_LEVEL_INCREASE

Adding Server Side Events to a project

Changing the properties of a Server Side Event in a project