# The madman is killed first, afterwards both amulet parts are collected and united anyway
# (original game and Advanced, any language).
# Expected: after the madman's death the amulet steps stay hidden for good, also after loading
# (the amulet steps check that the madman was not killed).
waitidle 20000
dismissall
cheat give 138 10
cheat level 50
talkwait
dismissall
cheat light 3
# --- chest 39 (B O S amulet and cell key)
goto 267 18 7
trigger 18 6 Eye
talkwait
usekey 138
talkwait
takeloot
closewindow
talkwait
count 263 1
quest Madman_FindTheSecondPartOfTheAmulet Active
# --- cell door and fight
goto 267 5 13
trigger 5 12 Eye
talkwait
usekey 261
talkwait
dismissall
goto 267 5 11
talkwait
trigger 5 11
waitbattle 15000
cheat win
talkwait
takeloot
closewindow
talkwait
waitidle 5000
quest Madman_KillTheMadman Completed
quest Madman_FindTheSecondPartOfTheAmulet Inactive
# --- the T A R amulet from Thornahuun
cheat light 3
goto 433 5 7
talkwait
trigger 5 6
talkwait
waitbattle 20000
cheat win
talkwait
takeloot
count 264 1
closewindow
talkwait
quests
# expected: still hidden (likely actual: Find Completed, Unite Active)
quest Madman_FindTheSecondPartOfTheAmulet Inactive
quest Madman_UniteTheAmulet Inactive
# --- Theresa unites them anyway
goto 287 26 14
wait 2000
dismissall
talk 22
talkwait
giveitem 264
talkwait 20000
takeitems
leave
talkwait
waitidle 5000
count 265 1
quests
# expected: still hidden (likely actual: Unite Completed, Give Active)
quest Madman_UniteTheAmulet Inactive
quest Madman_GiveTheAmuletToTheMadman Inactive
reloadquests
log after reload
quests
quest Madman_KillTheMadman Completed
quest Madman_FindTheSecondPartOfTheAmulet Inactive
quest Madman_UniteTheAmulet Inactive
quest Madman_GiveTheAmuletToTheMadman Inactive
exit
