Directional windows (#5195)

This commit is contained in:
mirrorcult
2021-11-06 17:12:42 -07:00
committed by GitHub
parent afeb22ccb2
commit 198933a513
12 changed files with 241 additions and 1 deletions

View File

@@ -10,7 +10,7 @@
fixtures:
- shape:
!type:PhysShapeAabb
bounds: "-0.49,-0.49,0.49,-0.2"
bounds: "-0.49,-0.49,0.49,-0.3"
mass: 50
layer:
- Impassable

View File

@@ -40,3 +40,38 @@
trackAllDamage: true
damageOverlay:
sprite: Structures/Windows/cracks.rsi
- type: entity
id: PlasmaWindowDirectional
parent: WindowDirectional
name: directional plasma window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: plasma_window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: plasma_window
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 200
behaviors:
- !type:PlaySoundBehavior
sound:
collection: GlassBreak
- !type:SpawnEntitiesBehavior
spawn:
ShardGlassPlasma:
min: 1
max: 2
- !type:DoActsBehavior
acts: [ "Destruction" ]

View File

@@ -40,3 +40,38 @@
trackAllDamage: true
damageOverlay:
sprite: Structures/Windows/cracks.rsi
- type: entity
id: WindowReinforcedDirectional
parent: WindowDirectional
name: directional reinforced window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: reinforced_window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: reinforced_window
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 150
behaviors:
- !type:PlaySoundBehavior
sound:
collection: GlassBreak
- !type:SpawnEntitiesBehavior
spawn:
ShardGlassReinforced:
min: 1
max: 2
- !type:DoActsBehavior
acts: [ "Destruction" ]

View File

@@ -43,3 +43,41 @@
trackAllDamage: true
damageOverlay:
sprite: Structures/Windows/cracks.rsi
- type: entity
id: PlasmaReinforcedWindowDirectional
parent: WindowDirectional
name: directional reinforced plasma window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: plasma_reinforced_window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: plasma_reinforced_window
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 600
behaviors:
- !type:PlaySoundBehavior
sound:
collection: GlassBreak
- !type:SpawnEntitiesBehavior
spawn:
ShardGlassPlasma:
min: 1
max: 2
PartRodMetal:
min: 1
max: 2
- !type:DoActsBehavior
acts: [ "Destruction" ]

View File

@@ -65,3 +65,100 @@
trackAllDamage: true
damageOverlay:
sprite: Structures/Windows/cracks.rsi
- type: entity
id: WindowDirectional
parent: BaseStructure
name: directional window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: window
- type: Physics
fixtures:
- shape:
!type:PhysShapeAabb
bounds: "-0.49,-0.49,0.49,-0.3"
mass: 50
layer:
- Impassable
- MobImpassable
- VaultImpassable
- SmallImpassable
mask:
- VaultImpassable
- type: Repairable
- type: Damageable
damageContainer: Inorganic
damageModifierSet: Glass
- type: Destructible
thresholds:
- trigger:
!type:DamageTrigger
damage: 50
behaviors:
- !type:PlaySoundBehavior
sound:
collection: GlassBreak
- !type:SpawnEntitiesBehavior
spawn:
ShardGlass:
min: 1
max: 2
- !type:DoActsBehavior
acts: [ "Destruction" ]
- type: Airtight
noAirWhenFullyAirBlocked: false
airBlockedDirection:
- South
- type: Window
- type: entity
id: WindowTintedDirectional
parent: WindowDirectional
name: directional tinted window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: tinted_window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: tinted_window
- type: Occluder
boundingBox: "-0.5,-0.5,0.5,-0.3"
- type: entity
id: WindowFrostedDirectional
parent: WindowDirectional
name: directional frosted window
description: Don't smudge up the glass down there.
placement:
mode: SnapgridCenter
snap:
- Window
components:
- type: Sprite
netsync: false
drawdepth: WallTops
sprite: Structures/Windows/directional.rsi
state: frosted_window
- type: Icon
sprite: Structures/Windows/directional.rsi
state: frosted_window