Heroes of Might and Magic Community
visiting hero! Register | Today's Posts | Games | Search! | FAQ/Rules | AvatarList | MemberList | Profile


Age of Heroes Headlines:  
5 Oct 2016: Heroes VII development comes to an end.. - read more
6 Aug 2016: Troubled Heroes VII Expansion Release - read more
26 Apr 2016: Heroes VII XPack - Trial by Fire - Coming out in June! - read more
17 Apr 2016: Global Alternative Creatures MOD for H7 after 1.8 Patch! - read more
7 Mar 2016: Romero launches a Piano Sonata Album Kickstarter! - read more
19 Feb 2016: Heroes 5.5 RC6, Heroes VII patch 1.7 are out! - read more
13 Jan 2016: Horn of the Abyss 1.4 Available for Download! - read more
17 Dec 2015: Heroes 5.5 update, 1.6 out for H7 - read more
23 Nov 2015: H7 1.4 & 1.5 patches Released - read more
31 Oct 2015: First H7 patches are out, End of DoC development - read more
5 Oct 2016: Heroes VII development comes to an end.. - read more
[X] Remove Ads
LOGIN:     Username:     Password:         [ Register ]
HOMM1: info forum | HOMM2: info forum | HOMM3: info mods forum | HOMM4: info CTG forum | HOMM5: info mods forum | MMH6: wiki forum | MMH7: wiki forum
Heroes Community > Heroes 4 - Lands of Axeoth > Thread: A way for map-custom H4 hero specialties
Thread: A way for map-custom H4 hero specialties
NimoStar
NimoStar


Responsible
Legendary Hero
Modding the Unmoddable
posted October 04, 2018 03:32 PM
Edited by NimoStar at 19:17, 04 Oct 2018.

A way for map-custom H4 hero specialties

I can't program hero specialties into the program code.

But I was thinking how could one have hero specialties in H4. I though of some ways and discarded them - artifact, special classes, etc.

But there is one way which is pretty close:

Create the hero in the map, edit the biography with an specialty, and add it to Events.

Example One
For example, a pirate hero could have "Specialty: Enters the battle with three Ballistae. Ballistae are removed at end of combat.", and at the end of the battle, the ballistae would be removed.

Standard Events:
Encountered: give army +3 ballistae
Defeated: remove 3 ballistae from army
Victorious: remove 3 ballistae from army

Example Two
Specialty: Hero regenerates two extra spell points per day.

Timed Event, every day: Give 2 extra spell points to this hero.

Example Three
Specialty: Demoralizing. -2 morale to opposing army.

Standard event - Encountered: -2 morale to opposing army.

Example Four
Specialty: Logistics.

Timed event, every day: +5 movement points to this army.

Example Five
Specialty: Fireball. Can cast fireball at half the normal cost.

Standard events:
Encountered - Give Scroll of Fireball
Defeated - Take Scroll of Fireball
Victorious - Take Scroll of Fireball

Example Six
Specialty: Healing. Can use one free Potion of Healing per combat.

Standard events:
Encountered - Give Potion of Healing.
Defeated - Take Potion of Healing.
Victorious - Take Potion of Healing.

Example Seven
Specialty: Elemental summoning. Summon double elementals as long as you have an open ring slot.

Standard events:
Encountered - Give Ring of Elementals.
Defeated - Take Ring of Elementals.
Victorious - Take Ring of Elementals.

(This is possible with any artifact. Testing is needed for combat artifact-based skills which is not dependant on Potions or Vials.)

Example Eight
Not everything artifact related has to be combat-only-specific. For example:
Specialty: Hydra Health. Hero creates a Potion of Hydra Health every day.

Timed events - Every day: Give potion of hydra health.
As there is no way to abuse these, it would be fine.

Example Nine
Not every specialty has to be daily.
Specialty: Demon Fire. Create a Vial of Demon Fire every 6 days.

Timed events - Day 6 - Every 6 days: Give Vial of Demon Fire.

Example Ten
A more complicated way to go about specialties is to link them to hero level tiers...

Specialty: Dead Assists. According to hero levels, a stack of unliving joins each fight. Levels 1-5: 15 skeletons. Levels 6-10: 8 gargoyles. Levels 11-15: 5 mummies. Levels 12-20: 4 vampires. Levels 21 and up: 3 ghost dragons.

