Client LuaCsForBarotrauma
BarotraumaShared/SharedSource/Items/Components/ItemLabel.cs
1
using
Barotrauma
.
Networking
;
2
using
Microsoft.Xna.Framework;
3
4
namespace
Barotrauma.Items.Components
5
{
6
partial class
ItemLabel
:
ItemComponent
,
IDrawableComponent
,
IServerSerializable
7
{
8
public
Vector2
DrawSize
9
{
10
//use the extents of the item as the draw size
11
get
{
return
Vector2.Zero; }
12
}
13
14
partial
void
OnStateChanged();
15
16
private
string
prevColorSignal;
17
18
public
override
void
ReceiveSignal
(
Signal
signal,
Connection
connection)
19
{
20
switch
(connection.
Name
)
21
{
22
case
"set_text"
:
23
if
(
Text
== signal.
value
) {
return
; }
24
Text
= signal.
value
;
25
OnStateChanged();
26
break
;
27
case
"set_text_color"
:
28
if
(signal.
value
!= prevColorSignal)
29
{
30
TextColor
= XMLExtensions.ParseColor(signal.
value
,
false
);
31
prevColorSignal = signal.
value
;
32
}
33
break
;
34
}
35
}
36
}
37
}
Barotrauma.Items.Components.Connection
Definition:
BarotraumaShared/SharedSource/Items/Components/Signal/Connection.cs:10
Barotrauma.Items.Components.Connection.Name
readonly string Name
Definition:
BarotraumaShared/SharedSource/Items/Components/Signal/Connection.cs:20
Barotrauma.Items.Components.ItemComponent
The base class for components holding the different functionalities of the item
Definition:
BarotraumaShared/SharedSource/Items/Components/ItemComponent.cs:35
Barotrauma.Items.Components.ItemLabel
Definition:
BarotraumaShared/SharedSource/Items/Components/ItemLabel.cs:7
Barotrauma.Items.Components.ItemLabel.TextColor
Color TextColor
Definition:
BarotraumaClient/ClientSource/Items/Components/ItemLabel.cs:84
Barotrauma.Items.Components.ItemLabel.DrawSize
Vector2 DrawSize
Definition:
BarotraumaShared/SharedSource/Items/Components/ItemLabel.cs:9
Barotrauma.Items.Components.ItemLabel.ReceiveSignal
override void ReceiveSignal(Signal signal, Connection connection)
Definition:
BarotraumaShared/SharedSource/Items/Components/ItemLabel.cs:18
Barotrauma.Items.Components.ItemLabel.Text
string Text
Definition:
BarotraumaClient/ClientSource/Items/Components/ItemLabel.cs:46
Barotrauma.Items.Components.IDrawableComponent
Definition:
BarotraumaShared/SharedSource/Items/Components/ItemComponent.cs:20
Barotrauma.Networking.IServerSerializable
Interface for entities that the server can send events to the clients
Definition:
INetSerializable.cs:22
Barotrauma.Items.Components
Definition:
BarotraumaShared/SharedSource/Items/Components/DockingPort.cs:15
Barotrauma.Networking
Definition:
LuaBarotraumaAdditions.cs:9
Barotrauma
Definition:
AchievementManager.cs:12
Barotrauma.Items.Components.Signal
Definition:
Signal.cs:4
Barotrauma.Items.Components.Signal.value
string value
Definition:
Signal.cs:5
Barotrauma
BarotraumaShared
SharedSource
Items
Components
ItemLabel.cs
Generated by
1.9.1