Skip to content

Posts from Current questions and answers regarding the map editor.

5.0 (12 ratings)
In reply to Пошлость
User Avatar
#4474
Auto-translated
Exploit
Two enemy heroes with different faction flags were standing still, and one of them couldn't be attacked.
To make them stand still:
EnableHeroAI('scripted_hero_name', nil);
To make them stand still and unable to be attacked:
EnableHeroAI('scripted_hero_name', nil);
sleep(1);
SetObjectEnabled('scripted_hero_name', nil);
User Avatar
#4476
Auto-translated
A convenient way to set the camera coordinates for adventure map dialogues, preventing black screens (in case the map is open at the location where the scene is played):
1. Create a 0th dialogue. It will serve solely as a receiver for the coordinates.
2. Position the camera in the desired location.
3. Press the K key (or similar), and a dialogue will appear, allowing you to select the scene for which you want to set the camera. From my experience, it only works for the 0th dialogue, which is why the first step was performed. Click OK.
4. Copy the coordinates from the 0th dialogue to your dialogue.
Карты для Героев Меча и Магии 5
Одиночные: Завеса срывается, Посол, Последний рывок, Эхо Пустоты
Кампания: Империя Единорога

Существа NCF
Орден Порядка: 1
Нейтралы: 1 2 3 4
In reply to RedHeavenHero
User Avatar
#4477
Auto-translated
Has anyone tried to influence the AI's behavior by modifying the game files? Is it even possible to do this in any way other than through scripts on a specific map? At least, could you expand the set of spells that it uses in combat? After all, it fundamentally doesn't cast mass spells, racial abilities like Watch, or Summons.
Мои карты

Возрождённый v 1.5 (обновление от 25/09/2016) :smile24:

готовится продолжение.

Великая Пустыня ( 25%) - про Маркела
Тьма над Иролланом (0%) - про Николаса

Мои моды (скорректированы мод на чумных энтов и циклопов зомби)
User Avatar
#4478
Auto-translated
I tried to do it using a trigger. The hero entered the zone where the cutscene should start, but nothing happened.
function 11F()
StartAdvMapDialog(0);
StartAdvMapDialog(1);
end;
Trigger(REGION_ENTER_AND_STOP_TRIGGER, "11", "11F" );
User Avatar
#4479
Auto-translated
Just in case, it's worth checking with `print("something")` whether the function is being called by the trigger. Personally, I'm not sure if function names can start with a number.
User Avatar
#4480
Auto-translated
I figured out what the problem was in the trigger; I set the wrong zone. When I entered the zone with the cutscenes in the game, I got a black screen again, but the text was there. The hero had already loaded the area where the cutscene takes place. Here are the camera settings and how it should look. CLICK
I probably configured the cameras incorrectly, so I'm asking for help.
User Avatar
#4482
Auto-translated
That's how I write the hero's coordinates. His x: 4, y: 86, z: 0.
Okay, I'll try it now.
User Avatar
#4484
Auto-translated
Yes, that was the problem, thank you very much. I thought that 'z' had no effect.

Added 3 hours 0 minutes ago
Another question: which script should I use, or how can I set it up in the settings so that, after completing a task, for example, killing a monster, a cutscene is triggered?
User Avatar
#4486
Auto-translated
I initially wanted to implement this, but I'm not entirely sure how. I need a cutscene to play after a hero is killed.
User Avatar
#4487
Auto-translated
With heroes, it's the easiest – there's a trigger for hero loss; in it, we check the hero's name and do what's needed. With monsters, it's more complicated; there are several options.
User Avatar
#4488
Auto-translated
So, I guess I did a good job because I chose a hero. But what exactly is the trigger? :)