From f3a140b0471688afbd195e4ccab13256393e23fd Mon Sep 17 00:00:00 2001 From: Anders Jenbo Date: Fri, 19 Apr 2019 03:57:29 +0200 Subject: [PATCH] Clean up TownDead --- Source/towners.cpp | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/Source/towners.cpp b/Source/towners.cpp index 675586d86..081b89ba7 100644 --- a/Source/towners.cpp +++ b/Source/towners.cpp @@ -448,24 +448,22 @@ void TownBarOwner() void TownDead() { - int v0; // esi - int v1; // eax + int tidx; - v0 = GetActiveTowner(TOWN_DEADGUY); - TownCtrlMsg(v0); - if (qtextflag) - goto LABEL_6; - if ((quests[6]._qactive != 2 || quests[6]._qlog) && quests[6]._qactive != 1) { - v1 = v0; - towner[v1]._tAnimDelay = 1000; - towner[v1]._tAnimFrame = 1; - strcpy(towner[v0]._tName, "Slain Townsman"); - LABEL_6: - if (quests[QTYPE_BUTCH]._qactive != 1) - towner[v0]._tAnimCnt = 0; + tidx = GetActiveTowner(TOWN_DEADGUY); + TownCtrlMsg(tidx); + if (!qtextflag) { + if ((quests[6]._qactive != 2 || quests[6]._qlog) && quests[6]._qactive != 1) { + towner[tidx]._tAnimDelay = 1000; + towner[tidx]._tAnimFrame = 1; + strcpy(towner[tidx]._tName, "Slain Townsman"); + } else { + return; + } } + if (quests[QTYPE_BUTCH]._qactive != 1) + towner[tidx]._tAnimCnt = 0; } -// 646D00: using guessed type char qtextflag; void TownHealer() {