Property Cleanliness
Homes in Kartik Properties get visibly dirty over time and can be cleaned again by hand with a broom or automatically with a placed robot vacuum. Cleanliness is a living, per-property stat separate from a property's condition/maintenance, a well-maintained home can still be filthy, and a run-down home isn't automatically dirty.
How it works
- Dirt builds up over real time. A clean, empty home slowly grimes up over
DaysToFilthyreal days. - Activity accelerates it. Every appliance use, cook, shower, or bath ages the property's cleanliness clock, so a busy household gets dirty in a day or two while an empty one drifts slowly.
- You clean it back to spotless. Sweep with a broom or run a robot vacuum to reset the property to fully clean.
Visual grime (four stacked layers)
As a property gets dirtier, the interior progressively shows more grime. Each tier layers on top of the last:
- Hazy air: a grimy tint overlays the room as filth rises.
- Clutter: trash and bottles appear scattered on furniture and across the floor.
- Dust: dust particle effects drift around the room.
- Cobwebs: the heaviest tier for a long-neglected home.
The dirt layout is deterministic and synced, so every occupant sees exactly the same mess in the same spots.
Cleaning by hand (broom sweep)
- Interact with the Sweep up option inside the property (requires a
broomitem by default). - Your character carries the broom and plays a sweeping animation while you walk over the mess, clutter is cleared as you pass within reach.
- Cleaning is collaborative. Any occupant can join in; each piece of clutter picked up is removed for everyone in real time.
- Press [X] to finish and save the clean; walking out the door cancels without saving.
Robot vacuum
Place a robot vacuum (a furniture item tagged as the vacuum feature) inside a property to automate cleaning:
- Slows decay: a property with a vacuum grimes up far more slowly (
VacuumDaysToFilthy). - Passive deep-clean: the vacuum deep-cleans the home automatically each billing cycle and draws a small amount of metered power for doing so.
- Manual run: use the Run Robot Vacuum interaction to send it around the room on demand; it wheels along the floor and snaps back to its spot when finished.
Configuration
Cleanliness is configured in shared/economy.lua under Config.Cleanliness:
Config.Cleanliness = {
Enabled = true,
DaysToFilthy = 4, -- real days a clean, IDLE home takes to reach MinCleanliness
MinCleanliness = 0.0, -- floor once fully filthy (0..1)
VacuumDaysToFilthy = 24, -- with a robot vacuum installed, decay is ~6x slower
CleanItem = 'broom', -- item required for a manual sweep (set false to require none)
VacuumFeature = 'vacuum', -- furniture `feature` tag that marks the robot vacuum
VacuumPowerDraw = 4, -- metered power units the robot draws per billing cycle (passive)
CleanReach = 1.6, -- how close (m) the player must get to a mess to clear it
-- Activity aging: each completed metered use subtracts this many SECONDS from
-- the cleanliness clock, so busy homes grime up faster. Keyed by the same `kind`
-- string the appliance / bathing handlers pass; anything unlisted uses `default`.
ActivityAging = {
default = 3 * 3600,
bbq = 6 * 3600, -- cooking is the messiest
shower = 2 * 3600,
bath = 3 * 3600,
washer = 1 * 3600,
dryer = 1 * 3600,
coffee = 1 * 3600,
sink = 30 * 60,
},
}The visual tiers (haze tint, clutter/scatter counts, dust and cobweb thresholds, and the carried-tool animations) are all tunable in the same Config.Cleanliness block.
Notes
- The
broomitem must exist in your inventory (or setCleanItem = falseto require no item). The same broom is used to clean solar panels. - Cleanliness is not the same as a property's condition/maintenance stat, see Utilities & Billing.
- Existing properties are backfilled to fully clean when the system is first added, so nothing looks dirty until it ages.
Testing
Admins can force a cleanliness level to preview the visuals immediately:
/kp_setdirty [level 0..1] [propertyId]This back-dates the property's cleanliness clock so the target level shows on entry (a raw SQL update will not work, as the value is read from the property cache).