Skip to content
#1979
Auto-translated
Probably, this question is off-topic, but does anyone know how to change the class skills of heroes? For example, an Orc can cast spells, but cannot learn them at the magic school (they will be given as rewards for quests) and does not use battle cries.

Added 6 minutes later
I want to create a script:
function alive()
while IsHeroAlive("Hero9") do
sleep(10)
end
Loose()
-- and this --
Loose(1)
end

startThread(alive)
function MestoK (heroname)
if heroname == "Hero9"
then MEssageBox (GetMapDataPath().."MestoK.txt")
Trigger(REGION_ENTER_AND_STOP_TRIGGER, "Mesto", nil)
end;
end;

Trigger(REGION_ENTER_AND_STOP_TRIGGER, "Mesto", "MestoK");
The second one doesn't work. Please tell me what the error is.

Added 38 seconds later
Where there are the letters "eee", there is "ili" instead.