forked from space-wizards/space-station-14
-
Notifications
You must be signed in to change notification settings - Fork 161
/
Copy pathSubdermalImplantComponent.cs
96 lines (75 loc) · 2.5 KB
/
SubdermalImplantComponent.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
using Content.Shared.Actions;
using Content.Shared.Whitelist;
using Robust.Shared.GameStates;
using Robust.Shared.Prototypes;
namespace Content.Shared.Implants.Components;
/// <summary>
/// Subdermal implants get stored in a container on an entity and grant the entity special actions
/// The actions can be activated via an action, a passive ability (ie tracking), or a reactive ability (ie on death) or some sort of combination
/// They're added and removed with implanters
/// </summary>
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
public sealed partial class SubdermalImplantComponent : Component
{
/// <summary>
/// Used where you want the implant to grant the owner an instant action.
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
[DataField("implantAction")]
public EntProtoId? ImplantAction;
[DataField, AutoNetworkedField]
public EntityUid? Action;
/// <summary>
/// The entity this implant is inside
/// </summary>
[ViewVariables, AutoNetworkedField]
public EntityUid? ImplantedEntity;
/// <summary>
/// Should this implant be removeable?
/// </summary>
[ViewVariables(VVAccess.ReadWrite)]
[DataField("permanent"), AutoNetworkedField]
public bool Permanent = false;
/// <summary>
/// Target whitelist for this implant specifically.
/// Only checked if the implanter allows implanting on the target to begin with.
/// </summary>
[DataField]
public EntityWhitelist? Whitelist;
/// <summary>
/// Target blacklist for this implant specifically.
/// Only checked if the implanter allows implanting on the target to begin with.
/// </summary>
[DataField]
public EntityWhitelist? Blacklist;
}
public sealed partial class UseChemicalImplantEvent : InstantActionEvent
{
}
/// <summary>
/// Used for opening the storage implant via action.
/// </summary>
public sealed partial class OpenStorageImplantEvent : InstantActionEvent
{
}
public sealed partial class UseFreedomImplantEvent : InstantActionEvent
{
}
/// <summary>
/// Used for triggering trigger events on the implant via action
/// </summary>
public sealed partial class ActivateImplantEvent : InstantActionEvent
{
}
/// <summary>
/// Used for opening the uplink implant via action.
/// </summary>
public sealed partial class OpenUplinkImplantEvent : InstantActionEvent
{
}
public sealed partial class UseScramImplantEvent : InstantActionEvent
{
}
public sealed partial class UseDnaScramblerImplantEvent : InstantActionEvent
{
}