Skip to content

Current questions and answers regarding the map editor.

User Avatar
#3274
Auto-translated
This is the first one. ``` function capture_prt() Trigger(5, "prt", nil) RazeBuilding("cityname") end Trigger(5, "prt", "capture_prt") ```

Added 14 minutes later
The second one. ``` points={{x1, y1, f1}, {x2, y2, f2}} function tch_portal(hero, portal) if portal == "name_of_first_portal" then SetObjectPosition(hero, points[2][1], points[2][2], points[2][3]) elseif portal == "name_of_second_portal" and hero ~= "Remisa" then SetObjectPosition(hero, points[1][1], points[1][2], points[1][3]) end end Trigger(4, "name_of_first_portal", "tch_portal") Trigger(4, "name_of_second_portal", "tch_portal") SetObjectEnabled("name_of_first_portal", nil) SetObjectEnabled("name_of_second_portal", nil) ``` x1, x2, y1, y2, f1, f2 are the coordinates of the point near the first and second portals, where the hero will be teleported.
Карты для Героев Меча и Магии 5
Одиночные: Завеса срывается, Посол, Последний рывок, Эхо Пустоты
Кампания: Империя Единорога

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