Re-anchorable structures (#39542)
* Initial commit * Reverted reinvention of an existing feature... * Fixed two missed entries * Added extra examine check * AI core and high security doors visuals snap to always face south
This commit is contained in:
@@ -2,7 +2,6 @@ using Content.Shared.Construction.EntitySystems;
|
||||
using Content.Shared.Tools;
|
||||
using Robust.Shared.GameStates;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
|
||||
|
||||
namespace Content.Shared.Construction.Components
|
||||
{
|
||||
|
||||
@@ -102,6 +102,13 @@ public sealed partial class AnchorableSystem : EntitySystem
|
||||
private void OnAnchoredExamine(EntityUid uid, AnchorableComponent component, ExaminedEvent args)
|
||||
{
|
||||
var isAnchored = Comp<TransformComponent>(uid).Anchored;
|
||||
|
||||
if (isAnchored && (component.Flags & AnchorableFlags.Unanchorable) == 0x0)
|
||||
return;
|
||||
|
||||
if (!isAnchored && (component.Flags & AnchorableFlags.Anchorable) == 0x0)
|
||||
return;
|
||||
|
||||
var messageId = isAnchored ? "examinable-anchored" : "examinable-unanchored";
|
||||
args.PushMarkup(Loc.GetString(messageId, ("target", uid)));
|
||||
}
|
||||
|
||||
@@ -170,6 +170,10 @@
|
||||
- AiHolder
|
||||
suffix: Empty
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: WarpPoint
|
||||
blacklist:
|
||||
tags:
|
||||
@@ -195,6 +199,7 @@
|
||||
- type: StationAiVision
|
||||
- type: InteractionOutline
|
||||
- type: Sprite
|
||||
snapCardinals: true
|
||||
sprite: Mobs/Silicon/station_ai.rsi
|
||||
layers:
|
||||
- state: base
|
||||
|
||||
@@ -5,6 +5,10 @@
|
||||
name: sentry turret
|
||||
description: A high-tech autonomous weapons system designed to keep unauthorized personnel out of sensitive areas.
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Fixtures
|
||||
fixtures:
|
||||
body:
|
||||
|
||||
@@ -4,6 +4,10 @@
|
||||
name: airlock
|
||||
description: It opens, it closes, and maybe crushes you.
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: StationAiWhitelist
|
||||
- type: MeleeSound
|
||||
soundGroups:
|
||||
|
||||
@@ -6,9 +6,14 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: StationAiWhitelist
|
||||
- type: InteractionOutline
|
||||
- type: Sprite
|
||||
snapCardinals: true
|
||||
sprite: Structures/Doors/Airlocks/highsec/highsec.rsi
|
||||
layers:
|
||||
- state: closed
|
||||
|
||||
@@ -5,6 +5,10 @@
|
||||
name: firelock
|
||||
description: Apply crowbar.
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: AtmosAlarmable
|
||||
syncWith:
|
||||
- FireAlarm
|
||||
|
||||
@@ -5,6 +5,10 @@
|
||||
abstract: true
|
||||
description: A door, where will it lead?
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: InteractionOutline
|
||||
- type: Sprite
|
||||
sprite: Structures/Doors/MineralDoors/metal_door.rsi
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
abstract: true
|
||||
description: Keeps the air in and the greytide out.
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Sprite
|
||||
sprite: Structures/Doors/secret_door.rsi
|
||||
layers:
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: StationAiWhitelist
|
||||
- type: Sprite
|
||||
sprite: Structures/Doors/Shutters/shutters.rsi
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: MeleeSound
|
||||
soundGroups:
|
||||
Brute:
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
snap:
|
||||
- Wallmount
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Physics
|
||||
canCollide: false
|
||||
- type: Clickable
|
||||
|
||||
@@ -9,6 +9,10 @@
|
||||
snap:
|
||||
- Wall
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: RangedDamageSound
|
||||
soundGroups:
|
||||
Brute:
|
||||
|
||||
@@ -8,6 +8,10 @@
|
||||
snap:
|
||||
- Window
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: MeleeSound
|
||||
soundGroups:
|
||||
Brute:
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Clickable
|
||||
- type: Sprite
|
||||
sprite: Structures/catwalk.rsi
|
||||
|
||||
@@ -4,6 +4,10 @@
|
||||
name: cryogenic sleep unit
|
||||
description: A super-cooled container that keeps crewmates safe during space travel.
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Sprite
|
||||
noRot: true
|
||||
sprite: Structures/cryostorage.rsi
|
||||
|
||||
@@ -5,6 +5,10 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Sprite
|
||||
sprite: Structures/plastic_flaps.rsi
|
||||
state: plasticflaps
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
placement:
|
||||
mode: SnapgridCenter
|
||||
components:
|
||||
- type: Anchorable
|
||||
flags:
|
||||
- Anchorable
|
||||
- type: Rotatable
|
||||
- type: Clickable
|
||||
- type: Sprite
|
||||
sprite: Structures/stairs.rsi
|
||||
|
||||
Reference in New Issue
Block a user