Add security barriers (#4458)
* Add sprites * Lock system now raises lock toggle events * Add prototype and barrier system * Toggle lock on click * Barrier blocks bullets (like a real wall) * Barrier now destroyable * Fancy visualzer and lighting. Also unlock by default * Deleted comma * Ignored components? * Update Resources/Prototypes/Entities/Objects/Specific/Security/barrier.yml Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> * Update Resources/Prototypes/Entities/Objects/Specific/Security/barrier.yml Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> * Toggle Lock no longer handled * Made it much easier to move through airlocks Co-authored-by: Swept <sweptwastaken@protonmail.com> Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,55 @@
|
||||
- type: entity
|
||||
name: deployable barrier
|
||||
id: DeployableBarrier
|
||||
description: A deployable barrier. Swipe your ID card to lock/unlock it.
|
||||
parent: BaseStructure
|
||||
components:
|
||||
- type: Sprite
|
||||
sprite: Objects/Specific/Security/barrier.rsi
|
||||
netsync: false
|
||||
state: idle
|
||||
- type: InteractionOutline
|
||||
- type: Physics
|
||||
fixtures:
|
||||
- shape:
|
||||
!type:PhysShapeCircle
|
||||
radius: 0.45
|
||||
layer:
|
||||
- Opaque
|
||||
- Impassable
|
||||
- VaultImpassable
|
||||
- SmallImpassable
|
||||
mask:
|
||||
- Impassable
|
||||
mass: 150
|
||||
- type: AccessReader
|
||||
access: [["Security"]]
|
||||
- type: Lock
|
||||
locked: false
|
||||
lockOnClick: true # toggle lock just by clicking on barrier
|
||||
- type: DeployableBarrier
|
||||
- type: Damageable
|
||||
resistances: metallicResistances
|
||||
- type: Destructible
|
||||
thresholds:
|
||||
- trigger:
|
||||
!type:DamageTrigger
|
||||
damage: 300
|
||||
behaviors:
|
||||
- !type:SpawnEntitiesBehavior
|
||||
spawn:
|
||||
SheetSteel:
|
||||
min: 5
|
||||
max: 5
|
||||
- !type:PlaySoundBehavior
|
||||
sound:
|
||||
path: /Audio/Effects/metalbreak.ogg
|
||||
- !type:DoActsBehavior
|
||||
acts: [ "Destruction" ]
|
||||
- type: PointLight
|
||||
enabled: false
|
||||
radius: 3
|
||||
color: red
|
||||
- type: Appearance
|
||||
visuals:
|
||||
- type: DeployableBarrierVisualizer
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 1.4 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 824 B |
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"version": 1,
|
||||
"size": {
|
||||
"x": 32,
|
||||
"y": 32
|
||||
},
|
||||
"license": "CC-BY-SA-3.0",
|
||||
"copyright": "Taken from cev-eris at https://github.com/discordia-space/CEV-Eris/commit/476e374cea95ff5e8b1603c48342bf700e2cd7af",
|
||||
"states": [
|
||||
{
|
||||
"name": "idle"
|
||||
},
|
||||
{
|
||||
"name": "deployed",
|
||||
"delays": [
|
||||
[
|
||||
0.1,
|
||||
0.1,
|
||||
0.1,
|
||||
0.1,
|
||||
0.5
|
||||
]
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user