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 ... 9 10 11 12 13 ... 50 100 150 200 250 300 350 400 407 · «PREV / NEXT»
fnord
fnord


Promising
Famous Hero
posted June 25, 2005 09:30 AM

Quote:

But what if i have some hierophants and some brutes ,and some soul eaters...will they all now would cast Prayer?


With that example it would change it for all Commander types. If you want it to be specific, you would need to use the BM:T command to check the type of creature in the stack and then apply it to the type you want (or different spells to different types).


____________

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


Responsible
Supreme Hero
Forgotten but not Forsaken
posted June 25, 2005 12:31 PM

Quote:
Quote:

But what if i have some hierophants and some brutes ,and some soul eaters...will they all now would cast Prayer?


With that example it would change it for all Commander types. If you want it to be specific, you would need to use the BM:T command to check the type of creature in the stack and then apply it to the type you want (or different spells to different types).




ok..THANKS....

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


Responsible
Supreme Hero
Forgotten but not Forsaken
posted June 25, 2005 12:59 PM

Quote:
Quote:
Quote:

But what if i have some hierophants and some brutes ,and some soul eaters...will they all now would cast Prayer?


With that example it would change it for all Commander types. If you want it to be specific, you would need to use the BM:T command to check the type of creature in the stack and then apply it to the type you want (or different spells to different types).




sorry for disturbing,but i don't know how to do that...could you make a script which would make paladins to cast bless or prayer...?

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


Admirable
Legendary Hero
ghost of the past
posted July 30, 2005 11:24 PM

I found some at the old site:

http://www.h3nl.narod.ru/erm_r.html

(Actually, I just wanted to put this great thread back on top of page one )
____________

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


Admirable
Legendary Hero
ghost of the past
posted July 31, 2005 03:36 PM

ERM vs H4 scripting

While I was working on my first Heroes 4 scenario, I couldn't help comparing it to something I was more familiar with: "In the Wake of Gods" (WoG) and its ERM scripts.