Encountered, conditional action: If level 5 or lower, add 15 skeletons. Otherwise if level 10 or lower add 8 gargoyles. Otherwise if level 15 or lower add 5 mummies... etc.
Same when defeated or victorious with removing the creatures (unless you actually want them to stack).

***

It would be interesting to have campaigns based in specialties (unusually strong ones; they also could get stronger in each progressing scenario, and even have a choice with Conditional Actions -"Do you wish to specialize in Movement Points or Spell Points?"-) and how to use them, like there was based on assembling artifact combinations.

***

Good points (?):
- Events will keep going even if hero dies, due to tombstone mechanic.
- Events will function if put in heroes in prisons.
- There can be spell specializations like creating a scroll at the start of combat and deleting it at the end of it. This will allow to cast the spell at half the normal cost, but not be a transferrable artifact. Scroll-based specializations may be buggy due to the game recognizing all scrolls as the same artifact type. However, other based on wands or staffs will be fine, as long as the hero has the free slots to use them.

Limitations:
- If hero is jailed in an enemy town-prison, events will be probably deleted.
- It cannot be applied to heroes in tavern.
- There cannot be "normal" specializations in creatures like raising their stats. There can be, however, specialization in ways of "if this creature is in army, do X" and "Create X at the start of combat

- Note: In one of my tests, the hero kept the ability when dead as a tombstone, but lost it after resurrecting. This probably was just an error on my part because the event was in the army, not inside the hero.

Advanced scripters (ones that don't use the interface) may create dependent variables, such as "Elf Support Specialty: When the combat starts, create one elf for each level of the hero. Remove them at end of combat." - I believe this is in the capabilities of the scripting engine; if not, it is possible, even from the editor's GUI, to trigger each level-instance individually with conditionals and number comparisons, although to do so for each level would be time-consuming without automation.
____________
Never changing = never improving

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Honorable
Famous Hero
posted October 04, 2018 05:31 PM
Edited by iliveinabox05 at 17:32, 04 Oct 2018.

Yeah, scripting can do quite a bit in this game.

I have scripted many such special abilities in my half completed Heroes Chronicles campaign.

I implemented several special abilities based on a points system (add points into the abilities that you want to). Some are simple, like + a static amount of attack / defense / mana and then an additional percentage based on level (when entering combat). For example: +10 attack and 2% per hero level. The flat amount and % increase with the level of the ability.

There is also additional movement that can be an ability (as you mentioned), or summoning a certain type of creature each turn (amount and creature type based on level of the ability). Looks like you also mentioned this as well.

I had also planned an ability kind of like an advanced scouting where certain areas of interest could be revealed based on the level of the ability. The higher the level of the ability, the more area that is revealed.

Another one I was going to work on was a sort of "magic barrage" (which could also be an artillery barrage) where on encounter, the heroes skill would trigger and reduce the enemy's numbers by a percentage based on the skill.

I also had planned on adding a "limit burst" type of skill based on my own combination artifact which could trigger before battles. It would basically ask if you wanted to trigger the skill and then add some major boosts for the battle. You could have different levels of this ability, so you could choose not to invoke it in favor or powering it up further before using it. Levels might not be the best way to describe it, maybe more like phase 1, 2, 3, where powering up to phase 3 would grant you higher boosts in battle than if you were to trigger the skill while only powered up to phase 2.

As you said, most of these abilities would have to be applied to heroes that are manually placed onto a map vs hired from the tavern.

It would be fun to get some ability ideas from others as well, since there are so many different things that could be scripted into this game. It could also be a challenge to come up with a way to script the more advanced ideas

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Responsible
Supreme Hero
posted October 05, 2018 11:49 PM

Apart from iLiVe's examples I know Duzeom also used customized skills in his Megom Chronicles campaigns. Also look at Psychobabbles top 10 on CH, there is also listed a map with customized hero skills.

Be aware of the difference between Army and Hero scripts. If you transfer a hero or a creature with an Army script you also transfer the script. This would ruin the ide of special hero skills if you would accidently/deliberately transfer it from one hero to another.
Also I do recall scripts don't run while being imprisoned.
If they run when dead, that is likely the army and not the hero script as you also asume.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Responsible
Legendary Hero
Modding the Unmoddable
posted October 06, 2018 04:37 PM

Quote:
Psychobabbles top 10 on CH


Link? :V

Yeah, I know army scripts wont work the same, it was a distraction using them in my game by accident.

I made this post not implying not anyone had tried it before. But neither the opposite, since, you know, last time I asked for multiplayer campaigns and turns out nobody had made one :V
____________
Never changing = never improving

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Responsible
Supreme Hero
posted October 06, 2018 06:30 PM

psychobabbles top 10 it is linked on the main site of CH. It's the map Draconic.
I listed the examples not to say your idea had been done before, but to refer to other examples in case you wanted more inspiration. Of course you have to dig into the maps yourself.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Responsible
Legendary Hero
Modding the Unmoddable
posted October 16, 2019 10:53 AM

has anyone ever tested if hero events like these are retained after the hero is in prison?

Also, now that I am looking into making a new campaign, it was nice to remember this...
____________
Never changing = never improving

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Responsible
Supreme Hero
posted October 16, 2019 08:16 PM

NimoStar said:
has anyone ever tested if hero events like these are retained after the hero is in prison?

Also, now that I am looking into making a new campaign, it was nice to remember this...


Tbh, I don't remember. I do believe there is some issue if the hero dies or is captured, that scripts are then lost. It would be easy to test, though..
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Responsible
Legendary Hero
Modding the Unmoddable
posted October 17, 2019 09:32 AM

Ok, I tested it and found some oddities:

- If I put "give 1 sorceress" as a script on the hero at the "encountered" time, and "take one sorceress" at the end, and both hero and sorceress are defeated... a sorceress appears at the end of battle alone.

This seems like an scripting error from the game as "0-1= -1" which it probably interprets as positive one because you can't have a negative number of creatures in an army.

For some reason, this doesn't happen if the hero wins.
The alternative explanation is that the hero "dies"/is imprisoned before it loses the battle, so its "defeated" script never triggers.
This doesn't seem exactly true because if it was the case there woudn't be a sorceress after everyone was already dead.

Furthermore, against neutral creatures I even had TWO sorceress appear when the hero was defeated: One immediately, and a second one via the event "inexplicably" triggering again befor that one was engaged by the neutral dragons.

So, this particular script is buggy and reccomended to use only when the condition "if you lose the hero you lose the campaign" is set.

If you are given a creature at the start of battle and you don't have enpugh free slots for it, you will be given the opportunity to move out other creatures or rearrange your army. The "discarded" creature (or hero) becomes its own army.

Also unrelated but I noticed the Preserve citadel doesn't have any shooting aisle, making it essentially similar to the castle...

- Daily triggers DON'T work on heroes in garrisons.
I gave an "increase level" daily trigger to heroes in a garrison and they would never advance.

Take them out? They advance.
Put them back in? Stop advancing.

So heroes in garrisons have their triggers (at least timed ones) "freezed" for the duration of their defense.
Somewhat unfortunate since garrisons with "can't take out creatures" are the only effective way to have a hero "Pinned" in them as a defender for map makers.

ALso, I had a crash after a siege with these heroes but have no idea if it is related. I coudn't reproduce the crash in a subsequent game (but in this case losing the siege woudn't imply losing the game, also it was on autoplay)

