Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Trying to cure a dead patient #2562

Open
Lobashev opened this issue Apr 22, 2024 · 7 comments
Open

[Bug] Trying to cure a dead patient #2562

Lobashev opened this issue Apr 22, 2024 · 7 comments
Labels
bug issue type S:Reproducible State

Comments

@Lobashev
Copy link

Describe the issue

Surgeons will attempt to treat a dead patient. But they won't succeed.
There's a long line for the surgery room. I've built a second surgery room. The patient went to the second room and got in line.
image

By the time it was his turn, he should have been dead.
image

But he went in. He was operated on. They didn't take any money. He started to change his clothes to get out. And then the game freezes.
image
image

Steps to Reproduce

  1. Load Autosave9.sav
  2. Move the camera to the right-bottom corner of the hospital, where the operating room is
  3. Wait for the surgeons to treat the current patient
  4. The next patient to come in is the dead patient. He will be operated on. After he gets up, they don't charge him. He will go to change his clothes and at that point the game will freeze

Expected Behaviour

The patient should not go into the office, but die in the hallway

Save Game

Autosave9.zip

CorsixTH Version

0.67

Operating System

Windows 11

Theme Hospital Version

Origin

Gamelog.txt

Gamelog generated on 2024-04-22 10:10:44
Compiled with api_version: 2684, arch: x64, audio: true, os: windows
SDL renderer: direct3d
Lua 5.4 run with api version: 2684, game version: v0.67, savegame version: 180
Created game with savegame version 180.
Savegame version is 180 (v0.67), originally it was 180 (v0.67).
Warning: Trying to remove nonexistent room build callback (function: 0000026810919BD0) from humanoid (table: 0000026836AC3A60).
Warning: Trying to remove nonexistent room remove callback (function: 0000026836F8EAA0) from humanoid (table: 0000026836AC3A60).
Warning: Trying to remove nonexistent staff callback (function: 00000268109198D0) from humanoid (table: 0000026836AC3A60).
Warning: Trying to remove nonexistent room build callback (function: 000002680FE16AD0) from humanoid (table: 0000026836A29ED0).
Warning: Trying to remove nonexistent room remove callback (function: 00000268366D37B0) from humanoid (table: 0000026836A29ED0).
Warning: Trying to remove nonexistent staff callback (function: 000002680FE17610) from humanoid (table: 0000026836A29ED0).
Savegame version is 180 (v0.67), originally it was 180 (v0.67).
Warning: Trying to remove nonexistent room build callback (function: 0000023F42D0B7C0) from humanoid (table: 0000023F4323AB20).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F44286890) from humanoid (table: 0000023F4323AB20).
Warning: Trying to remove nonexistent staff callback (function: 0000023F42D0B700) from humanoid (table: 0000023F4323AB20).
Warning: Trying to remove nonexistent room build callback (function: 0000023F42D10620) from humanoid (table: 0000023F35F28AD0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F44289E90) from humanoid (table: 0000023F35F28AD0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F42D0FEA0) from humanoid (table: 0000023F35F28AD0).
Warning: Trying to resolve door deadlock at (71, 91)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4640E850) from humanoid (table: 0000023F45A099F0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47B6E160) from humanoid (table: 0000023F45A099F0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4640ED30) from humanoid (table: 0000023F45A099F0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F46414070) from humanoid (table: 0000023F456201B0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47BA2220) from humanoid (table: 0000023F456201B0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F46413410) from humanoid (table: 0000023F456201B0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D1960) from humanoid (table: 0000023F35A277A0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47ABD660) from humanoid (table: 0000023F35A277A0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D1D20) from humanoid (table: 0000023F35A277A0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F39FF6980) from humanoid (table: 0000023F21AB7820).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4856DEF0) from humanoid (table: 0000023F21AB7820).
Warning: Trying to remove nonexistent staff callback (function: 0000023F39FF6560) from humanoid (table: 0000023F21AB7820).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464CFC80) from humanoid (table: 0000023F45AE2B00).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F461AE900) from humanoid (table: 0000023F45AE2B00).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464CFB00) from humanoid (table: 0000023F45AE2B00).
Warning: Trying to resolve door deadlock at (78, 91)
Warning: Trying to remove nonexistent room build callback (function: 0000023F42D10DA0) from humanoid (table: 0000023F462A9040).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F46B762E0) from humanoid (table: 0000023F462A9040).
Warning: Trying to remove nonexistent staff callback (function: 0000023F42D10C80) from humanoid (table: 0000023F462A9040).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D44E0) from humanoid (table: 0000023F36BB33E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47950B00) from humanoid (table: 0000023F36BB33E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D4180) from humanoid (table: 0000023F36BB33E0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D2EC0) from humanoid (table: 0000023F456E3A60).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F48D4F680) from humanoid (table: 0000023F456E3A60).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D1FC0) from humanoid (table: 0000023F456E3A60).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D0100) from humanoid (table: 0000023F46668B20).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F479562E0) from humanoid (table: 0000023F46668B20).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D0DC0) from humanoid (table: 0000023F46668B20).
Warning: Trying to remove nonexistent room build callback (function: 0000023F42D107A0) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4C8E2140) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent staff callback (function: 0000023F42D11DC0) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464CFF20) from humanoid (table: 0000023F45756B30).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F48D6F370) from humanoid (table: 0000023F45756B30).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D16C0) from humanoid (table: 0000023F45756B30).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4640E970) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F46B78DD0) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4640F210) from humanoid (table: 0000023F36DB4120).
Warning: Trying to remove nonexistent room build callback (function: 0000023F39FF1EE0) from humanoid (table: 0000023F45C0D570).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F453B61B0) from humanoid (table: 0000023F45C0D570).
Warning: Trying to remove nonexistent staff callback (function: 0000023F39FF16A0) from humanoid (table: 0000023F45C0D570).
Warning: Trying to remove nonexistent room build callback (function: 0000023F46412810) from humanoid (table: 0000023F45549DF0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47789E30) from humanoid (table: 0000023F45549DF0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464127B0) from humanoid (table: 0000023F45549DF0).
Warning: Trying to resolve door deadlock at (86, 86)
Warning: Trying to resolve door deadlock at (86, 86)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4906D310) from humanoid (table: 0000023F456E4220).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F48D99F10) from humanoid (table: 0000023F456E4220).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4906D2B0) from humanoid (table: 0000023F456E4220).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D25C0) from humanoid (table: 0000023F36105220).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47960000) from humanoid (table: 0000023F36105220).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D1E40) from humanoid (table: 0000023F36105220).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D5A40) from humanoid (table: 0000023F4612C0A0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4CB08840) from humanoid (table: 0000023F4612C0A0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D59E0) from humanoid (table: 0000023F4612C0A0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4C94D730) from humanoid (table: 0000023F226699F0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4C87DDC0) from humanoid (table: 0000023F226699F0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4C94D130) from humanoid (table: 0000023F226699F0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F39FF6440) from humanoid (table: 0000023F45AE41C0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4CE55E30) from humanoid (table: 0000023F45AE41C0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F39FF6DA0) from humanoid (table: 0000023F45AE41C0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D0B20) from humanoid (table: 0000023F462A6000).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F435FF1C0) from humanoid (table: 0000023F462A6000).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D0220) from humanoid (table: 0000023F462A6000).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464D8680) from humanoid (table: 0000023F36B9D9E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F435FCB50) from humanoid (table: 0000023F36B9D9E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464D79C0) from humanoid (table: 0000023F36B9D9E0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4906EAB0) from humanoid (table: 0000023F36101120).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F48D49650) from humanoid (table: 0000023F36101120).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4906E4B0) from humanoid (table: 0000023F36101120).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D6846D0) from humanoid (table: 0000023F45C06570).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D389DA0) from humanoid (table: 0000023F45C06570).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D683770) from humanoid (table: 0000023F45C06570).
Warning: Trying to resolve door deadlock at (67, 91)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D68E2D0) from humanoid (table: 0000023F46501680).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F35810870) from humanoid (table: 0000023F46501680).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D68E6F0) from humanoid (table: 0000023F46501680).
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE0080) from humanoid (table: 0000023F4D0E9BD0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F46A8FB70) from humanoid (table: 0000023F4D0E9BD0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FDF4E0) from humanoid (table: 0000023F4D0E9BD0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D689EF0) from humanoid (table: 0000023F45C849E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F47BA5EB0) from humanoid (table: 0000023F45C849E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D68A430) from humanoid (table: 0000023F45C849E0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D68F2F0) from humanoid (table: 0000023F456DD4E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F49E189F0) from humanoid (table: 0000023F456DD4E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D68FBF0) from humanoid (table: 0000023F456DD4E0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE6FE0) from humanoid (table: 0000023F432390A0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F48D50280) from humanoid (table: 0000023F432390A0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FE7A60) from humanoid (table: 0000023F432390A0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE25A0) from humanoid (table: 0000023F36BA9420).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4CD05120) from humanoid (table: 0000023F36BA9420).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FE2420) from humanoid (table: 0000023F36BA9420).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D689410) from humanoid (table: 0000023F4619D7E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D057120) from humanoid (table: 0000023F4619D7E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D689D70) from humanoid (table: 0000023F4619D7E0).
Warning: Trying to resolve door deadlock at (67, 91)
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE0DA0) from humanoid (table: 0000023F4650F040).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F485740D0) from humanoid (table: 0000023F4650F040).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FE0D40) from humanoid (table: 0000023F4650F040).
Warning: Trying to remove nonexistent room build callback (function: 0000023F464CE660) from humanoid (table: 0000023F45750830).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D972D30) from humanoid (table: 0000023F45750830).
Warning: Trying to remove nonexistent staff callback (function: 0000023F464CD8E0) from humanoid (table: 0000023F45750830).
Warning: Trying to resolve door deadlock at (79, 86)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D686530) from humanoid (table: 0000023F456DFFA0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4C94EF00) from humanoid (table: 0000023F456DFFA0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D686EF0) from humanoid (table: 0000023F456DFFA0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4E78E4B0) from humanoid (table: 0000023F456BD7E0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4DA2D540) from humanoid (table: 0000023F456BD7E0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4E78ED50) from humanoid (table: 0000023F456BD7E0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE6620) from humanoid (table: 0000023F3637CFF0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E7B5190) from humanoid (table: 0000023F3637CFF0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FE65C0) from humanoid (table: 0000023F3637CFF0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4DF46740) from humanoid (table: 0000023F4DA75B60).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E427290) from humanoid (table: 0000023F4DA75B60).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4DF45CC0) from humanoid (table: 0000023F4DA75B60).
Warning: Trying to remove nonexistent room build callback (function: 0000023F48FE5180) from humanoid (table: 0000023F4E2E1CE0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4CD05690) from humanoid (table: 0000023F4E2E1CE0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F48FE5120) from humanoid (table: 0000023F4E2E1CE0).
Warning: Trying to resolve door deadlock at (67, 91)
Warning: Trying to resolve door deadlock at (71, 91)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4DAEDF50) from humanoid (table: 0000023F36944910).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F485726F0) from humanoid (table: 0000023F36944910).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4DAEE790) from humanoid (table: 0000023F36944910).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4DBA9B50) from humanoid (table: 0000023F4D0F9010).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D8AE670) from humanoid (table: 0000023F4D0F9010).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4DBA9AF0) from humanoid (table: 0000023F4D0F9010).
Warning: Trying to resolve door deadlock at (71, 86)
Warning: Trying to resolve door deadlock at (45, 87)
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D74CCD0) from humanoid (table: 0000023F4E414270).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D8B36E0) from humanoid (table: 0000023F4E414270).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D74C5B0) from humanoid (table: 0000023F4E414270).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D74FCD0) from humanoid (table: 0000023F45542070).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D8ADDA0) from humanoid (table: 0000023F45542070).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D74FAF0) from humanoid (table: 0000023F45542070).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D74D390) from humanoid (table: 0000023F456251B0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4C94D610) from humanoid (table: 0000023F456251B0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D74BFB0) from humanoid (table: 0000023F456251B0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F49AE0090) from humanoid (table: 0000023F45620D70).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E7AA720) from humanoid (table: 0000023F45620D70).
Warning: Trying to remove nonexistent staff callback (function: 0000023F49ADF670) from humanoid (table: 0000023F45620D70).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4CC0E240) from humanoid (table: 0000023F216EE720).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F446E8C10) from humanoid (table: 0000023F216EE720).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4CC0E6C0) from humanoid (table: 0000023F216EE720).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4CC10D00) from humanoid (table: 0000023F46533060).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4D84D220) from humanoid (table: 0000023F46533060).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4CC10A00) from humanoid (table: 0000023F46533060).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4C9F4A80) from humanoid (table: 0000023F431F2B70).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E0DDD40) from humanoid (table: 0000023F431F2B70).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4C9F49C0) from humanoid (table: 0000023F431F2B70).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4D74F0D0) from humanoid (table: 0000023F45B380B0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E0B5FF0) from humanoid (table: 0000023F45B380B0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4D74F3D0) from humanoid (table: 0000023F45B380B0).
Warning: Trying to remove nonexistent room build callback (function: 0000023F49ADEEF0) from humanoid (table: 0000023F3692B250).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4794E910) from humanoid (table: 0000023F3692B250).
Warning: Trying to remove nonexistent staff callback (function: 0000023F49ADF010) from humanoid (table: 0000023F3692B250).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4C9F6BE0) from humanoid (table: 0000023F2F5F3180).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F4E0E3E60) from humanoid (table: 0000023F2F5F3180).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4C9F6760) from humanoid (table: 0000023F2F5F3180).
Warning: Trying to remove nonexistent room build callback (function: 0000023F4CC10100) from humanoid (table: 0000023F35BCFDA0).
Warning: Trying to remove nonexistent room remove callback (function: 0000023F49C8A760) from humanoid (table: 0000023F35BCFDA0).
Warning: Trying to remove nonexistent staff callback (function: 0000023F4CC0F9E0) from humanoid (table: 0000023F35BCFDA0).
Savegame version is 180 (v0.67), originally it was 180 (v0.67).
Warning: Trying to remove nonexistent room build callback (function: 00000227C9B44A10) from humanoid (table: 00000227D6010E70).
Warning: Trying to remove nonexistent room remove callback (function: 00000227E136F7C0) from humanoid (table: 00000227D6010E70).
Warning: Trying to remove nonexistent staff callback (function: 00000227C9B43810) from humanoid (table: 00000227D6010E70).
Warning: Trying to remove nonexistent room build callback (function: 00000227EA63DC60) from humanoid (table: 00000227CAC14050).
Warning: Trying to remove nonexistent room remove callback (function: 00000227CADB2B30) from humanoid (table: 00000227CAC14050).
Warning: Trying to remove nonexistent staff callback (function: 00000227EA63D420) from humanoid (table: 00000227CAC14050).
Warning: Trying to remove nonexistent room build callback (function: 00000227EA521140) from humanoid (table: 00000227EA6B52F0).
Warning: Trying to remove nonexistent room remove callback (function: 00000227D7DBE3B0) from humanoid (table: 00000227EA6B52F0).
Warning: Trying to remove nonexistent staff callback (function: 00000227EA521620) from humanoid (table: 00000227EA6B52F0).
Warning: Trying to remove nonexistent room build callback (function: 00000227E9B2C900) from humanoid (table: 00000227CB332A20).
Warning: Trying to remove nonexistent room remove callback (function: 00000227EA651070) from humanoid (table: 00000227CB332A20).
Warning: Trying to remove nonexistent staff callback (function: 00000227E9B2BE80) from humanoid (table: 00000227CB332A20).
Warning: Trying to remove nonexistent room build callback (function: 00000227E9B2E880) from humanoid (table: 00000227CAE70FB0).
Warning: Trying to remove nonexistent room remove callback (function: 00000227EBA5F950) from humanoid (table: 00000227CAE70FB0).
Warning: Trying to remove nonexistent staff callback (function: 00000227E9B2E700) from humanoid (table: 00000227CAE70FB0).
Warning: Trying to remove nonexistent room build callback (function: 00000227EA201AC0) from humanoid (table: 00000227CB1550A0).
Warning: Trying to remove nonexistent room remove callback (function: 00000227EC6B0460) from humanoid (table: 00000227CB1550A0).
Warning: Trying to remove nonexistent staff callback (function: 00000227EA2017C0) from humanoid (table: 00000227CB1550A0).
Warning: Trying to remove nonexistent room build callback (function: 00000227EA201340) from humanoid (table: 00000227EABA41F0).
Warning: Trying to remove nonexistent room remove callback (function: 00000227ED7D9A20) from humanoid (table: 00000227EABA41F0).
Warning: Trying to remove nonexistent staff callback (function: 00000227EA200620) from humanoid (table: 00000227EABA41F0).
Savegame version is 180 (v0.67), originally it was 180 (v0.67).
Error in timer handler: 
Lua\entities\humanoid.lua:472: assertion failed!
stack traceback:
	[C]: in function 'assert'
	Lua\entities\humanoid.lua:472: in method 'startAction'
	Lua\entities\humanoid.lua:577: in method 'finishAction'
	Lua\humanoid_actions\use_screen.lua:48: in local 'timer_function'
	Lua\entity.lua:216: in method 'tick'
	Lua\world.lua:1074: in method 'onTick'
	Lua\app.lua:1202: in function <Lua\app.lua:1199>
	(...tail calls...)
	Lua\app.lua:1102: in function <Lua\app.lua:1097>

