Added simple grilles with construction, deconstruction and destruction. (#4801)
This commit is contained in:
committed by
GitHub
parent
f635909d4e
commit
09d40b386a
@@ -8,6 +8,15 @@
|
|||||||
flatReductions:
|
flatReductions:
|
||||||
Blunt: 5
|
Blunt: 5
|
||||||
|
|
||||||
|
# Like metallic, but without flat reduction so it can be damaged with fists.
|
||||||
|
- type: damageModifierSet
|
||||||
|
id: FlimsyMetallic
|
||||||
|
coefficients:
|
||||||
|
Blunt: 0.7
|
||||||
|
Slash: 0.5
|
||||||
|
Piercing: 0.7
|
||||||
|
Shock: 1.2
|
||||||
|
|
||||||
- type: damageModifierSet
|
- type: damageModifierSet
|
||||||
id: Inflatable
|
id: Inflatable
|
||||||
coefficients:
|
coefficients:
|
||||||
|
|||||||
72
Resources/Prototypes/Entities/Structures/Walls/grille.yml
Normal file
72
Resources/Prototypes/Entities/Structures/Walls/grille.yml
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
- type: entity
|
||||||
|
id: Grille
|
||||||
|
parent: BaseStructure
|
||||||
|
name: grille
|
||||||
|
description: A flimsy framework of iron rods.
|
||||||
|
components:
|
||||||
|
- type: Sprite
|
||||||
|
netsync: false
|
||||||
|
drawdepth: Walls
|
||||||
|
sprite: Structures/Walls/grille.rsi
|
||||||
|
state: grille
|
||||||
|
- type: Icon
|
||||||
|
sprite: Structures/Walls/grille.rsi
|
||||||
|
state: grille
|
||||||
|
- type: RCDDeconstructWhitelist
|
||||||
|
- type: Construction
|
||||||
|
graph: grille
|
||||||
|
node: grille
|
||||||
|
deconstructionTarget: start
|
||||||
|
- type: Damageable
|
||||||
|
damageContainer: Inorganic
|
||||||
|
damageModifierSet: FlimsyMetallic
|
||||||
|
- type: Destructible
|
||||||
|
thresholds:
|
||||||
|
- trigger:
|
||||||
|
!type:DamageTrigger
|
||||||
|
damage: 20
|
||||||
|
behaviors:
|
||||||
|
- !type:ChangeConstructionNodeBehavior
|
||||||
|
node: grilleBroken
|
||||||
|
- !type:DoActsBehavior
|
||||||
|
acts: ["Breakage"]
|
||||||
|
|
||||||
|
- type: entity
|
||||||
|
id: GrilleBroken
|
||||||
|
parent: Grille
|
||||||
|
name: grille
|
||||||
|
description: A flimsy framework of iron rods. It has seen better days.
|
||||||
|
components:
|
||||||
|
- type: Sprite
|
||||||
|
netsync: false
|
||||||
|
drawdepth: Walls
|
||||||
|
sprite: Structures/Walls/grille.rsi
|
||||||
|
state: grille_broken
|
||||||
|
- type: Icon
|
||||||
|
sprite: Structures/Walls/grille.rsi
|
||||||
|
state: grille_broken
|
||||||
|
- type: RCDDeconstructWhitelist
|
||||||
|
- type: Construction
|
||||||
|
graph: grille
|
||||||
|
node: grilleBroken
|
||||||
|
deconstructionTarget: start
|
||||||
|
- type: Physics
|
||||||
|
fixtures:
|
||||||
|
- shape:
|
||||||
|
!type:PhysShapeAabb
|
||||||
|
bounds: "-0.45,-0.45,0.45,0.45"
|
||||||
|
mass: 50
|
||||||
|
layer:
|
||||||
|
- Passable
|
||||||
|
mask:
|
||||||
|
- Passable
|
||||||
|
- type: Destructible
|
||||||
|
thresholds:
|
||||||
|
- trigger:
|
||||||
|
!type:DamageTrigger
|
||||||
|
damage: 10
|
||||||
|
behaviors:
|
||||||
|
- !type:ChangeConstructionNodeBehavior
|
||||||
|
node: start
|
||||||
|
- !type:DoActsBehavior
|
||||||
|
acts: ["Destruction"]
|
||||||
44
Resources/Prototypes/Recipes/Construction/Graphs/grille.yml
Normal file
44
Resources/Prototypes/Recipes/Construction/Graphs/grille.yml
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
- type: constructionGraph
|
||||||
|
id: grille
|
||||||
|
start: start
|
||||||
|
graph:
|
||||||
|
- node: start
|
||||||
|
edges:
|
||||||
|
- to: grille
|
||||||
|
completed:
|
||||||
|
- !type:SnapToGrid
|
||||||
|
southRotation: true
|
||||||
|
steps:
|
||||||
|
- material: MetalRod
|
||||||
|
amount: 2
|
||||||
|
doAfter: 1
|
||||||
|
|
||||||
|
- node: grille
|
||||||
|
entity: Grille
|
||||||
|
edges:
|
||||||
|
- to: start
|
||||||
|
completed:
|
||||||
|
- !type:SpawnPrototype
|
||||||
|
prototype: PartRodMetal1
|
||||||
|
amount: 2
|
||||||
|
- !type:DeleteEntity
|
||||||
|
steps:
|
||||||
|
- tool: Cutting
|
||||||
|
doAfter: 0.25
|
||||||
|
|
||||||
|
- node: grilleBroken
|
||||||
|
entity: GrilleBroken
|
||||||
|
edges:
|
||||||
|
- to: start
|
||||||
|
completed:
|
||||||
|
- !type:SpawnPrototype
|
||||||
|
prototype: PartRodMetal1
|
||||||
|
amount: 1
|
||||||
|
- !type:DeleteEntity
|
||||||
|
steps:
|
||||||
|
- tool: Cutting
|
||||||
|
- to: grille
|
||||||
|
steps:
|
||||||
|
- material: MetalRod
|
||||||
|
amount: 1
|
||||||
|
doAfter: 0.5
|
||||||
@@ -70,6 +70,23 @@
|
|||||||
placementMode: SnapgridCenter
|
placementMode: SnapgridCenter
|
||||||
canRotate: false
|
canRotate: false
|
||||||
|
|
||||||
|
- type: construction
|
||||||
|
name: grille
|
||||||
|
id: Grille
|
||||||
|
graph: grille
|
||||||
|
startNode: start
|
||||||
|
targetNode: grille
|
||||||
|
category: Structures
|
||||||
|
description: A flimsy framework of iron rods.
|
||||||
|
conditions:
|
||||||
|
- !type:TileNotBlocked
|
||||||
|
icon:
|
||||||
|
sprite: Structures/Walls/grille.rsi
|
||||||
|
state: grille
|
||||||
|
objectType: Structure
|
||||||
|
placementMode: SnapgridCenter
|
||||||
|
canRotate: false
|
||||||
|
|
||||||
- type: construction
|
- type: construction
|
||||||
name: window
|
name: window
|
||||||
id: Window
|
id: Window
|
||||||
|
|||||||
BIN
Resources/Textures/Structures/Walls/grille.rsi/grille.png
Normal file
BIN
Resources/Textures/Structures/Walls/grille.rsi/grille.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 216 B |
BIN
Resources/Textures/Structures/Walls/grille.rsi/grille_broken.png
Normal file
BIN
Resources/Textures/Structures/Walls/grille.rsi/grille_broken.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 285 B |
Binary file not shown.
|
After Width: | Height: | Size: 490 B |
Binary file not shown.
|
After Width: | Height: | Size: 483 B |
Binary file not shown.
|
After Width: | Height: | Size: 526 B |
Binary file not shown.
|
After Width: | Height: | Size: 510 B |
29
Resources/Textures/Structures/Walls/grille.rsi/meta.json
Normal file
29
Resources/Textures/Structures/Walls/grille.rsi/meta.json
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
{
|
||||||
|
"version": 1,
|
||||||
|
"license": "CC-BY-SA-3.0",
|
||||||
|
"copyright": "Taken from https://github.com/tgstation/tgstation at commit 17c603f1d037f22081d446b9a3f3ae8d41f52e86",
|
||||||
|
"size": {
|
||||||
|
"x": 32,
|
||||||
|
"y": 32
|
||||||
|
},
|
||||||
|
"states": [
|
||||||
|
{
|
||||||
|
"name": "grille"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "grille_broken"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "grille_damaged_0"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "grille_damaged_1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "grille_damaged_2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "grille_damaged_3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user