Fix spray nozzle not cleaning reagents properly (#35950)

* init, god help us all

* further refining

* final round of bugfixes

* whoopsies

* To file scoped namespace

* first review

* oopsie

* oopsie woopsie

* pie is on my face

* persistence

* datafieldn't

* make PreviousTileRef nullable

* change component to file scoped namespace

* Minor tweaks:

- We clamp the reaction amount to a minimum value because when working with percentages and dividing, we approach numbers like 0.01 and never actually properly delete the entity (because we check for zero). This allows us to react with a minimum amount and cleans things up nicely.
- Minor clarification to comments.
- Rebalancing of the spray nozzle projectile.

* the scug lies!!!!

* undo file scoped namespace in system

* kid named warning

---------

Co-authored-by: ScarKy0 <106310278+ScarKy0@users.noreply.github.com>
This commit is contained in:
ArtisticRoomba
2025-04-19 19:41:24 -07:00
committed by GitHub
parent a90c16b8d1
commit 44925b9be7
4 changed files with 94 additions and 47 deletions

View File

@@ -99,8 +99,8 @@
- type: Tag
tags:
- Spray
# Vapor
# Vapor
- type: entity
id: Vapor
name: "vapor"
@@ -111,6 +111,8 @@
vapor:
maxVol: 50
- type: Vapor
active: true
transferAmountPercentage: 0.5
- type: AnimationPlayer
- type: Sprite
sprite: Effects/chempuff.rsi

View File

@@ -936,6 +936,7 @@
- BulletImpassable
- type: Vapor
active: true
transferAmountPercentage: 1
- type: Appearance
- type: VaporVisuals