Additional Information

No response

@Lobashev Lobashev added the bug issue type label Apr 22, 2024
@lewri
Copy link
Member

lewri commented Apr 24, 2024

Thanks for this report. Is the error reproducable from the save provided or has it already happened?

@lewri
Copy link
Member

lewri commented Apr 24, 2024

By the time it was his turn, he should have been dead.

Did he get up from the bench then sit back down again do you know?

@Lobashev
Copy link
Author

@lewri

Thanks for this report. Is the error reproducable from the save provided or has it already happened?

Can be reproduced from save

Did he get up from the bench then sit back down again do you know?

Just got up and went to the office. This can be seen in the save

@lewri
Copy link
Member

lewri commented Apr 26, 2024

Clicked on:
humanoid - class: Standard Male Patient
Warmth: 0.324   Happiness: 1.000   Fatigue: 0.000  Thirst: 0.493  Toilet_Need: 0.528   Health: 0.000   Service Quality: 0.000
Actions: [use_object - bench   must_happen, queue - Bench distance: 0 Standing: false   must_happen, walk - going to 93:68   must_happen, meander, die]

Already dead in the save. @mugmuggy if you're around any ideas if this may have slipped past #2310 ?

Edit: Potentially related to the issue in 0.66 where an action got interrupted and blocked dying. If you pick up the patient's bench, then kill them again via debug script they die properly.

