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 3.5 - WoG and Beyond > Thread: ERM help and discussion
Thread: ERM help and discussion This Popular Thread is 407 pages long: 1 50 100 ... 120 121 122 123 124 ... 150 200 250 300 350 400 407 · «PREV / NEXT»
JimV
JimV


Responsible
Supreme Hero
posted November 28, 2011 03:13 PM

Quote:
Though I meant something a bit more random, and not only spells.
A funny example would be "messengers" that appear for a second, "say" something at you, then disappear again.



For appearing and disappearing messengers or other graphical events, see my XFiles demo, mentioned previously on this thread.

I am slowly (as I learn Windows programming) working on an addition to XFiles, to play an external (compressed), timed .avi file, or other media file.  This could easily produce Salamandre's timed animation display.  An animation can also be done using TL0, as also illustrated in the current XFiles demo, but requires a bit too much scripting.

The basic idea of a timed animation is:  a) know in advance how long it will take to complete an animation; b) start the animation (e.g., place an object which has an animated DEF), and enable TL0 (flagged) at the same time; c) count elapsed time by the number of TL0 triggers which occur; d) stop the animation (delete the object), and disable the TL0 triggers when enough time has elapsed to complete the animation.  The TL0 can count in increments of either 1 second or about 20 milliseconds.  If there is a bit of stationary padding at the end of the animation, one second should be fine enough.  The 20 millisecond version is good for making one event occur instantaneously after another, but does not leave a lot of time for the computer to perform other things simultaneously.

An easier way to show an animation (once I have completed my DLL addition) is to make a media file of it (.avi, .wmv, etc.), and use a DLL to play it.  Era will load DLL's.  The media file contains information about itself, including its time length, so the the DLL routine can do all the timing logistics and all the user has to do is call the routine with the name of the media file.

As for coming up with random ideas for real-time events, personally I think it is better to use one's imagination to come up with ideas for interesting maps, such as a story which the map will follow, then work on implementing the map ideas with the tools from ERM and other sources.  Working on events first and then building a map around them is the wrong way around, for me - like building a house by slapping together interesting architectural details, rather than planning the house as a whole.

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


Famous Hero
posted November 28, 2011 06:43 PM


Quote:



Problem 2:  here is how ERM Help explains the !!HE:S command:
--------------------------------
S#1/$2;  Set/check/get secondary skill
  #1 - Skill number (see Format SS)
  $2 - Skill level (0=none, 1=basic, 2 =advanced, 3 =expert).
Comments:
You can even set all(!) secondary skills (28 altogether) but only the first eight will show on the hero screen.
----------------------------------



So I can even set the secondary skills of a hero before they  get them? Is this the correct trigger to use then? I noticed others using the CM2 for their heroes in their maps.  

ZVSE