(If you haven't heard about it yet, WoG is a fan-made mod, developed by Slava Salnikov and his team)

Both Heroes 4 and WoG introduced powerful tools for mapmakers.

What is the difference?

First, here is a comment by Slava (from the old site):

Quote:
Question:

What sort of new things will fans of Heroes III see in WoG? As far as differences
from previous add-ons, will there be global changes?

Slava's Answer:

Basically, the most important change is an opportunity for the mapmaker to have more
control over the course of the game with the help of the Event Related Model (ERM) scripting language. This is something that has never been done in Heroes before.
In fact, I was quite suprised when I read the interview by Timothy Pulver (he is also a member of our team) with the main programmer for NWC, Gus Smedstad, to learn that in Heroes IV there will be a practically identical scripting mechanism. At that time, our site and the first ERM versions had existed for some months.
I do not wish to come to any definite conclusions, but I do wonder if the delayed release of Heroes IV could be a consequence of developers having decided to add scripts in the project when initially nothing along these lines had been seriously considered.
So now players can feel the charm of interactivity of the maps with scripts without having to wait for Heroes IV.


Meanwhile, Heroes 4 came and went, but it's interesting to compare those two...

If you are not familiar with WoG and ERM, here's a sample:

ZVSE
!?OB3/33/0;
!!HE-1:A2/40/0/?v1000;
!!IF&v1000=1:M^%Z400, you seem to have the armor? Perhaps you are the one I have been waiting for.^;

Translated into English, this reads:

This is an ERM script.
If any hero visits the object (quest hut) at 3/33/0,
check if he has the artifact and set the flag.
If the flag is "true", display the message: (name of the hero), you seem to have the armor? Perhaps you are the one I have been waiting for.

What are all those numbers?!

3/33/0 are the coordinates of the object (0 means it's on the surface)
-1 means "any"
2  means "check"
40 is the dragon scale armor
v1000 - the flag used here
%Z400 - stores the name of the visiting hero

etc

Some of them you can find in the WoG help files, others you choose and set.

Other symbols stand for ERM triggers (!?) and receivers (!!) :

OB - object
HE - hero
M - text message

etc

You can learn how to use them reading the help files.

ERM is not a complicated language; I studied literature at uni, but ERM reminded me of Basic I used to learn back in primary school... so it took me several hours to write my first script. I still write rather simple scripts, mind you, but they add a number of unique features to my maps... and it's fun. You can change ANYTHING in the game, and I mean ANYTHING.

This is not possible with the great, but limited H4 editor.

On the other hand, Heroes 4 scripting is simpler: all the options are there for you to choose.

Let's take another look at the example and translate it into a Heroes 4 script:

(the player visits the quest hut)

TRIGGERED SCRIPT:

SEQUENCE:

CONDITIONAL ACTION:

IF this army HAS ARTIFACT dragon scale armor,

DISPLAY MESSAGE: You seem to have the artifact equipped?
Perhaps you are the one I have been waiting for.

REMOVE SCRIPT

It's easy, isn't it? However, I said those are simple scripts, presented for comparison only.

I understand the true power of both ERM and H4 editor lies in Flags and variables, but I didn't have the time and skills to further study those.

Perhaps fellow H4/WoG mapmakers would like to compare notes on this topic...?
____________

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


Admirable
Legendary Hero
ghost of the past
posted August 17, 2005 09:50 AM

Quote:
Can anybody help me in finding ERM Tutorial? (I want russian version)


http://forum.df2.ru/index.php?s=ab2391e6fe0d564754d9b187e69d9d42&showtopic=150&st=0
____________

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


Admirable
Legendary Hero
ghost of the past
posted September 25, 2005 08:23 PM

up

A script went wrong and everybody got... stoned.


____________

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


Promising
Famous Hero
Passed away
posted September 26, 2005 07:11 AM

Nice ... But can't you give some more information please
____________
The ultimate WoG tester

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


Admirable
Legendary Hero
ghost of the past
posted September 26, 2005 08:41 AM

Quote:
Nice ... But can't you give some more information please

I'm afraid it's nothing to write home about. At least not at the moment. I'll either locate the error in the script or make up a story about "Stone Dragons". LOL
____________

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


Promising
Famous Hero
posted September 26, 2005 08:18 PM

Quote:
Quote:
Nice ... But can't you give some more information please

I'm afraid it's nothing to write home about. At least not at the moment. I'll either locate the error in the script or make up a story about "Stone Dragons". LOL


It's most likely something to do with a monster's flag that you're setting (in battle), since that's what controls the stone effect. But you may be aware of this already.


____________

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


Admirable
Legendary Hero
ghost of the past
posted October 08, 2005 12:23 PM

Fnord, if I wanted to include external files (such as pictures in text events) in a campaign, would it work the same as with scenarios? Should I just put those in the maps folder?
____________

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


Promising
Famous Hero
posted October 08, 2005 08:26 PM

Quote:
Fnord, if I wanted to include external files (such as pictures in text events) in a campaign, would it work the same as with scenarios? Should I just put those in the maps folder?


I haven't worked with custom campaigns yet (I never even made one in standard Heroes 3) so I'm not really sure, although I would imagine it's the same way as with single maps. I think if the ERM points to a path to load a picture, it won't matter whether the map is in a scenario file or not and if I recall correctly, each ERM command handles the path for picture display a little differently (or some of them are different anyway, like portraits are different from multipurpose dialogues etc.).

I suppose the best thing you can do is to run a little test with one picture and your scenario and see if it loads correctly.


____________

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


Hired Hero
of the Dark knights
posted December 26, 2005 01:34 PM

How did the black dragons get stoned aren't they immune to all magics?

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


Admirable
Legendary Hero
ghost of the past
posted December 26, 2005 02:49 PM

Quote:
How did the black dragons get stoned aren't they immune to all magics?

Because it isn't a spell - it's an ability.
____________

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


Hired Hero
of the Dark knights
posted December 30, 2005 09:49 PM

Can someone tell me how to script?

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


Promising
Famous Hero
Revealer of Truth
posted January 03, 2006 09:49 AM

Quote:
Can someone tell me how to script?


You can find everything you want to know here: http://www.h3nl.narod.ru/index.html
____________

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


Hired Hero
of the Dark knights
posted January 06, 2006 07:47 PM
Edited by LordOfDeath on 6 Jan 2006

Thanks Gom jabbar! now i know how to do this . But i only need to know one more thing.. how do i switch names on creatures?

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


Promising
Famous Hero
posted January 07, 2006 12:16 AM
Edited by Fnord on 6 Jan 2006

Quote:
Thanks Gom jabbar! now i know how to do this . But i only need to know one more thing.. how do i switch names on creatures?


Use the UN:G1 command:

G1/#1/#2/$; Change Monster names.
  #1 - Number of Monster (Format C)
  #2 - Type of text
        0 - Singular name
        1 - Plural name
        2 - Specialty text
  $ - z variable (or its number) that keep the new text
        0 means restore original  

For example, to change the name of Centaurs to Ostritches, you could use:

ZVSE

!#VRz855:S^Ostritch^; [Set z variable 855 to "Ostritch"]
!#VRz856:S^Ostritches^; [Set z variable 856 to "Ostritches"]
!#UN:G1/14/0/855; [Change Centaur to Ostritch]
!#UN:G1/14/1/856; [Change Centaurs to Ostritches]


(Note: the stuff in square brackets are just comments so you can leave them out if you wish.)


____________

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


Hired Hero
posted January 26, 2006 12:12 AM

Hi

I use this script to start a combat in 25/25/0 (event there)
I want the conmbat to be vs 20 zealot.

ZVES
!?LE30/30/0;
!!HE-1:T25/25/0/9/20;

Can anyone tell me what is wrong?

(And if possible, tell me how to place a rock in the battlefield)

Thanks

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


Promising
Famous Hero
posted January 26, 2006 09:32 AM

Quote:
Hi

I use this script to start a combat in 25/25/0 (event there)
I want the conmbat to be vs 20 zealot.

ZVES
!?LE30/30/0;
!!HE-1:T25/25/0/9/20;

Can anyone tell me what is wrong?

(And if possible, tell me how to place a rock in the battlefield)

Thanks


First, it must be ZVSE and not ZVES and if you want the script to trigger from an event at 25/25/0 you'll need to use !?LE25/25/0; rather than !?LE30/30/0;

Anyway, the x/y/l location in the HE:T command is only to determine the type of terrain for the battlefield. The combat will always occur with the hero specified (or -1 for current hero), wherever he or she is. So if the hero trigger an event at 30/30/0 and you use that !?LE30/30/0 that's the one who will be in the combat with the 20 Zealots.


____________

 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 ... 9 10 11 12 13 ... 50 100 150 200 250 300 350 400 407 · «PREV / NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.4064 seconds