Skip to content

Posts from Current questions and answers regarding the map editor.

5.0 (12 ratings)
User Avatar
#4660
Auto-translated
Godric's Hollow, no, with the approach used in the first map, it takes an unacceptably long time.
РПГ-сценарий для HoMM5: Путь героя
ЧаВо по созданию карт для HoMM5: ЧаВо
In reply to Jack_of_shadows
#4661
Auto-translated
Okay, so you’ll just be the guru on this forum when it comes to the map editor.
#4663
Auto-translated
Good day. I'm trying to create a quest where the reward is a specific skill. However, after completing the quest, the skill isn't granted. Other rewards (stats, experience, army, artifact) work fine. It doesn't seem like it should be complicated: you choose the corresponding reward type (Award_Skill), and then select the skill (SkillID).
In reply to AstralLein
#4665
Auto-translated
AstralLein
In the seer's hut? It's there, it's just that the reward isn't displayed in this case due to a developer oversight, but it is awarded.
Yes, in the hut, but the specified skills are not awarded, and they definitely don't appear on the characters.
In reply to am-wrag
#4666
Auto-translated
I'm having a strange problem. I wrote a script:
function play_anims()
if GetCurrentPlayer() ~= 1 then return end
Trigger(REGION_ENTER_AND_STOP_TRIGGER, "udar1", nil)
PlayObjectAnimation("limon", "attack00", IDLE)
sleep(5)
PlayObjectAnimation("limon2", "attack00", IDLE)
sleep(5)
PlayObjectAnimation("limon3", "attack00", IDLE)
sleep(5)
PlayObjectAnimation("limon4", "attack00", IDLE)
end

Trigger(REGION_ENTER_AND_STOP_TRIGGER, 'udar1', 'play_anims')

Everything works, all the creatures are fighting on the map. But the creature named limon3 is standing with its arms spread. Does anyone have any ideas?

Added 15 minutes later
And another script to make the creatures on the map fight from the very beginning, but if you enter the region, a battle starts with one creature from the pair that is fighting. And as soon as the battle is won, the creature immediately wants to join. Does anyone know how to implement this?
User Avatar
#4667
Auto-translated
The problem is that the creature named limon3 stands with its arms outstretched.
Not all creatures have animations defined in their properties (Shared->AnimSet). The simplest solution is to replace the problematic monster with another one.
And also, a script so that creatures on the map start fighting from the beginning, but when you enter a region, a battle starts with one creature from the pair that is fighting. And as soon as the battle is won, the creature immediately wants to join. Does anyone know how to implement this?
What specifically is causing difficulties? You write animations in the script, place a region trigger, in it, use StartCombat(), and in the battle callback (one of the parameters of the StartCombat function), check if the battle was won and force the hero to click on the monster that is pre-configured to join.
РПГ-сценарий для HoMM5: Путь героя
ЧаВо по созданию карт для HoMM5: ЧаВо
#4669
Auto-translated
Where do you get the spell codes for the map? I would be grateful if you could share a file containing all the spells.
User Avatar
#4670
Auto-translated
Godric's Hollow, I described this in the FAQ. There is a folder with spells in the game's resources; it contains all or almost all the spells. You just need to know their English names.

UPD: or are you referring to the spell IDs? Then the file is HOMM5_A2_IDs_for_Scripts.pdf.
РПГ-сценарий для HoMM5: Путь героя
ЧаВо по созданию карт для HoMM5: ЧаВо
In reply to Jack_of_shadows
#4671
Auto-translated
Am I correct in understanding that there should be only one trigger for the entire script on the map? That is, if I first assign a REGION_ENTER_AND_STOP_TRIGGER, and then write it again, that trigger will be reset.

Added 8 minutes ago
If I understand correctly, how can I create 2 functions with the REGION_ENTER_AND_STOP_TRIGGER trigger? Both functions with animations, but one animation is a spell, and the other is attack00.

Added 30 minutes ago
And no, I'm not talking about their IDs; I've found those. I'm talking about the spells themselves, for example, /Effects/_(Effect)/Spells/Armageddon.xdb#xpointer(/Effect).

Added 47 seconds ago
Specifically, where can I find such spells, in which folder?
User Avatar
#4672
Auto-translated
Hello, I have a question: How can I make it so that after capturing a garrison (let's give it a scripted name, Garnizon01), a dialogue is played (let's take, for example, the very first one, DialogScenes/A2C0/M1/S1/DialogScene)?
Thank you in advance.
User Avatar
#4673
Auto-translated
Am I correct in understanding that there should be only one trigger for the entire script on the map?
For one region (in your example) – yes. And nothing will be reset for different regions.
That's exactly where I can find such spells, in which folder?
You can find them in the folder you mentioned... /Effects/_(Effect)/Spells
Good afternoon, I have a question: How can I make it so that after capturing a garrison (let's give it a scripted name Garnizon01), a dialogue is played (let's take, for example, the very first one DialogScenes/A2C0/M1/S1/DialogScene)
Thank you in advance.
Trigger. There used to be one trigger for changing the ownership of objects, but I'm not sure... Otherwise, use OBJECT_TOUCH_TRIGGER.
 

К А
Стикеры GBF в Telegram
In reply to Ment
#4674
Auto-translated
Do you happen to know how to remove corpses from the map? I cast a spell, killed the creatures, but the remains, like a vampire sword, are still there. How do I remove these remains from the map?
In reply to Годрикова впадина
User Avatar
#4675
Auto-translated
Godric's Hollow
Do you happen to know how to remove corpses? I mean, I cast a spell on the map, killed the creatures, but the remains are still there, like a vampire sword, etc. How do I remove these remains from the map?
Delete Object (in your case, the vampire with the death animation)
You need to perform the deletion after the death animation; it's obvious why.
In reply to DarkLordax
#4676
Auto-translated
Well, that makes sense, but how do I remove them? Actually, I want to time it so that I remove the dead units when the Armageddon spell flashes – it will be unnoticeable. But the question is, how exactly do I remove them from the map? Since the functions run sequentially, I don't think there will be any problems with that. I just need a script, because I don't know how to write one.