Skip to content

an open-source alternative to the dots, bots and muses of the world, run an office of claude code/codex like agents on your laptop, sandboxes or anywhere, uses your existing subscriptions

feat: office life - cheers, lit desk screens, a real coffee cycle, plant watering

Gulum969ef133322d
diff --git a/src/renderer/src/assets/maps/office.tmj b/src/renderer/src/assets/maps/office.tmj
index 3a3a71b4..ab3f9fcd 100644
--- a/src/renderer/src/assets/maps/office.tmj
+++ b/src/renderer/src/assets/maps/office.tmj
@@ -1 +1 @@
-{"compressionlevel":-1,"height":22,"infinite":false,"layers":[{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,1698,1699,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,1714,1715,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":1,"name":"floor","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[514,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,517,530,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,533,530,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,533,530,0,0,0,0,0,0,611,611,0,0,0,0,0,0,0,0,0,611,0,0,0,0,0,0,611,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,522,522,522,522,0,522,522,522,522,522,522,522,0,522,522,522,522,522,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,554,554,554,554,0,554,554,554,554,554,554,554,0,554,554,554,554,554,0,0,0,0,0,0,522,0,522,522,522,522,522,522,533,530,570,570,570,570,0,570,570,570,570,570,570,570,0,570,570,570,570,570,0,0,0,0,0,0,554,0,554,554,554,554,554,554,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,570,570,0,570,570,570,570,570,570,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,611,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,578,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,0,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,581],"height":22,"id":2,"name":"walls","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,266,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,281,282,0,0,0,0,0,0,0,0,0,0,0,0,257,257,257,257,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,297,298,0,0,0,0,289,0,0,0,0,0,0,1610612898,1610612914,2684354789,2684354789,1610612914,1610612930,260,0,0,0,0,0,0,0,0,0,2,3,4,2,3,4,0,0,0,0,2,3,4,0,0,0,0,0,1610612897,1610612913,1610612965,1610612965,1610612913,1610612929,276,0,0,0,0,0,0,0,0,0,0,289,0,0,289,0,0,0,0,0,18,289,20,0,0,0,0,0,0,274,274,274,274,0,0,0,0,2,3,4,2,3,4,0,0,305,0,0,305,0,0,0,0,0,0,305,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,289,0,0,289,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,305,0,0,305,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1029,1026,1027,0,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,0,0,0,0,0,1041,1042,1043,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,0,0,0,0,1044,0,1061,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,0,305,305,0,1073,1074,1075,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,305,305,0,0,0,0,0,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,0,0,0,0,269,191,192,0,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,38,40,39,285,207,208,2248,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,54,56,55,301,223,224,2264,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2280,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":3,"name":"furniture-below","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,327,328,0,0,0,0,0,0,327,328,0,0,327,328,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,343,344,0,0,0,0,0,0,343,344,0,0,343,344,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,354,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,365,366,0,365,366,0,0,0,370,0,0,0,0,0,0,0,0,451,0,0,0,0,395,0,0,0,0,0,0,0,0,0,0,0,381,382,0,381,382,0,0,0,0,431,432,349,0,0,0,0,0,467,258,258,258,258,411,0,0,0,0,365,366,0,365,366,0,18,19,20,18,19,20,0,0,0,0,0,19,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,381,382,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,18,19,20,18,19,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,0,0,0,0,0,0,0,0,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,313,0,0,0,0,0,1610613812,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,329,330,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1650,1650,0,0,0,0,0,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,313,0,0,0,0,0,0,0,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,0,329,330,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":4,"name":"furniture-above","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,1,1,0,0,1,1,1,1,0,0,0,1,0,0,0,0,0,0,1,0,1,1,0,1,1,1,1,1,1,0,0,0,0,0,1,1,0,1,1,1,1,1,1,1,0,1,0,0,0,0,0,0,1,1,1,1,1,1,1,0,1,1,0,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,0,1,0,1,1,0,1,1,1,1,0,1,1,0,1,0,1,1,0,1,1,1,0,0,1,1,0,0,1,1,1,1,0,0,0,0,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,1,0,1,1,0,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,1,0,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,1,1,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,1,0,0,0,0,0,0,0,0,1,1,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,1,0,1,0,0,1,1,1,0,1,1,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,0,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1],"height":22,"id":5,"name":"collision","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"draworder":"topdown","id":6,"name":"spawn-points","objects":[{"id":0,"name":"desk-ceo","type":"","x":48,"y":64,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-1","type":"","x":32,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-2","type":"","x":96,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-3","type":"","x":160,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-4","type":"","x":224,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-5","type":"","x":288,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-6","type":"","x":352,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-team-lead","type":"","x":32,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-backend-engineer","type":"","x":96,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-product-manager","type":"","x":160,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-data-engineer","type":"","x":224,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-project-manager","type":"","x":288,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-market-researcher","type":"","x":352,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-agent-organizer","type":"","x":320,"y":112,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"warroom-seat","type":"","x":368,"y":112,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-chief-architect","type":"","x":432,"y":80,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-ui-ux-expert","type":"","x":480,"y":80,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"entrance","type":"","x":256,"y":320,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-1","type":"","x":432,"y":224,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-2","type":"","x":432,"y":256,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-3","type":"","x":448,"y":224,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-4","type":"","x":448,"y":256,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-stand-coffee","type":"","x":400,"y":240,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-stand-vending","type":"","x":464,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true}],"opacity":1,"type":"objectgroup","visible":true,"x":0,"y":0},{"draworder":"topdown","id":7,"name":"zones","objects":[{"id":0,"name":"boardroom","type":"","x":144,"y":48,"width":144,"height":80,"rotation":0,"visible":true},{"id":0,"name":"cafeteria","type":"","x":384,"y":192,"width":128,"height":128,"rotation":0,"visible":true}],"opacity":1,"type":"objectgroup","visible":true,"x":0,"y":0}],"nextlayerid":8,"nextobjectid":1,"orientation":"orthogonal","renderorder":"right-down","tiledversion":"1.12.0","tileheight":16,"tilesets":[{"columns":16,"firstgid":1,"image":"../tilesets/office-tileset.png","imageheight":512,"imagewidth":256,"margin":0,"name":"office-tileset","spacing":0,"tilecount":512,"tileheight":16,"tilewidth":16},{"firstgid":513,"source":"A5 Office Floors & Walls.tsx"},{"firstgid":1025,"source":"interiors.tsx"}],"tilewidth":16,"type":"map","version":"1.10","width":34}
\ No newline at end of file
+{"compressionlevel":-1,"height":22,"infinite":false,"layers":[{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,1698,1699,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,1714,1715,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,783,784,0,0,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,799,800,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":1,"name":"floor","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[514,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,517,530,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,554,533,530,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,533,530,0,0,0,0,0,0,611,611,0,0,0,0,0,0,0,0,0,611,0,0,0,0,0,0,611,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,643,643,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,522,522,522,522,0,522,522,522,522,522,522,522,0,522,522,522,522,522,0,0,0,0,0,0,643,0,0,0,0,0,0,0,533,530,554,554,554,554,0,554,554,554,554,554,554,554,0,554,554,554,554,554,0,0,0,0,0,0,522,0,522,522,522,522,522,522,533,530,570,570,570,570,0,570,570,570,570,570,570,570,0,570,570,570,570,570,0,0,0,0,0,0,554,0,554,554,554,554,554,554,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,570,570,0,570,570,570,570,570,570,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,611,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,530,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,643,0,0,0,0,0,0,0,0,533,578,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,0,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,579,581],"height":22,"id":2,"name":"walls","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,266,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,281,282,0,0,0,0,0,0,0,452,0,0,0,0,257,257,257,257,0,0,453,0,0,0,0,0,0,0,0,0,0,0,0,0,297,298,0,0,0,0,289,0,0,0,0,0,0,1610612898,1610612914,2684354789,2684354789,1610612914,1610612930,260,0,0,0,0,0,0,0,0,0,2,3,4,2,3,4,0,0,0,0,2,3,4,0,0,0,0,0,1610612897,1610612913,1610612965,1610612965,1610612913,1610612929,276,0,0,0,0,0,0,0,0,0,0,289,0,0,289,0,0,0,0,0,18,289,20,0,0,0,0,0,0,274,274,274,274,0,0,0,0,2,3,4,2,3,4,0,0,305,0,0,305,0,0,0,0,0,0,305,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,289,0,0,289,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,305,0,0,305,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1029,1026,1027,0,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,0,0,0,0,0,1041,1042,1043,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,0,0,0,0,1044,0,1061,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,0,305,305,0,1073,1074,1075,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,305,305,0,0,0,0,0,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,2,3,4,0,0,0,0,0,269,191,192,0,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,289,0,0,0,38,40,39,285,207,208,2248,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,305,0,0,0,54,56,55,301,223,224,2264,0,0,470,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,471,0,0,0,0,0,0,0,472,2280,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":3,"name":"furniture-below","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,327,328,0,0,0,0,0,0,327,328,0,0,327,328,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,343,344,0,0,0,0,0,0,343,344,0,0,343,344,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,354,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,365,366,0,365,366,0,0,0,370,0,0,0,0,0,0,0,0,451,0,0,0,0,395,0,0,0,0,0,0,0,0,0,0,0,381,382,0,381,382,0,0,0,0,431,432,349,0,0,0,0,0,467,258,258,258,258,411,0,0,0,0,365,366,0,365,366,0,18,19,20,18,19,20,0,0,0,0,0,19,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,381,382,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,18,19,20,18,19,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,0,0,0,0,0,0,0,0,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,313,0,0,0,0,0,1610613812,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,329,330,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1650,1650,0,0,0,0,0,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,365,366,0,0,0,0,0,0,0,0,0,0,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,381,382,0,0,313,0,0,0,0,0,0,0,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,18,19,20,0,0,329,330,0,0,0,0,0,0,0,454,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,455,0,0,0,0,0,0,0,456,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"height":22,"id":4,"name":"furniture-above","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"data":[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,1,1,1,0,0,1,1,1,1,0,0,1,1,0,0,0,0,0,0,1,0,1,1,0,1,1,1,1,1,1,0,0,0,0,0,1,1,0,1,1,1,1,1,1,1,0,1,0,0,0,0,0,0,1,1,1,1,1,1,1,0,1,1,0,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,0,1,0,1,1,0,1,1,1,1,0,1,1,0,1,0,1,1,0,1,1,1,0,0,1,1,0,0,1,1,1,1,0,0,0,0,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,1,0,1,1,0,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,0,1,1,1,1,1,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,1,0,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,1,1,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,0,0,1,1,1,0,0,0,0,0,0,0,0,1,1,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,1,0,1,0,0,1,1,1,0,1,1,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,1,0,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1],"height":22,"id":5,"name":"collision","opacity":1,"type":"tilelayer","visible":true,"width":34,"x":0,"y":0},{"draworder":"topdown","id":6,"name":"spawn-points","objects":[{"id":0,"name":"desk-ceo","type":"","x":48,"y":64,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-1","type":"","x":32,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-2","type":"","x":96,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-3","type":"","x":160,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-4","type":"","x":224,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-5","type":"","x":288,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"pc-6","type":"","x":352,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-team-lead","type":"","x":32,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-backend-engineer","type":"","x":96,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-product-manager","type":"","x":160,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-data-engineer","type":"","x":224,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-project-manager","type":"","x":288,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-market-researcher","type":"","x":352,"y":288,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-agent-organizer","type":"","x":320,"y":112,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"warroom-seat","type":"","x":368,"y":112,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-chief-architect","type":"","x":432,"y":80,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"desk-ui-ux-expert","type":"","x":480,"y":80,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"entrance","type":"","x":256,"y":320,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-1","type":"","x":432,"y":224,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-2","type":"","x":432,"y":256,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-3","type":"","x":448,"y":224,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-seat-4","type":"","x":448,"y":256,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-stand-coffee","type":"","x":400,"y":240,"width":0,"height":0,"rotation":0,"visible":true,"point":true},{"id":0,"name":"cafe-stand-vending","type":"","x":464,"y":208,"width":0,"height":0,"rotation":0,"visible":true,"point":true}],"opacity":1,"type":"objectgroup","visible":true,"x":0,"y":0},{"draworder":"topdown","id":7,"name":"zones","objects":[{"id":0,"name":"boardroom","type":"","x":144,"y":48,"width":144,"height":80,"rotation":0,"visible":true},{"id":0,"name":"cafeteria","type":"","x":384,"y":192,"width":128,"height":128,"rotation":0,"visible":true}],"opacity":1,"type":"objectgroup","visible":true,"x":0,"y":0}],"nextlayerid":8,"nextobjectid":1,"orientation":"orthogonal","renderorder":"right-down","tiledversion":"1.12.0","tileheight":16,"tilesets":[{"columns":16,"firstgid":1,"image":"../tilesets/office-tileset.png","imageheight":512,"imagewidth":256,"margin":0,"name":"office-tileset","spacing":0,"tilecount":512,"tileheight":16,"tilewidth":16},{"firstgid":513,"source":"A5 Office Floors & Walls.tsx"},{"firstgid":1025,"source":"interiors.tsx"}],"tilewidth":16,"type":"map","version":"1.10","width":34}
\ No newline at end of file
diff --git a/src/renderer/src/assets/tilesets/office-tileset.png b/src/renderer/src/assets/tilesets/office-tileset.png
index be5e1747..9a7cffbc 100644
Binary files a/src/renderer/src/assets/tilesets/office-tileset.png and b/src/renderer/src/assets/tilesets/office-tileset.png differ
diff --git a/src/renderer/src/scene/office/Character.ts b/src/renderer/src/scene/office/Character.ts
index c4827a6f..816797d2 100644
--- a/src/renderer/src/scene/office/Character.ts
+++ b/src/renderer/src/scene/office/Character.ts
@@ -97,6 +97,22 @@ export class Character {
private glyphElapsed = 0;
private onClick?: (agentId: string) => void;
+ // ── Office-life effects (cheer / coffee / watering) ────────────────────────
+ /** Effect layer riding on the sprite: confetti, the carried cup, droplets. */
+ private fx: Graphics;
+ private fxDirty = false; // fx drew last frame → needs a clear when idle
+ private cheerT = -1; // -1 = not cheering
+ private confetti: Array<{ x: number; y: number; vx: number; vy: number; c: number }> = [];
+ private carryingCup = false;
+ /** The cup parked on this agent's desk (world-positioned, lives in the char
+ * layer so it survives the agent walking away). */
+ private deskCup: Graphics;
+ private deskCupOn = false;
+ private cupSpot: { x: number; y: number } | null = null;
+ private waterT = -1; // -1 = not watering
+ private waterDur = 0;
+ private onWaterDone: (() => void) | null = null;
+
constructor(options: CharacterOptions) {
this.agentId = options.agentId;
this.mapRenderer = options.mapRenderer;
@@ -122,6 +138,13 @@ export class Character {
this.overlay = new Graphics();
this.overlay.eventMode = 'none';
+
+ this.fx = new Graphics();
+ this.fx.eventMode = 'none';
+
+ this.deskCup = new Graphics();
+ this.deskCup.eventMode = 'none';
+ this.deskCup.visible = false;
}
getAnimation(): CharacterAnimation { return this.state; }
@@ -332,6 +355,92 @@ export class Character {
if (glyph === 'none') this.overlay.clear();
}
+ // ── Cheer ──────────────────────────────────────────────────────────────────
+
+ /** Celebrate finished work: a couple of happy hops under a confetti burst.
+ * Movement (wander / idle loop) is held for the duration so the jump reads
+ * on the spot; whatever the avatar was told to do resumes right after. */
+ cheer(): void {
+ if (this.sitting) return; // seated cheer would fight the sit offset/crop
+ // Stop in place so the hops read on the spot; roaming resumes right after.
+ this.path = [];
+ if (this.state === 'walk') {
+ this.state = 'idle';
+ this.sprite.setAnimation('idle', this.direction);
+ }
+ this.cheerT = 0;
+ this.confetti = [];
+ const colors = [0xffd93d, 0xff6b6b, 0x6bcb77, 0x4d96ff, 0xf6a6ff];
+ for (let i = 0; i < 14; i++) {
+ this.confetti.push({
+ x: (Math.random() - 0.5) * 8,
+ y: -22 - Math.random() * 6,
+ vx: (Math.random() - 0.5) * 46,
+ vy: -30 - Math.random() * 40,
+ c: colors[i % colors.length]
+ });
+ }
+ }
+
+ /** True while the cheer animation holds the avatar in place. */
+ isCheering(): boolean {
+ return this.cheerT >= 0;
+ }
+
+ // ── Coffee cup ─────────────────────────────────────────────────────────────
+
+ /** Where this agent's cup rests when parked on its desk (world pixels).
+ * Typically beside the monitor — where the old baked-in tileset mug sat. */
+ setCupSpot(spot: { x: number; y: number } | null): void {
+ this.cupSpot = spot;
+ if (spot) {
+ this.deskCup.position.set(spot.x, spot.y);
+ this.deskCup.zIndex = spot.y;
+ }
+ }
+
+ /** Show/hide the cup in the avatar's hand (walking it to/from the café). */
+ setCarryingCup(carrying: boolean): void {
+ this.carryingCup = carrying;
+ }
+
+ /** Park the carried cup on the desk / pick it back up. No-op without a spot. */
+ setCupOnDesk(on: boolean): void {
+ if (!this.cupSpot) return;
+ this.deskCupOn = on;
+ this.deskCup.visible = on;
+ if (on) this.drawCup(this.deskCup, 0, 0);
+ else this.deskCup.clear();
+ }
+
+ hasCupOnDesk(): boolean {
+ return this.deskCupOn;
+ }
+
+ isCarryingCup(): boolean {
+ return this.carryingCup;
+ }
+
+ // ── Watering ───────────────────────────────────────────────────────────────
+
+ /** Water the plant the avatar is facing: a held watering can + a steady arc
+ * of droplets for `seconds`, then `onDone` (resume wandering etc.). */
+ startWatering(seconds: number, onDone?: () => void): void {
+ this.waterT = 0;
+ this.waterDur = seconds;
+ this.onWaterDone = onDone ?? null;
+ }
+
+ isWatering(): boolean {
+ return this.waterT >= 0;
+ }
+
+ /** Abort a watering in progress (real work arrived). The callback is dropped. */
+ stopWatering(): void {
+ this.waterT = -1;
+ this.onWaterDone = null;
+ }
+
setBaseAlpha(alpha: number): void {
this.targetAlpha = alpha;
}
@@ -353,6 +462,8 @@ export class Character {
parent.addChild(this.workGlow);
parent.addChild(this.sprite.container);
this.sprite.container.addChild(this.overlay);
+ this.sprite.container.addChild(this.fx);
+ parent.addChild(this.deskCup);
parent.addChild(this.thoughtBubble.container);
this.enableClick();
this.fadeDirection = 'in';
@@ -387,6 +498,7 @@ export class Character {
this.thoughtBubble.hide();
this.thoughtBubble.container.parent?.removeChild(this.thoughtBubble.container);
this.workGlow.parent?.removeChild(this.workGlow);
+ this.deskCup.parent?.removeChild(this.deskCup);
}
}
} else if (this.isVisible) {
@@ -401,9 +513,11 @@ export class Character {
if (!this.isVisible) return;
// Working agents stay seated; between tasks they wander the office.
+ // A cheer or a watering holds roaming so the effect plays out in place.
+ const heldByFx = this.cheerT >= 0 || this.waterT >= 0;
if (this.state === 'walk') this.updateWalk(dt);
- else if (this.wandering) this.updateWander(dt);
- if (this.idleLoop) this.updateIdleLoop(dt);
+ else if (this.wandering && !heldByFx) this.updateWander(dt);
+ if (this.idleLoop && !heldByFx) this.updateIdleLoop(dt);
this.sprite.container.zIndex = this.py;
this.thoughtBubble.setPosition(this.px, this.py);
@@ -424,6 +538,132 @@ export class Character {
}
this.updateStatusGlyph(dt);
+ this.updateFx(dt);
+ }
+
+ /** True while parked in the seated pose at the HOME desk (not a café seat). */
+ isSittingAtDesk(): boolean {
+ if (!this.sitting) return false;
+ const t = this.getTilePosition();
+ return t.x === this.deskTile.x && t.y === this.deskTile.y;
+ }
+
+ // ── Effect rendering (cheer confetti, carried cup, watering, cup steam) ────
+
+ /** Carried-cup offset from the feet anchor, per facing direction. */
+ private carryOffset(): { x: number; y: number } {
+ switch (this.direction) {
+ case 'left': return { x: -7, y: -9 };
+ case 'right': return { x: 7, y: -9 };
+ case 'up': return { x: -5, y: -10 };
+ default: return { x: 5, y: -9 };
+ }
+ }
+
+ /** Hand position while watering, per facing direction. */
+ private handOffset(): { x: number; y: number } {
+ switch (this.direction) {
+ case 'left': return { x: -6, y: -9 };
+ case 'right': return { x: 6, y: -9 };
+ case 'up': return { x: 0, y: -13 };
+ default: return { x: 0, y: -6 };
+ }
+ }
+
+ /** A tiny coffee mug (white body, yellow stripe, handle) at (x, y) = its
+ * bottom-left. Same silhouette as the mug the tileset used to bake onto
+ * every desk — now it only exists where an agent actually put one down. */
+ private drawCup(g: Graphics, x: number, y: number): void {
+ g.rect(x, y - 4, 5, 4).fill(0xf2ede2);
+ g.rect(x, y - 2, 5, 1).fill(0xe8c14d);
+ g.rect(x + 5, y - 3, 1, 2).fill(0xd9d2c4);
+ g.rect(x, y - 4, 5, 1).fill(0xffffff);
+ }
+
+ private steamT = 0;
+
+ private updateFx(dt: number): void {
+ this.steamT += dt;
+
+ // ── Desk cup (world-anchored, persists while the agent roams) ───────────
+ if (this.deskCupOn && this.cupSpot) {
+ this.deskCup.clear();
+ this.drawCup(this.deskCup, 0, 0);
+ // two staggered steam pixels drifting up and fading
+ for (let i = 0; i < 2; i++) {
+ const ph = (this.steamT * 0.7 + i * 0.5) % 1;
+ this.deskCup.rect(1 + i * 2, -5 - Math.round(ph * 5), 1, 1)
+ .fill({ color: 0xffffff, alpha: 0.5 * (1 - ph) });
+ }
+ }
+
+ // ── Sprite-riding effects ────────────────────────────────────────────────
+ const active = this.cheerT >= 0 || this.waterT >= 0 || this.carryingCup;
+ if (!active) {
+ if (this.fxDirty) { this.fx.clear(); this.fxDirty = false; }
+ return;
+ }
+ this.fx.clear();
+ this.fxDirty = true;
+
+ // Cheer: happy hops + a confetti burst, ~1.6s, then back to whatever the
+ // avatar was doing (movement is held meanwhile — see update()).
+ if (this.cheerT >= 0) {
+ this.cheerT += dt;
+ const t = this.cheerT;
+ if (t >= 1.6) {
+ this.cheerT = -1;
+ this.sprite.setPosition(this.px, this.py); // land the final hop
+ } else {
+ const decay = 1 - t / 1.6;
+ const hop = Math.abs(Math.sin(t * Math.PI * 2.2)) * 5 * decay;
+ this.sprite.setPosition(this.px, this.py - hop);
+ for (const p of this.confetti) {
+ p.x += p.vx * dt;
+ p.y += p.vy * dt;
+ p.vy += 110 * dt;
+ const alpha = Math.max(0, Math.min(1, (1.45 - t) / 0.5));
+ this.fx.rect(Math.round(p.x), Math.round(p.y), 2, 2).fill({ color: p.c, alpha });
+ }
+ }
+ }
+
+ // Carried cup, riding in the hand on the facing side (+ steam).
+ if (this.carryingCup) {
+ const o = this.carryOffset();
+ this.drawCup(this.fx, o.x, o.y);
+ const ph = (this.steamT * 0.9) % 1;
+ this.fx.rect(o.x + 2, o.y - 5 - Math.round(ph * 4), 1, 1)
+ .fill({ color: 0xffffff, alpha: 0.5 * (1 - ph) });
+ }
+
+ // Watering: a little can in the hand and an arc of droplets falling onto
+ // the plant in front, until the duration elapses → onDone (resume idling).
+ if (this.waterT >= 0) {
+ this.waterT += dt;
+ if (this.waterT >= this.waterDur) {
+ this.waterT = -1;
+ const cb = this.onWaterDone;
+ this.onWaterDone = null;
+ cb?.();
+ } else {
+ const h = this.handOffset();
+ const dirX = this.direction === 'left' ? -1 : this.direction === 'right' ? 1 : 0;
+ const dirY = this.direction === 'up' ? -1 : this.direction === 'down' ? 1 : 0;
+ // can body + spout toward the plant
+ this.fx.rect(h.x - 2, h.y - 2, 5, 3).fill(0x9aa7b0);
+ this.fx.rect(h.x + (dirX >= 0 ? 3 : -4), h.y - 2, 2, 1).fill(0x9aa7b0);
+ for (let i = 0; i < 4; i++) {
+ const ph = (this.waterT * 1.3 + i / 4) % 1;
+ const reach = 4 + ph * 7;
+ const dx = dirX !== 0 ? reach * dirX : (i - 1.5) * 1.5;
+ const dy = dirY !== 0 ? reach * dirY : 0;
+ const fall = ph * ph * 9;
+ this.fx.rect(Math.round(h.x + dx), Math.round(h.y + dy + fall - 2), 1, 2)
+ .fill({ color: 0x5bb7e8, alpha: 1 - ph * 0.45 });
+ }
+ }
+ }
}
private updateStatusGlyph(dt: number): void {
@@ -572,5 +812,8 @@ export class Character {
this.sprite.destroy();
this.workGlow.destroy();
this.overlay.destroy();
+ this.fx.destroy();
+ this.deskCup.parent?.removeChild(this.deskCup);
+ this.deskCup.destroy();
}
}
diff --git a/src/renderer/src/scene/office/DeskScreen.ts b/src/renderer/src/scene/office/DeskScreen.ts
new file mode 100644
index 00000000..d6b4b150
--- /dev/null
+++ b/src/renderer/src/scene/office/DeskScreen.ts
@@ -0,0 +1,81 @@
+import { Container, Graphics, Sprite } from 'pixi.js';
+import type { TiledMapRenderer } from './TiledMapRenderer';
+
+// The office tileset ships every desk PC twice: a dark, switched-off monitor
+// (gids 365/366 + 381/382 — what the map paints) and the SAME monitor with a
+// lit blue desktop (367/368 + 383/384). DeskScreen overlays the lit variant on
+// a desk's monitor block while its agent is seated, plus a tiny screen-life
+// animation (scrolling lines + a blinking cursor) so the PC visibly works when
+// its owner does. Hidden, the map's off art shows through — no state to undo.
+
+/** gid of the OFF monitor block's top-left tile, as painted in the map. */
+export const MONITOR_OFF_TOPLEFT_GID = 365;
+/** Matching ON tiles, laid out 2×2 directly right of the off block. */
+const ON_GIDS: ReadonlyArray<readonly [number, number, number]> = [
+ // [gid, dx, dy] in tiles relative to the block's top-left
+ [367, 0, 0], [368, 1, 0],
+ [383, 0, 1], [384, 1, 1]
+];
+
+/** Screen interior of the 2×2 (32×32px) block, in local pixels — where the
+ * blue desktop is drawn in the tile art. The animation stays inside it. */
+const SCREEN = { x: 3, y: 5, w: 25, h: 12 };
+
+export class DeskScreen {
+ readonly container = new Container();
+ private anim = new Graphics();
+ private on = false;
+ private t = 0;
+
+ constructor(mapRenderer: TiledMapRenderer, topLeft: { x: number; y: number }) {
+ const ts = mapRenderer.tileSize;
+ for (const [gid, dx, dy] of ON_GIDS) {
+ const tex = mapRenderer.textureForGid(gid);
+ if (!tex) continue;
+ const s = new Sprite(tex);
+ s.x = dx * ts;
+ s.y = dy * ts;
+ this.container.addChild(s);
+ }
+ this.anim.eventMode = 'none';
+ this.container.addChild(this.anim);
+ this.container.x = topLeft.x * ts;
+ this.container.y = topLeft.y * ts;
+ // Sort with the characters: the block's bottom edge sits above the seated
+ // agent's anchor row, so the avatar's head draws over the keyboard, not
+ // under it — same painter's order the map art implies.
+ this.container.zIndex = (topLeft.y + 2) * ts - 1;
+ this.container.visible = false;
+ this.container.eventMode = 'none';
+ }
+
+ /** Light the screen (agent sat down) or cut it (stood up / left). */
+ setOn(on: boolean): void {
+ if (on === this.on) return;
+ this.on = on;
+ this.container.visible = on;
+ if (!on) { this.anim.clear(); this.t = 0; }
+ }
+
+ update(dt: number): void {
+ if (!this.on) return;
+ this.t += dt;
+ const g = this.anim;
+ g.clear();
+ // Two faint "output" lines scrolling up the desktop, wrapping around —
+ // the eternal build log — plus a cursor blinking in the lower left.
+ for (let i = 0; i < 2; i++) {
+ const phase = (this.t * 3.2 + i * (SCREEN.h / 2)) % SCREEN.h;
+ const y = SCREEN.y + SCREEN.h - 1 - phase;
+ const w = 6 + ((i * 7 + Math.floor(this.t / 1.7)) % 9);
+ g.rect(SCREEN.x + 2, Math.round(y), w, 1).fill({ color: 0xcfe6ff, alpha: 0.55 });
+ }
+ if (Math.floor(this.t / 0.53) % 2 === 0) {
+ g.rect(SCREEN.x + 2, SCREEN.y + SCREEN.h - 2, 2, 2).fill({ color: 0xffffff, alpha: 0.9 });
+ }
+ }
+
+ destroy(): void {
+ this.container.destroy({ children: true });
+ }
+}
diff --git a/src/renderer/src/scene/office/OfficeFloor.tsx b/src/renderer/src/scene/office/OfficeFloor.tsx
index 0e7df3c4..a6c4c45c 100644
--- a/src/renderer/src/scene/office/OfficeFloor.tsx
+++ b/src/renderer/src/scene/office/OfficeFloor.tsx
@@ -6,6 +6,7 @@ import { useStore, type Agent } from '@/store/store';
import { TiledMapRenderer, type TiledMap } from './TiledMapRenderer';
import { Camera } from './Camera';
import { Character } from './Character';
+import { DeskScreen, MONITOR_OFF_TOPLEFT_GID } from './DeskScreen';
import { MessageEnvelope, type MessageAct } from './MessageEnvelope';
import { getCastFrames, CAST_BY_NAME, hexToNumber, DEFAULT_CHARACTER } from './cast';
import { pickSoloLine, pickExchange, type BreakSpot } from './cafeteriaLines';
@@ -52,6 +53,13 @@ interface CafeBreak {
chattingWith?: string; // set on the partner: stays put & stays quiet
}
+/** A plant-watering errand in progress for one agent. */
+interface WateringRun {
+ phase: 'walking' | 'watering';
+ timer: number;
+ plantIdx: number;
+}
+
interface Runtime {
character: Character;
seatIndex: number | null;
@@ -62,8 +70,21 @@ interface Runtime {
prevCarrying?: string;
prevPrompt?: string;
brk?: CafeBreak;
+ /** This desk's monitor overlay — lit while its agent is seated. */
+ screen?: DeskScreen;
+ /** Walking a fresh coffee from the break room home to the desk. */
+ cupCarryHome?: boolean;
+ /** Walking the empty desk cup back to the break room. */
+ returningCup?: boolean;
+ wtr?: WateringRun;
}
+/** Lines an avatar throws over its shoulder right after finishing a task. */
+const CHEER_LINES = [
+ 'done! ✔', 'nailed it', "that's a wrap", 'ship it 🚀', 'another one done',
+ 'crushed it', 'in the books'
+] as const;
+
/** Patch the map's external (.tsx) tileset refs with the inline metadata the
* renderer needs — mirrors the reference repo's OfficeScene.init(). */
function resolveMap(): TiledMap {
@@ -331,13 +352,33 @@ export function OfficeFloor() {
rt.brk = undefined;
};
- // End a break gracefully: free the seat, drop the bubble, resume normal idle.
+ // End a break gracefully: free the seat, drop the bubble, resume normal
+ // idle. Most breaks end with TAKING A COFFEE back to the desk: the agent
+ // walks home cup-in-hand, parks it beside the monitor (the tick below
+ // spots the arrival), and wanders off — the cup stays, steaming, until
+ // the next break takes it back to the kitchen.
const endBreak = (id: string, rt: Runtime): void => {
+ const spot = rt.brk ? cafeSpots[rt.brk.spotIdx] : undefined;
+ const arrived = rt.brk?.phase === 'lingering';
releaseBreak(rt);
rt.character.hideThought();
+ if (rt.returningCup) {
+ // The cup made it back to the kitchen (or vanishes with the watchdog).
+ rt.returningCup = false;
+ rt.character.setCarryingCup(false);
+ }
const agent = agentById(id);
- if (agent?.isGod) rt.character.sitAtDesk(true);
- else rt.character.startWandering();
+ if (agent?.isGod) { rt.character.sitAtDesk(true); return; }
+ const takesCoffee = arrived && !!spot
+ && (spot.spot === 'coffee' || (spot.spot === 'table' && Math.random() < 0.6))
+ && !rt.character.hasCupOnDesk();
+ if (takesCoffee) {
+ rt.character.setCarryingCup(true);
+ rt.cupCarryHome = true;
+ rt.character.sitAtDesk(false); // walk it home; the tick parks it
+ } else {
+ rt.character.startWandering();
+ }
};
const startBreak = (id: string, rt: Runtime): void => {
@@ -358,9 +399,20 @@ export function OfficeFloor() {
cafeTaken[idx] = id;
rt.brk = { spotIdx: idx, phase: 'walking', timer: 0, quipTimer: 0 };
const c = rt.character;
+ // A cup still parked on the desk goes back to the kitchen with them.
+ if (c.hasCupOnDesk()) {
+ c.setCupOnDesk(false);
+ c.setCarryingCup(true);
+ rt.returningCup = true;
+ }
c.walkToAndThen(spot.tile, () => {
// Bail if the break was cancelled or reassigned while walking.
if (!rt.brk || rt.brk.spotIdx !== idx) return;
+ if (rt.returningCup) {
+ // Cup returned — onto the tray it goes.
+ rt.returningCup = false;
+ c.setCarryingCup(false);
+ }
if (spot.seated) c.sitInPlace(spot.facing);
else { c.setIdle(); c.faceDirection(spot.facing); }
rt.brk.phase = 'lingering';
@@ -372,7 +424,7 @@ export function OfficeFloor() {
};
const breakEligible = (agent: Agent, rt: Runtime): boolean => {
- if (agent.isGod || rt.brk) return false;
+ if (agent.isGod || rt.brk || rt.wtr || rt.cupCarryHome) return false;
if (agent.status !== 'idle' && agent.status !== 'success') return false;
return !rt.character.isSitting(); // already parked at a desk → leave it
};
@@ -438,6 +490,92 @@ export function OfficeFloor() {
startBreak(agent.id, rt);
};
+ // ─── Plants: watering errands for the truly idle ───────────────────────
+ // The office plants (painted into the map) each have a stand tile next to
+ // them. Every so often one idle agent strolls over, faces the plant, and
+ // gives it a drink — small, purposeful busywork for a quiet floor.
+ const PLANTS: Array<{ stand: Tile; facing: Facing }> = [
+ { stand: { x: 2, y: 20 }, facing: 'left' }, // tall plant, bottom-left corner
+ { stand: { x: 22, y: 20 }, facing: 'right' }, // tall plant, end of the desk rows
+ { stand: { x: 30, y: 20 }, facing: 'right' }, // tall plant, right room
+ { stand: { x: 6, y: 4 }, facing: 'up' }, // potted plant, the CEO office
+ { stand: { x: 17, y: 4 }, facing: 'up' } // potted plant, the corridor
+ ];
+ const plantTaken: (string | null)[] = new Array(PLANTS.length).fill(null);
+
+ const releaseWatering = (id: string, rt: Runtime): void => {
+ if (!rt.wtr) return;
+ plantTaken[rt.wtr.plantIdx] = null;
+ rt.wtr = undefined;
+ rt.character.stopWatering();
+ };
+
+ let wtrCooldown = 20;
+ const updateWatering = (dt: number): void => {
+ // Watchdog walking errands that never arrive; everything else is event-driven.
+ for (const [id, rt] of runtimes) {
+ if (!rt.wtr) continue;
+ rt.wtr.timer += dt;
+ if (rt.wtr.phase === 'walking' && rt.wtr.timer > 20) {
+ releaseWatering(id, rt);
+ rt.character.startWandering();
+ }
+ }
+ wtrCooldown -= dt;
+ if (wtrCooldown > 0) return;
+ wtrCooldown = 16 + Math.random() * 22;
+ if (Math.random() >= 0.6) return; // keep it occasional
+ const freePlants = PLANTS.map((_, i) => i).filter((i) => !plantTaken[i]);
+ if (freePlants.length === 0) return;
+ const candidates: Array<[Agent, Runtime]> = [];
+ for (const agent of useStore.getState().agents) {
+ const rt = runtimes.get(agent.id);
+ if (rt && breakEligible(agent, rt)) candidates.push([agent, rt]);
+ }
+ if (candidates.length === 0) return;
+ const [agent, rt] = candidates[Math.floor(Math.random() * candidates.length)];
+ const plantIdx = freePlants[Math.floor(Math.random() * freePlants.length)];
+ const plant = PLANTS[plantIdx];
+ const c = rt.character;
+ plantTaken[plantIdx] = agent.id;
+ rt.wtr = { phase: 'walking', timer: 0, plantIdx };
+ c.walkToAndThen(plant.stand, () => {
+ if (!rt.wtr || rt.wtr.plantIdx !== plantIdx) return;
+ rt.wtr.phase = 'watering';
+ rt.wtr.timer = 0;
+ c.faceDirection(plant.facing);
+ c.showThought('watering the plants 🌿');
+ c.startWatering(4.5, () => {
+ releaseWatering(agent.id, rt);
+ c.hideThought();
+ c.startWandering();
+ });
+ });
+ };
+
+ // ─── Coffee delivery + desk screens, every frame ───────────────────────
+ const updateDeskLife = (dt: number): void => {
+ for (const [id, rt] of runtimes) {
+ // Park the carried coffee the moment its courier is seated at home —
+ // then, if there's still nothing to do, get up and wander off (the
+ // cup stays, steaming, beside the monitor).
+ if (rt.cupCarryHome && rt.character.isSittingAtDesk()) {
+ rt.cupCarryHome = false;
+ rt.character.setCarryingCup(false);
+ rt.character.setCupOnDesk(true);
+ const agent = agentById(id);
+ if (agent && !agent.isGod && (agent.status === 'idle' || agent.status === 'success')) {
+ rt.character.startWandering();
+ }
+ }
+ // The monitor lights up whenever its owner is in the chair.
+ if (rt.screen) {
+ rt.screen.setOn(rt.character.isSittingAtDesk());
+ rt.screen.update(dt);
+ }
+ }
+ };
+
const addCharacter = async (agent: Agent) => {
const charName = CAST_BY_NAME[agent.character] ? agent.character : DEFAULT_CHARACTER;
const member = CAST_BY_NAME[charName];
@@ -464,15 +602,30 @@ export function OfficeFloor() {
onClick: (id) => useStore.getState().select(id),
});
character.show(charLayer);
- runtimes.set(agent.id, { character, seatIndex, waitTile, charName });
- applyState(agent, runtimes.get(agent.id)!, true);
+ const rt: Runtime = { character, seatIndex, waitTile, charName };
+ // Standard desks paint the 2×2 PC monitor two rows above the seat —
+ // give those a DeskScreen (lights up while seated) and a cup spot
+ // beside the monitor, exactly where the tileset's baked-in mug used
+ // to sit before we cleared it (desks start clean now; cups only exist
+ // where an agent actually carried one).
+ if (mapRenderer.gidAt('furniture-above', seatTile.x, seatTile.y - 2) === MONITOR_OFF_TOPLEFT_GID) {
+ const top = { x: seatTile.x, y: seatTile.y - 2 };
+ rt.screen = new DeskScreen(mapRenderer, top);
+ charLayer.addChild(rt.screen.container);
+ const ts2 = mapRenderer.tileSize;
+ character.setCupSpot({ x: top.x * ts2 + 18, y: top.y * ts2 + 23 });
+ }
+ runtimes.set(agent.id, rt);
+ applyState(agent, rt, true);
};
const removeCharacter = (id: string) => {
const rt = runtimes.get(id);
if (!rt) return;
releaseBreak(rt); // free any café seat it was holding
+ releaseWatering(id, rt); // and any plant it was tending
if (rt.seatIndex != null) seatClaims.delete(rt.seatIndex);
+ rt.screen?.destroy();
rt.character.hide(0);
// give the fade-out a moment, then destroy
setTimeout(() => rt.character.destroy(), 700);
@@ -487,6 +640,11 @@ export function OfficeFloor() {
|| rt.prevCarrying !== agent.carrying
|| rt.prevPrompt !== agent.lastPrompt;
if (!changed) return;
+ // Finishing real work (working/thinking/compacting → done) earns a
+ // little celebration before the avatar goes back to roaming.
+ const finishedWork = !force && !agent.isGod
+ && (rt.prevStatus === 'working' || rt.prevStatus === 'thinking' || rt.prevStatus === 'compacting')
+ && (agent.status === 'idle' || agent.status === 'success');
rt.prevStatus = agent.status;
rt.prevAction = agent.action;
rt.prevCarrying = agent.carrying;
@@ -506,6 +664,15 @@ export function OfficeFloor() {
}
releaseBreak(rt);
}
+ // Same for a watering errand: idle refreshes leave it alone, real work
+ // cancels it (the can disappears, the agent heads to its desk).
+ if (rt.wtr) {
+ if (agent.status === 'idle' || agent.status === 'success') {
+ c.setStatusGlyph(agent.status === 'success' ? 'success' : 'none');
+ return;
+ }
+ releaseWatering(agent.id, rt);
+ }
// A thought cloud above the head shows what the agent is doing RIGHT NOW
// (its live `action`, e.g. "edit App.tsx"). Working → sit at the desk;
@@ -546,8 +713,14 @@ export function OfficeFloor() {
break;
case 'success':
c.setStatusGlyph('success');
- c.hideThought();
- if (agent.isGod) c.sitAtDesk(true); else c.startWandering();
+ if (agent.isGod) { c.hideThought(); c.sitAtDesk(true); break; }
+ c.startWandering();
+ if (finishedWork) {
+ c.cheer();
+ c.showThought(CHEER_LINES[Math.floor(Math.random() * CHEER_LINES.length)]);
+ } else {
+ c.hideThought();
+ }
break;
case 'ghost':
c.setStatusGlyph('none');
@@ -559,6 +732,12 @@ export function OfficeFloor() {
c.setStatusGlyph('none');
// The god runs the floor from its desk; everyone else wanders when idle.
if (agent.isGod) { c.sitAtDesk(true); c.showThought(liveActivity(agent, 'running the floor')); }
+ else if (finishedWork) {
+ // Task done → a quick cheer on the spot, then back to roaming.
+ c.startWandering();
+ c.cheer();
+ c.showThought(CHEER_LINES[Math.floor(Math.random() * CHEER_LINES.length)]);
+ }
else { c.startWandering(); c.showThought(liveActivity(agent, 'idle')); }
break;
}
@@ -680,6 +859,8 @@ export function OfficeFloor() {
rt.character.update(dt);
}
updateCafeteria(dt);
+ updateWatering(dt);
+ updateDeskLife(dt);
resolveBubbleOverlaps();
for (let i = envelopes.length - 1; i >= 0; i--) {
if (envelopes[i].update(dt)) {
diff --git a/src/renderer/src/scene/office/TiledMapRenderer.ts b/src/renderer/src/scene/office/TiledMapRenderer.ts
index 7ec4b3d0..8ced244a 100644
--- a/src/renderer/src/scene/office/TiledMapRenderer.ts
+++ b/src/renderer/src/scene/office/TiledMapRenderer.ts
@@ -101,6 +101,31 @@ export class TiledMapRenderer {
getZone(name: string): ZoneRect | undefined { return this.zones.get(name); }
getAllZones(): Map<string, ZoneRect> { return this.zones; }
+ /** The (flip-stripped) gid painted at a tile of a layer, 0 when empty.
+ * Lets the scene locate furniture by art — e.g. each desk's monitor block. */
+ gidAt(layerName: string, tx: number, ty: number): number {
+ const layer = this.findLayer(layerName, 'tilelayer');
+ if (!layer?.data || tx < 0 || ty < 0 || tx >= this.width || ty >= this.height) return 0;
+ return (layer.data[ty * this.width + tx] ?? 0) & TILE_ID_MASK;
+ }
+
+ /** A sub-texture for one tileset tile, addressed by gid — for dynamic props
+ * that reuse map art (e.g. the lit monitor variant overlaid when an agent
+ * sits down). Returns undefined for gid 0 / out-of-range. */
+ textureForGid(gid: number): Texture | undefined {
+ const tileId = gid & TILE_ID_MASK;
+ if (tileId === 0) return undefined;
+ const resolved = this.resolveTileset(tileId);
+ if (!resolved) return undefined;
+ const { tileset, texture } = resolved;
+ const cols = tileset.columns ?? 16;
+ const tw = tileset.tilewidth ?? this.tileSize;
+ const th = tileset.tileheight ?? this.tileSize;
+ const localId = tileId - tileset.firstgid;
+ const frame = new Rectangle((localId % cols) * tw, Math.floor(localId / cols) * th, tw, th);
+ return new Texture({ source: texture.source, frame });
+ }
+
private parseCollisionLayer(): void {
const layer = this.findLayer(COLLISION_LAYER, 'tilelayer');
this.walkabilityGrid = Array.from({ length: this.height }, () => Array(this.width).fill(true));