That's the problem; they don't reach the trigger. I'm starting to think that the region acts as an obstacle for them... although there are no region-based restrictions at all (the larger I make the region, the further away from the destination the heroes stop).
Posts from Scripts
P.S. too bad, I thought the MoveHeroRealTime command allowed you to cover absolutely any distance in one go, but it turns out it only covers the distance for which there are enough movepoints (and you can't make it higher than the maximum movepoints with the command, if you believe the manual. But in the developers' campaign scripts, I found adding a certain number of points to the hero before executing the MoveHeroRealTime command, why, I wonder? if again, according to the manual: "The hero will jump to the specified point. Regardless of whose turn it is and whether or not he has movepoints"! There is an inconsistency...) in general, it's sad :)
Multiplayer: Господство, Извечное противостояние, Война за Магию, Торговая империя, Анатомия войны, Эксперимент
SingleScenario: Последний Рубеж, Трон, Элиралис, Вернуться домой!, Лабиринты разума
Campaign: Колонизация
The heroes simply didn't have enough movepoints, and the first hero had logistics + a racial skill...
P.S. It's a pity, I thought that the MoveHeroRealTime command allows you to cover absolutely any distance at once, but it turns out it only covers the distance for which there are enough movepoints. (and you can't make it higher than the maximum movepoints with the command, if you believe the manual. But in the campaign scripts, I found that the developers added a certain number of points to the hero before executing the MoveHeroRealTime command, why, I wonder? if again, according to the manual: "The hero will jump to the specified point, regardless of whose turn it is and whether he has movepoints or not"! There is an inconsistency...) in general, it's sad :)
Or, more simply, teleport closer to the desired point, and then let them run.
By the way, about the manual with errors - there are other ones too :)
Since the points are running out, implement the check within the loop, and, for example, when they are less than half, add them to the appropriate hero. ;)
Here's an idea ;) thank you!
It won't look good to teleport them to the middle of the map) They run from the Dungeon (from the point where the player can't see them) through the visible part (large) of the map... so it can only be done this way :)
Added 8 minutes later
I tried, but it doesn't work. I put a sensor that shows that the points are added every second by 2500, but it still runs its distance and stops earlier than it should... I don't understand why the developers didn't come up with such a functional command to move a hero using normal movement over long distances in real time...
Multiplayer: Господство, Извечное противостояние, Война за Магию, Торговая империя, Анатомия войны, Эксперимент
SingleScenario: Последний Рубеж, Трон, Элиралис, Вернуться домой!, Лабиринты разума
Campaign: Колонизация
Here's an idea ;) thanks!
It won't look good to teleport them to the middle of the map). They run from the Dungeon (from a point where the player can't see them) across the visible part (the large part) of the map... so it has to be this way :)
Added 8 minutes later
I tried it, but it doesn't work. I set up a sensor that shows that points are added every second, 2500 at a time, but it still runs its distance and stops earlier than it should... I don't understand why the developers didn't come up with a functional command to move a hero over long distances in real time using normal movement...
I'm done giving advice - it won't get you very far :smile17:
Here's an idea ;) thanks!
It won't look good to teleport them to the middle of the map. They run away from the Dungeon (from the point where the player can't see them) through the visible part (the large part) of the map... so it can only be done this way :)
Added 8 minutes later
I tried, but it doesn't work. I put a sensor that shows that points are added every second by 2500, but it still runs its distance and stops earlier than it should... I don't understand, did the developers really not come up with such a functional command to move a hero by means of normal movement over long distances in real time...
There is such a function - I don't have the source code at hand right now, but you can check the script in the prologue of the Orcs campaign in Lords;
There is also a bug with the hero stopping, related to him passing through the garrison gate - there you can also pull off a "trick," related to creating a point region in the gate.
Multiplayer: Господство, Извечное противостояние, Война за Магию, Торговая империя, Анатомия войны, Эксперимент
SingleScenario: Последний Рубеж, Трон, Элиралис, Вернуться домой!, Лабиринты разума
Campaign: Колонизация
antonag07, it's nonsense...I made something similar, and the MoveHeroRealTime command doesn't work as it should... I did it using the good old MoveHero instead.
function MoveHeroRealTimeAndReachPoint( heroName, x, y, floor )
moveCost = CalcHeroMoveCost( heroName, x, y, GROUND );
ChangeHeroStat( heroName, STAT_MOVE_POINTS, moveCost );
sleep(1);
MoveHeroRealTime( heroName, x, y, GROUND );
end;
Why say it's nonsense right away?! It works there...
That's the thing, they don't even reach the trigger; I'm starting to think that the region acts as an obstacle for them... although there are absolutely no region-based restrictions (the larger I make the region, the further away from the destination the heroes stop :))
I don't know if it's related, but I placed a Mask in one location on the map to prevent anyone from entering. However, as soon as an object (art) is teleported there using scripts, the mask stops working.
That can't be. I think you're teleporting it to the edge of the mask. So, when a hero approaches the mask, they end up on a tile adjacent to the artifact, allowing them to interact with it. If there was another tile of the mask separating them, they wouldn't be able to reach it.
That can’t be. I think you’re teleporting him to the edge of the mask. So, when a hero approaches the mask, he ends up on a cell adjacent to the artifact, so he can interact with it. If there was another cell of the mask separating them, he wouldn’t be able to approach.
Why immediately call it nonsense?! It works...
it doesn't work (if the hero doesn't have enough maximum movement points, he won't go anywhere; I checked it many times). The distance is simply shorter (they use a smaller distance).
I found a clever way to make the hero run across the entire map using transit regions. I determined the exact distance the hero can travel. I placed regions with additional movement points and a send command at the end points (it all works :). Otherwise, I don't think it's possible to force the hero to travel such distances).
Multiplayer: Господство, Извечное противостояние, Война за Магию, Торговая империя, Анатомия войны, Эксперимент
SingleScenario: Последний Рубеж, Трон, Элиралис, Вернуться домой!, Лабиринты разума
Campaign: Колонизация
it doesn't work (if the hero doesn't have enough maximum movement points, they won't go anywhere; I've checked this many times). The distance is simply too short (they use it).
I found a clever way to make the hero run across the entire map using transit regions. I determined the exact distance the hero can travel. I placed regions with additional movement points and a send command at the end points (it all works :). Otherwise, I understand that you can't force the hero to travel such distances.
Цикл "Закадычные враги": "Особенное гостеприимство, "Супероружие", "Меж молотом и наковальней"
"Падение Шантири"
Кампания для "Кодекса Войны"
"Выбор Сагиттеля"