Garrisoned heroes in towns are NOT subject to this dynamic, their daily triggers still function.

Even more strangely, TOMBSTONES will keep triggering their daily ability.
If you give it a daily skeleton, for example, the skeleton wil happily appear carrying the tombstones even if their hero is dead on the middle of nowhere.

- In regards to heroes in prison:
Timed events don't work for them , unsurprisingly, as in garrisons,
BUT I have found that, upon leaving prison, they retain all the timed events they had.


So, good and bad news.

The good news is that events on heroes are never deleted due to game states.

The bad news is that they don't always work as intended.
____________
Never changing = never improving

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Responsible
Supreme Hero
posted October 18, 2019 12:02 AM

Some of those ring a bell. Clearly as you write these must've been never thoroughly tested and ironed out. Some of those 'unfortunate' script effect can however be used for special actions if used correctly, but you gotta be able to control them, like a creature recovering the body of your hero..
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Responsible
Legendary Hero
Modding the Unmoddable
posted October 18, 2019 12:40 AM
Edited by NimoStar at 00:40, 18 Oct 2019.

Well H4 was a rushed game and it shows even in this, in addition to AI (I have put relic arrtifacts without guards right next to the AI's town door and they *never* collect them)

But there are some ways for these to be potentially useful in alternate ways, yes. Sometimes at the cost of their normal usefullness...

It took a few hours to test all of this and I had to make a special map to do it and rule out any other variables.
____________
Never changing = never improving

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread »
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0444 seconds