Imo while we need to indeed fix bugs like these, our crash handling function for the action queue isn't really robust enough. Specifically, we just ignore any going_home patients indiscriminatingly.

--! Handle an empty action queue in some way instead of crashing.
function Humanoid:_handleEmptyActionQueue()
-- if this is a patient that is going home, an empty
-- action queue is not a problem
if class.is(self, Patient) and self.going_home then
return
end

@mugmuggy
Copy link
Contributor

@lewri Can't be definitive, but I would say its 'interrupted' twice. The obvious issue for me is that the queue action in the action queue position is immediately outside the door and the walk is to in the room. The must happen and saved must happen are true on the walk action so they will enter and it can't be interrupted until after the first tile is walked.

As there are those multiple bits of code that are interrupting actions that cause it to be written and processed makes it harder or uglier to resolve this specific case.

@lewri
Copy link
Member

lewri commented Apr 28, 2024

Thanks muggy,

When I was playing around I found that if you found a way to initiate some kind of queue update or kicked them off the bench the problematic must happen was unblocked.

Should we still try and prevent a crash when it falls over though for now? It probably isn't always good enough to ignore an empty action queue if the going home flag is true.

@lewri
Copy link
Member

lewri commented Apr 29, 2024

The obvious issue for me is that the queue action in the action queue position is immediately outside the door and the walk is to in the room. The must happen and saved must happen are true on the walk action so they will enter and it can't be interrupted until after the first tile is walked.

Replicated this, can confirm it's the bench position.

Another interesting part is that if a patient sits at the problematic bench and the walk action does not have must_happen they will die fine.

You can hack the queue to account for this but it probably isn't the right solution:

function Patient:die()
  -- It may happen that this patient was just cured and then the room blew up.
  self.hospital:humanoidDeath(self)
  self:setMood("dead", "activate")

  -- Remove any messages and/or callbacks related to the patient.
  self:unregisterCallbacks()

  self.going_home = true
  if self:getRoom() then
    self:queueAction(MeanderAction():setCount(1))
  else
+   for _, act in ipairs(self.action_queue) do
+     if act.name == "walk" and act.must_happen then act.must_happen = false end
+   end
    self:setNextAction(MeanderAction():setCount(1))
  end
  self:queueAction(DieAction())
  self:setDynamicInfoText(_S.dynamic_info.patient.actions.dying)
end

@lewri lewri added the S:Reproducible State label Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug issue type S:Reproducible State
Projects
None yet
Development

No branches or pull requests

3 participants