Skip to content
User Avatar
#1845
Auto-translated
RedHeavenHero
UnitCastAreaSpell(unit, spell_id, x, y) -- forces the hero to cast an area-of-effect spell; there must be enough mana.
unit - the name of the combat unit
spell_id - the spell ID
x, y - coordinates

x, y = pos(unit) -- returns the coordinates of a unit by its name

Thank you, it seems I understand everything now, but where can I get the unit name for pos? unitNames() seems to return a string containing all the names, but how can I extract the desired one from this string?
Кампании для Heroes V 3.1 (Трилогия):

Пробуждение зла
Нашествие из Преисподней
Смена эпох

Скачать все кампании одним архивом: Яндекс.Диск Google.Диск

You can download the set of 3 Campaigns (English version) here


Одиночные сценарии Heroes V 3.1:


Незваные гости
Красный кристалл
Синий кристалл
Закат тьмы

Мультиплеерные карты для Heroes V 3.1:

Легендарная война
Сердце вулкана
Передел мира

Statistics

Welcome our newest member: leyu