!?CM2;
!!HE-1:N?v1; [Get current hero #]
!!HE15:S1/2;
!!HE15:S2/2;

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


Responsible
Supreme Hero
posted November 28, 2011 07:13 PM

Quote:


So I can even set the secondary skills of a hero before they  get them?


Yes, that is what ERM Help is saying.  The HE:S receiver gives you access to the internal data tables of the Heroes 3 program and lets you set them to whatever legal values you wish.  Once they are set, the program has no way to know whether the Hero gained the skill honestly through level promotion, or whether a hacker hex-edited the values, or whether you used the receiver to set them in an ERM script.

You could have read this yourself, directly from ERM Help, and also learned the difference between triggers and receivers, and what triggers are available under various conditions, and what receivers will work under those conditions, and what Heroes data those receivers will allow you to change.

Then, having learned those tools, and practiced with them a bit, ask yourself what you want a map to be about, then what sort of events or features would contribute to the map's intended purposes, then finally what triggers and receivers you could use to implement those features.

No one but you knows exactly what you want to do in your maps (well, I certainly don't), so you are the best person to plan your scripts - once you have read ERM Help.

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


Famous Hero
posted November 28, 2011 07:41 PM

Where can I read this ERM help info? Is there a specific file name?

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


Admirable
Omnipresent Hero
Wog refugee
posted November 28, 2011 08:06 PM

"C:\Program Files\3DO\Myheroesfolder\Help\Erm Help 2.81\index.htm"
____________
Era II mods and utilities

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


Responsible
Supreme Hero
posted November 28, 2011 09:14 PM

Quote:
Where can I read this ERM help info? Is there a specific file name?


As Salamandre's reply indicated, an "original" version of the ERM Help is installed in your Heroes 3 folder when you install either WoG 3.58f or Era.  The Era version, referenced by Salamandre, includes new commands added for WoG 3.59, which will work under Era (but not under WoG 3.58f).

I have made several small corrections and additions to the WoG 3.58f ERM Help, which can be downloaded here:

http://www.box.net/s/nv038pb3shsgnsuuum5a

Solitaire345 has done similar work on the Era version.  He gives download links in his second post on page 115 of this thread.

The ERM Help includes tutorials and sample scripts, as well as descriptions of all the receivers and triggers.  I learned 99% of what I know about scripting by reading it - which was why it was created by the WoG team.  It is the best Help manual I have ever seen.  (Of course, all the Help documents which I have read previously were on paper or were word-processor files, not HTML documents with links to tables and cross-references.  Still it amazes me that a group of amateur computer hackers took the trouble to put together such a valuable document.)

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


Admirable
Omnipresent Hero
Wog refugee
posted November 29, 2011 02:12 AM
Edited by Salamandre at 02:26, 29 Nov 2011.

I have a strange issue in DL:

It is said that H#1/#2 is parsed before showing. In my script I have 3 functions, each one changes all the items defs and hints. In the first function, then one which opens the first dialog, I set all the H#1/#2. In other functions I don't need to set them again (will crash if I do), and the hints are updated, hence my dilemma, how are they updated?

Example;

!?FU1;*coming from game and open dialog
!!VRz1:S^Lightning Bolt^;
!!DL#:H5/z1; set this hint on item 5

!?FU2; coming from FU1
!!VRz1:S^magic arrow^;
Item 5 shows magic arrow without any H5/z1 command.

All further functions will have items hints updated correctly, no idea how, as all H commands are in FU1. How the game knows z1 is for item 5?
____________
Era II mods and utilities

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


Responsible
Supreme Hero
posted November 29, 2011 02:59 AM
Edited by JimV at 03:00, 29 Nov 2011.

Quote:
I have a strange issue in DL:
...
How the game knows z1 is for item 5?


Let me quote an expert on this subject:

Quote:
posted by Salamandre (Honorable Legendary Hero) at 14:11, 26 Aug 2011

...

And if someone had the pleasure of getting endless crashes with DL, please tell me now to change hint txt for a def item inside a function.

!?FU300;
!!VRz1:S^Hint^;
!!DL10:H1/z1;

!?FU301;
!!VRz1:S^It will crash^;
!!DL10:H1/z1;

So far, setting hint txt in template will override any H$/# text. If text in template is left empty, the H$/# hint will display correctly but no way to change it later without instant crash.

Edit: solved second. You don't have to change hint show, but only z var stored text. The DL will read from first function.


I understood from the second quote that the DL:H command stores the z-variable number in association with the hint item, so that when the contents of that z-variable change, that hint item is also updated.

(It would be good to add this information to the Era ERM Help.  I must have had dozens of crashes due to disobeying rules which are not in the DL:H description.)

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


Admirable
Omnipresent Hero
Wog refugee
posted November 29, 2011 03:01 AM

Yes I know I posted this, just was confused why it does so...I am always scared that my work-around things will generate later errors if I don't get the the logic 100%.
____________
Era II mods and utilities

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


Famous Hero
posted November 29, 2011 10:15 AM



Quote:
"C:\Program Files\3DO\Myheroesfolder\Help\Erm Help 2.81\index.htm"


Cool thanks! I've been testing some easy scripts to get the hang of it, with some success, and failures, namely secondary skills.  Here's what I have:


!?HM0; (Identify Orrin as hero)
!!HE-1:S1/22/1; (use hero who triggered event, orrin, and in slot 1 give skill of offense)
!!HE-1:S2/21/1;(use hero who triggered event, orrin, and in slot 2 give skill of learning)


I was using the format:
S$1/$2/1

I used the !?HM trigger because it was on the top of the page for the HE receivers, but for some reason it's not working? Should I use another trigger?

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


Known Hero
posted November 29, 2011 10:54 AM

Quote:

I was using the format:
S$1/$2/1


As I remember this command controls mainly the arrangement of skills. When you execute !!HE-1:S1/22/1; you force the game to show this skill in the first slot, but not actually give it to the hero. Moreover, this slot is already occupied with one of the default skills. All this can cause fatal errors.

If you don't care which place in the table a new skill will take you should use !!HE-1:Sx/y; syntax. If you do care you still have to use it in order to give the skill. After that you can find out its position and swap it with any other skill making it first or second in the table if you need.

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


Admirable
Omnipresent Hero
Wog refugee
posted November 29, 2011 03:10 PM

In mapsforheroes.com there is a map you can get when word searching for "Luna".

Inside you have a script which sets pretty well the leveling, hope is what you want:

ZVSE

!#VRv313:S0;               *** set v313 to 0   . Counter
!#VRv314:S2;               *** set v314 to 2

!?HL136;                  *** TRIGGER when Luna gains a level

!!VRv315:S0 T3;      *** Set v315 to random # 0 to 3 atk/def/pwr/kwn

!!VRv314&v313=1:S5;     *** 2 Navigation
!!VRv314&v313=2:S9;     *** 3 Luck
!!VRv314&v313=4:S13;   *** 4 Estates
!!VRv314&v313=5:S20;   *** 5 Artillery
!!VRv314&v313=6:S23;   *** 6 Armorer
!!VRv314&v313=7:S25;   *** 7 Sorcery
!!VRv314&v313=8:S26;   *** 8 Resistence
!!VRv314&v313=9:S27;   *** 9 1st Aid

!!HL:Sv315/-2/v314;  *** Skill selection Logistic 1st time
!!VRv313:Sd1;          *** add 1 to v313
____________
Era II mods and utilities

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


Adventuring Hero
Outcast Fire Witch
posted November 29, 2011 04:12 PM

I want to change some heroes's unique abitities.
As we know, with script 39, Adrienne can cast curse on all enemy stacks at start of combat. I want to change it. Can I make a hero with ability that cast benefit spell on all friendly, or bad spell on enemies?
____________
My HoMM3 Maps
Sorry for my bad English.

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


Famous Hero
posted November 29, 2011 05:55 PM

Neither the Luna script, or the !!HE-1:sx/y; seem to work, and I tried them on new maps that don't have any other ERM codes for overlap.

 The leveling I can use with the !?HL trigger and then use !!HL receiver to display the next set of skills when gaining a level.  That I figured out last night (my first step! lol).  

What I would like to have is the skills already in place, including the hidden skills.  Because there's a problem when you use the HL receiver and all 8 skill slots are full.  When you gain a level it shows basic x and basic y, and if you jump 10 levels for example, you won't acquire the skills and your selection will still be basic x/y.  What I'm doing right now, is having the hero with the 8 skills open a pandora's box of experience, and hope that the 2 hidden skills I'd like (resistance and intelligence) appear.  But then from day 1 I have a hero starting at level 16 lol.  The rest of the hidden skills I can get from battle academy (script 16), but for some reason, I can never find those 2 in the academy I'd like.  

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


Admirable
Omnipresent Hero
Wog refugee
posted November 29, 2011 06:06 PM

I have no idea what you want, but if you want all skills in place on first day, without any experience bonus:

!?PI;
!!DO15611/0/27/1:P;

!?FU15611;
!!HE0:Sx16/1;

Orrin will have all skills on first day. Of course, you need script "hidden skills" to be activated, otherwise you can't view them.
____________
Era II mods and utilities

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


Famous Hero
posted November 29, 2011 06:46 PM

Quote:
I have no idea what you want, but if you want all skills in place on first day, without any experience bonus:

!?PI;
!!DO15611/0/27/1:P;

!?FU15611;
!!HE0:Sx16/1;

Orrin will have all skills on first day. Of course, you need script "hidden skills" to be activated, otherwise you can't view them.



I would like these skills to appear in the 8 slots,

Fire Magic
Sorcery
Wisdom
Learning
Air Magic
Earth Magic
Pathfinding
Logistics

and these two to appear in the hidden skills

intelligence
resistance

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


Famous Hero
posted November 29, 2011 06:52 PM

that actually worked well, and they all did appear in the hidden skill set. I just need to find a way to narrow the skills attached, and if i can put them in order..

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


Admirable
Omnipresent Hero
Wog refugee
posted November 29, 2011 07:03 PM

What's the problem? The skills will be offered in the order you put them.

If HE-1:S0/1; gives pathfinding, then use same command for all skills, placing the ones you want in hidden in last two positions.
____________
Era II mods and utilities

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


Known Hero
posted November 29, 2011 07:07 PM
Edited by Aleee at 19:11, 29 Nov 2011.

Quote:
that actually worked well, and they all did appear in the hidden skill set. I just need to find a way to narrow the skills attached, and if i can put them in order..


!?PI;
!!DO15611/0/27/1:P;
!!HE0:S[1]/1;
!!HE0:S[2]/1;
...
!!HE0:S[n]/1;

!?FU15611;
!!HE0:Sx16/0;


where [1], [2],..., [n] - are skills' IDs from the ERM-help. In order to make the two skills hidden you just need to place them at the end: [n-1] and [n].

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


Famous Hero
posted November 30, 2011 05:24 AM

Yay! I got it! Thank you all! Now time to play for hours upon hours!

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread » This Popular Thread is 407 pages long: 1 50 100 ... 120 121 122 123 124 ... 150 200 250 300 350 400 407 · «PREV / NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0878 seconds