Auto-translated
Good people, please help me with some advice. I really want to set up a strong army to guard the dwarven treasure. I made the object inactive and added a trigger on touch with the question "Are you ready to fight the guardian?". If the answer is yes, a message should appear, and a battle should begin. The message appears, but the battle doesn't happen. I would like to understand why. I will be grateful for any help, because I'm tired of tinkering with it.
```
dir = GetMapDataPath()
Trigger(OBJECT_TOUCH_TRIGGER, "tres1", "tres1F")
function tres1F (heroName)
number=GetCurrentPlayer()
QuestionBoxForPlayers(number,dir.."Capture.txt", "captureF", "nocaptureF")
end
function captureF (heroName)
number=GetCurrentPlayer()
MessageBoxForPlayers(number,dir.."gettreasure.txt")
StartCombat (heroName, nil, 2,
CREATURE_THANE, 20,
CREATURE_WARLORD, 20, nil)
end
function alreadyCapturedF (heroName)
number=GetCurrentPlayer()
MessageBoxForPlayers(number,dir.."alreadyCaptured.txt")
end
function nocaptureF (heroName)
number=GetCurrentPlayer()
MessageBoxForPlayers(number,dir.."Coward.txt")
end
SetObjectEnabled("tres1", false)