Difference between revisions of "Connection Panels"

From Official Barotrauma Wiki
Jump to: navigation, search
BTGamepedia>@DeletedUser40580494
m (fixed some links)
m (10 revisions imported)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Cleanup}}
+
#REDIRECT [[Wiring]]
Some items and devices have a connection panel where wires can be plugged in. The panels can have several different inputs and outputs, some sending signals out depending on the state of the item and some controlling the item in one way or another.
 
 
 
Here's a list [[item components]] that can send or receive signals, and the different inputs and outputs of those components:
 
 
 
==== Any Itemcomponent ====
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|activate, use
 
|input
 
|Uses the item whenever a signal is received. The effect is dependent on which type of itemcomponent it is and what kind of effects are assigned to the connection in the configuration file of the item.
 
|
 
|}
 
 
 
==== Powered ====
 
All items that require power either have the "powered" item component or some subclass of it (OxygenGenerator, Pump, Engine...)
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|power_in, power
 
|input
 
|Delivers power to the item, or in case of items with the PowerContainer or PowerTransfer component (Batteries, Junction Boxes), distributes it to other connected items. Power connections don't work with signal connections: connecting a power connection to a signal connection or vice versa does nothing.
 
|
 
|}
 
 
 
==== [[:Category:Electrical Components|Electrical Components]] ====
 
The connections in the electrical components are explained [[:Category:Electrical Components|on their separate page]].
 
 
 
==== Controller ====
 
Controller is a component that can make an item control other items. The most common use of the controller component are buttons.
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|signal_out
 
|output
 
|Sends out "1" when the item is selected
 
|
 
|-
 
|trigger_out
 
|output
 
|Sends out "1" if the item is selected and the user left clicks. Used in railgun controllers for example: when the user wants to fire, the the component sends out a signal to the railgun
 
|
 
|-
 
|position_out
 
|output
 
|Sends out the cursor position of the user and focuses the camera on the connected item if the FocusOnSelected attribute of the item is set to true. Used in railgun controllers for aiming the railgun.
 
|
 
|}
 
 
 
==== [[Doors|Door]] ====
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|toggle
 
|input
 
|Closes/opens the door when any signal is received
 
|
 
|-
 
|set_state
 
|input
 
|Closes the door when a signal "0" is received and opens it whenever any other signal is received
 
|
 
|-
 
|state_out
 
|output
 
|Sends out "0" if the door is closed and "1" if it is open
 
|
 
|}
 
 
 
==== [[Pump]] ====
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|toggle
 
|input
 
|Turns the pump on/off whenever a signal is received
 
|
 
|-
 
|set_active
 
|input
 
|Turns the pump off when a signal "0" is received, and opens it when any other signal is received
 
|
 
|-
 
|set_speed
 
|input
 
|Sets the speed of the pump to the received value. The value is clamped between -100.0 and 100.0
 
|
 
|-
 
|set_targetlevel
 
|input
 
|Sets the target water level in the room to the received value. 0.0 means that the pump will try to empty the room completely, 50 means that it will try to fill the room half way and 100.0 means that it will try to fill the entire room with water. The value is clamped between 0.0 and 100.0
 
|
 
|}
 
 
 
==== '''Steering''' ====
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|velocity_x_out
 
|output
 
|Sends out the amount of steering along the x-axis. Clamped between -100.0 and 100.0 For example, if the submarine is being steered at full speed to the right, the output signal is 100.0. The most common use is to send the signal to the engine the move the submarine forwards and backwards.
 
|
 
|-
 
|velocity_y_out
 
|output
 
|Sends out the amount of steering along the y-axis, where down is the positive direction. Clamped between -100.0 and 100.0. For example, if the submarine is being steered straight down, the output signal is 100.0. The most common use is to send the signal to the set_targetlevel inputs of some pumps, making them fill up ballast tanks when diving and empty them when moving upwards.
 
|
 
|-
 
|velocity_in
 
|input
 
|Sets the steering velocity to the received value. The signal must contain the x-speed and y-speed separated with a comma, e.g. "-50,10".
 
|
 
|}
 
 
 
==== Engine ====
 
Controller is a component that can make an item control other items. The most common use of the controller component are buttons.
 
{| class="wikitable"
 
!Label
 
!Type
 
!Description
 
!
 
|-
 
|set_force
 
|input
 
|Sets the direction and power at which the engine tries to push the submarine. Clamped between -100.0 and 100.0. A signal of "100.0" would make the engine push the submarine forwards at full speed (assuming there is enough power) and "-100.0" backwards.
 
|
 
|}
 

Latest revision as of 21:38, 12 November 2020

Redirect to: