Skip to content

Current questions and answers regarding the map editor.

User Avatar
#3102
Auto-translated
There is a function called EnableHeroAI(sHeroName, bEnable). Is there a function that checks the state of bEnable? Something like IsEnableHeroAI?
There isn't such a function, but it's easy to create one.
local enable_hero_ai = EnableHeroAI
local disabled = {}
function EnableHeroAI(hero, enable)
  %enable_hero_ai(hero, enable)
  %disabled[hero] = not enable
end

function IsHeroEnabled(hero)
  return not %disabled[hero]
end
Карты для Героев Меча и Магии 5
Одиночные: Завеса срывается, Посол, Последний рывок, Эхо Пустоты
Кампания: Империя Единорога

Существа NCF
Орден Порядка: 1
Нейтралы: 1 2 3 4