Dual Universe Wiki
Advertisement
Interactive Elements April2017

A sample of Interactive Elements; the player can be seen standing on a sensor, which is triggering the two lights it is connected to.

Interactive Elements are Elements which are able to be linked with their surroundings to perform simple actions without the need for programming. The system is a simple input-output system; a sensor or switch can be hooked up to a light or a door to allow for events to occur when something triggers the sensor or switch.

Inputs[]

Examples:

Pressure Plate

The pressure plate is a sensor which can detect when a player is standing on it. When triggered, it switches between its 2 states (activated or deactivated) and emits the corresponding event.

(infra red) Laser Sensor (Emitter and Receiver)

The laser sensor is able to detect players (or objects) at extended range. The laser extends from the emitter towards the receiver; if it is interupted, it switches between its 2 states (activated if uninterrupted or deactivated if interrupted) and emits the corresponding event.

Manual Button

The manual button is a small element which can be activated by hand. By default it is in a "released" state, but when activated it become in a "pressed" state during a short time and emits the corresponding events. If connected to a Programming Board, it provides the events "pressed()" and "released()", and the function "getState()".

Manual Switch

The manual switch is a small element which can be activated by hand. When activated, it switches between its 2 states (pressed or released) and emits the corresponding event. If connected to a Programming Board, it provides the events "pressed()" and "released()", and the function "getState()".

Outputs[]

Lamp

The lamp is a light source which has 2 states: on and off. A lamp will keep its current state until it receives an opposit instruction..

Force Field

The force field is a solid wall which has 2 states: activated and deactivated. It allows the instantaneous creation and removal of solid walls anywhere that voxels are not present. A force field will keep its current state until it receives an opposit instruction.

Door

A door has 2 states, it can be opened or closed. A door will keep its current state until it receives an opposit instruction. If connected to a Programming Board, it provides the functions "activate()" which open the door and "deactivate()" which (probably) close the door.

Logic Gates[]

In addition to inputs and outputs, there are logic gates. While inputs reside at the beginning of systems and outputs reside at the end, logic gates have their place in the middle of systems where they perform operations based on the state of their inputs. There are currently three logic gates in Dual Universe.

AND gate

Operators pre-alpha
The AND gate accepts two inputs, but will only send an active signal if both of its inputs are active.

XOR gate

A XOR gate can have two inputs, and will send an active signal if one of them activated. When two switches are connected to an XOR gate, which outputs into a light, using either switch will toggle the light. This can be chained to have any amount of switches toggle a light.

NOR gate

A NOR gate can have two inputs, and will send an active signal if neither of them are activated.

NAND gate

A NAND gate can have two inputs, and will send an active signal if either or none of them are activated.

OR gate

An OR gate can have any number of inputs, and will send an active signal if any of them are activated. If three sensors are hooked up to an OR gate, and the gate is connected to a light, triggering one or more sensors will turn on the light.

NOT gate

A NOT gate can have only one input. A NOT gate reverses the state of that input; if a sensor is hooked up to a NOT gate, and the sensor is not being triggered, than the NOT gate will be sending an active signal. As soon as the sensor is triggered, then the NOT gate's signal will deactivate.
Advertisement