added consumption timeout for beverages and snacks (#5013)

Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
bloodrizer
2022-01-30 05:27:51 -08:00
committed by GitHub
parent cfd2e28eae
commit b0f1f4ae89
7 changed files with 26 additions and 14 deletions

View File

@@ -1,13 +1,24 @@
#
# Base component for consumable food
#
- type: entity
parent: BaseItem
id: FoodBase
abstract: true
components:
- type: Food
- type: ItemCooldown
- type: UseDelay
delay: 1.5
# This base type is used to cover all of the "obvious" things that should be doable to open-package food.
# Practically this means injection.
# But it might in future also mean drawing with a syringe, so this is a base prototype just in case.
- type: entity
parent: BaseItem
parent: FoodBase
id: FoodInjectableBase
abstract: true
components:
- type: Food
- type: InjectableSolution
solution: food

View File

@@ -1,7 +1,7 @@
# Base
- type: entity
parent: BaseItem
parent: FoodBase
id: FoodSnackBase
abstract: true
components:

View File

@@ -1,5 +1,5 @@
- type: entity
parent: BaseItem
parent: FoodBase
id: FoodBowlBase
abstract: true
components:

View File

@@ -20,6 +20,9 @@
interfaces:
- key: enum.TransferAmountUiKey.Key
type: TransferAmountBoundUserInterface
- type: ItemCooldown
- type: UseDelay
delay: 1.0
- type: entity
parent: DrinkBase

View File

@@ -1,5 +1,5 @@
- type: entity
parent: BaseItem
parent: DrinkBase
id: DrinkBottleBaseFull
abstract: true
components:
@@ -10,12 +10,6 @@
solutions:
drink:
maxVol: 100
- type: SolutionTransfer
canChangeTransferAmount: true
- type: UserInterface
interfaces:
- key: enum.TransferAmountUiKey.Key
type: TransferAmountBoundUserInterface
- type: Sprite
state: icon
- type: DamageOnLand
@@ -26,8 +20,6 @@
damage:
types:
Blunt: 4
- type: Spillable
solution: drink
- type: Damageable
damageContainer: Inorganic
- type: Destructible

View File

@@ -37,6 +37,9 @@
- type: Tag
tags:
- Trash
- type: ItemCooldown
- type: UseDelay
delay: 1.0
- type: entity
parent: DrinkCanBaseFull

View File

@@ -28,6 +28,9 @@
state: icon
- type: Spillable
solution: drink
- type: ItemCooldown
- type: UseDelay
delay: 1.0
- type: entity
parent: DrinkBaseCup