diff --git a/Resources/Locale/ru-RU/_white/structures/growingpot.ftl b/Resources/Locale/ru-RU/_white/structures/growingpot.ftl new file mode 100644 index 0000000000..fcea7f4a72 --- /dev/null +++ b/Resources/Locale/ru-RU/_white/structures/growingpot.ftl @@ -0,0 +1,2 @@ +ent-GrowingPot = самодельная грядка + .desc = Деревнянная грядка для выращивания. diff --git a/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml b/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml index 9dd4c37ca2..eb0d6fac72 100644 --- a/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml +++ b/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml @@ -186,6 +186,8 @@ prob: 0.10 - id: BarberScissors prob: 0.05 + - id: PackedSoil # WD + prob: 0.05 # Syndicate loot - id: null prob: 0.95 @@ -594,6 +596,8 @@ prob: 0.10 - id: BarberScissors prob: 0.05 + - id: PackedSoil # WD + prob: 0.05 # Syndicate loot - id: null prob: 0.95 diff --git a/Resources/Prototypes/Catalog/VendingMachines/Inventories/nutri.yml b/Resources/Prototypes/Catalog/VendingMachines/Inventories/nutri.yml index 1dd893507d..9d0d364bb5 100644 --- a/Resources/Prototypes/Catalog/VendingMachines/Inventories/nutri.yml +++ b/Resources/Prototypes/Catalog/VendingMachines/Inventories/nutri.yml @@ -18,6 +18,7 @@ HandheldSeedAnalyzer: 2 EZNutrientChemistryBottle: 3 Eftpos: 4 + PackedSoil: 5 #WD edit emaggedInventory: Left4ZedChemistryBottle: 1 diff --git a/Resources/Prototypes/_White/Catalog/Cargo/cargo.yml b/Resources/Prototypes/_White/Catalog/Cargo/cargo.yml index 8030597b8d..ccf029020a 100644 --- a/Resources/Prototypes/_White/Catalog/Cargo/cargo.yml +++ b/Resources/Prototypes/_White/Catalog/Cargo/cargo.yml @@ -296,3 +296,13 @@ cost: 2000 category: Security group: market + +- type: cargoProduct + id: cargoPackedSoil + icon: + sprite: White/Structures/growingpot.rsi + state: packed_soil + product: CratePackedSoil + cost: 500 + category: cargoproduct-category-name-hydroponics + group: market diff --git a/Resources/Prototypes/_White/Entities/Objects/CargoCrates/misc.yml b/Resources/Prototypes/_White/Entities/Objects/CargoCrates/misc.yml new file mode 100644 index 0000000000..986229067a --- /dev/null +++ b/Resources/Prototypes/_White/Entities/Objects/CargoCrates/misc.yml @@ -0,0 +1,10 @@ +- type: entity + parent: CrateHydroponics + id: CratePackedSoil + name: ящик с почвой + description: Ящик, содержащий пять упаковок с почвой. + components: + - type: StorageFill + contents: + - id: PackedSoil + amount: 5 diff --git a/Resources/Prototypes/_White/Entities/Objects/Misc/packed_soil.yml b/Resources/Prototypes/_White/Entities/Objects/Misc/packed_soil.yml new file mode 100644 index 0000000000..74b9712e62 --- /dev/null +++ b/Resources/Prototypes/_White/Entities/Objects/Misc/packed_soil.yml @@ -0,0 +1,16 @@ +- type: entity + name: упаковка почвы + description: Можно засыпать в каркас грядки. + id: PackedSoil + parent: BaseItem + components: + - type: Item + size: Normal + - type: Sprite + sprite: White/Structures/growingpot.rsi + state: packed_soil + - type: Tag + tags: + - PackedSoilTag + - type: StaticPrice + price: 10 diff --git a/Resources/Prototypes/_White/Entities/Structures/GrowingPot.yml b/Resources/Prototypes/_White/Entities/Structures/GrowingPot.yml new file mode 100644 index 0000000000..83ec7ba420 --- /dev/null +++ b/Resources/Prototypes/_White/Entities/Structures/GrowingPot.yml @@ -0,0 +1,88 @@ +- type: entity + name: самодельная грядка + parent: [GrowingPotNoSoil, hydroponicsSoil] + id: GrowingPot + description: Позволяет выращивать различные культуры. + components: + - type: Sprite + sprite: White/Structures/growingpot.rsi + state: pot_filled + - type: Transform + anchored: true + - type: Construction + graph: growingPot + node: growingPot + - type: Destructible + thresholds: + - trigger: + !type:DamageTrigger + damage: 50 + behaviors: + - !type:SpawnEntitiesBehavior + spawn: + MaterialWoodPlank1: + min: 5 + max: 10 + +- type: entity + id: GrowingPotEmpty + parent: GrowingPot + suffix: Empty + components: + - type: PlantHolder + waterLevel: 0 + nutritionLevel: 0 + +- type: entity + name: каркас самодельной грядки + id: GrowingPotNoSoil + parent: BaseStructure + placement: + mode: SnapgridCenter + description: Позволяет выращивать различные культуры, однако не хватает земли... + components: + - type: InteractionOutline + - type: Sprite + sprite: White/Structures/growingpot.rsi + state: pot_empty + noRot: true + - type: Tag + tags: + - Structure + - type: Fixtures + fixtures: + fix1: + shape: + !type:PhysShapeAabb + bounds: "-0.45,-0.45,0.45,0.1" + density: 60 + hard: true + mask: + - MachineMask + - type: Appearance + - type: Clickable + - type: Transform + noRot: true + - type: Construction + graph: growingPot + node: growingPotNoSoil + - type: Anchorable + - type: Damageable + DamageContainer: StructuralInorganic + DamageModifierSet: Wood + - type: Destructible + thresholds: + - trigger: + !type:DamageTrigger + damage: 20 + behaviors: + - !type:PlaySoundBehavior + sound: + collection: WoodDestroy + - !type:SpawnEntitiesBehavior + spawn: + MaterialWoodPlank1: + min: 5 + max: 10 + - !type:DoActsBehavior + acts: [ "Destruction" ] diff --git a/Resources/Prototypes/_White/Recipes/Construction/Graphs/growingPot.yml b/Resources/Prototypes/_White/Recipes/Construction/Graphs/growingPot.yml new file mode 100644 index 0000000000..1b3f921780 --- /dev/null +++ b/Resources/Prototypes/_White/Recipes/Construction/Graphs/growingPot.yml @@ -0,0 +1,61 @@ +- type: constructionGraph + id: growingPot + start: start + graph: + - node: start + actions: + - !type:DestroyEntity {} + edges: + - to: growingPotNoSoil + completed: + - !type:SnapToGrid + southRotation: true + steps: + - material: WoodPlank + amount: 15 + doAfter: 4 + - material: MetalRod + amount: 4 + doAfter: 1 + + - node: growingPotNoSoil + entity: GrowingPotNoSoil + edges: + - to: growingPot + conditions: + - !type:EntityAnchored + completed: + - !type:SnapToGrid + southRotation: true + steps: + - tag: PackedSoilTag + name: упаковка почвы + icon: + sprite: White/Structures/growingpot.rsi + state: packed_soil + - to: start + completed: + - !type:SpawnPrototype + prototype: MaterialWoodPlank1 + amount: 15 + - !type:SpawnPrototype + prototype: PartRodMetal1 + amount: 4 + steps: + - tool: Screwing + doAfter: 1 + + - node: growingPot + entity: GrowingPotEmpty + edges: + - to: growingPotNoSoil + conditions: + - !type:EntityAnchored + completed: + - !type:SpawnPrototype + prototype: PackedSoil + amount: 1 + - !type:EmptyAllContainers + steps: + - tool: Prying + doAfter: 5 diff --git a/Resources/Prototypes/_White/Recipes/Construction/GrowingPot.yml b/Resources/Prototypes/_White/Recipes/Construction/GrowingPot.yml new file mode 100644 index 0000000000..3b76e3e1e0 --- /dev/null +++ b/Resources/Prototypes/_White/Recipes/Construction/GrowingPot.yml @@ -0,0 +1,16 @@ +- type: construction + id: GrowingPot + name: самодельная грядка + description: Деревнянная грядка для выращивания. + graph: growingPot + startNode: start + targetNode: growingPot + category: construction-category-furniture + icon: + sprite: White/Structures/growingpot.rsi + state: pot_filled + objectType: Structure + placementMode: SnapgridCenter + canBuildInImpassable: false + conditions: + - !type:TileNotBlocked diff --git a/Resources/Prototypes/_White/tags.yml b/Resources/Prototypes/_White/tags.yml index de4f84d435..7fd259942a 100644 --- a/Resources/Prototypes/_White/tags.yml +++ b/Resources/Prototypes/_White/tags.yml @@ -150,3 +150,6 @@ - type: Tag id: MagazineKalashLightRifleBox + +- type: Tag + id: PackedSoilTag diff --git a/Resources/Textures/White/Structures/growingpot.rsi/meta.json b/Resources/Textures/White/Structures/growingpot.rsi/meta.json new file mode 100644 index 0000000000..cc817e7473 --- /dev/null +++ b/Resources/Textures/White/Structures/growingpot.rsi/meta.json @@ -0,0 +1,20 @@ +{ + "version": 1, + "license": "CC-BY-SA-3.0", + "copyright": "dosharus", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "pot_filled" + }, + { + "name": "pot_empty" + }, + { + "name": "packed_soil" + } + ] +} \ No newline at end of file diff --git a/Resources/Textures/White/Structures/growingpot.rsi/packed_soil.png b/Resources/Textures/White/Structures/growingpot.rsi/packed_soil.png new file mode 100644 index 0000000000..9368408eeb Binary files /dev/null and b/Resources/Textures/White/Structures/growingpot.rsi/packed_soil.png differ diff --git a/Resources/Textures/White/Structures/growingpot.rsi/pot_empty.png b/Resources/Textures/White/Structures/growingpot.rsi/pot_empty.png new file mode 100644 index 0000000000..b06810c9a4 Binary files /dev/null and b/Resources/Textures/White/Structures/growingpot.rsi/pot_empty.png differ diff --git a/Resources/Textures/White/Structures/growingpot.rsi/pot_filled.png b/Resources/Textures/White/Structures/growingpot.rsi/pot_filled.png new file mode 100644 index 0000000000..1d51f2df2c Binary files /dev/null and b/Resources/Textures/White/Structures/growingpot.rsi/pot_filled.png differ