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 150 ... 192 193 194 195 196 ... 200 250 300 350 400 407 · «PREV / NEXT»
majaczek
majaczek


Supreme Hero
Work at Magic Dimmension
posted March 12, 2013 08:21 PM

Heh JimV thanks. But I probably didn't show the context well.  

If I summon additional commander creature for attacker it will be just a creature. I tried to "enable all atttacker comanders" after then - but it looks like popup is mismatched because it shows always paladin (while I wanted the additional commander to match the creature - this time to be same as real commander).

Is it a bug in WoG or I just call the function on wrong trigger (so bug on my side)?

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


Known Hero
Editing Heroes Without Limits
posted March 12, 2013 08:28 PM
Edited by felipe at 20:35, 12 Mar 2013.

-

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


Known Hero
Editing Heroes Without Limits
posted March 12, 2013 08:34 PM

JimV thanks a lot.

I tried this command:

!!UN:I1/1/0/100/0; ->place a learningstone (ok)
!!UN: O1/1/0; ->delete the learning stone (not ok)

The comand to delete always crash the game I tried also:

!!UN:I1/1/0/100/0;
!!OB1/1/0:T0 U-1; (set type and subtype to 0 and -1)
!!UN: O1/1/0;

but the command to delete the stone make the game crash anyway

why? How can I delete the object?

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


Admirable
Omnipresent Hero
Wog refugee
posted March 12, 2013 08:35 PM
Edited by Salamandre at 20:43, 12 Mar 2013.

Felipe, there is no reason the game crashes with that command unless there are some additional scripts around which you did not show.

Try this:

!?CM0;
!!VRv10:+1;
!!UN&v10=1:I1/1/0/100/0;
!!UN&v10=2:O1/1/0;
!!VRv10&v10=2:S0;

and keep right-clicking on adventure map.
____________
Era II mods and utilities

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


Responsible
Supreme Hero
posted March 12, 2013 08:35 PM

Okay, remove the word "expert". (I thought it would motivate, as in "You too can be an expert.") People who want to learn how to script should read ERM Help and practice. That is what ERM Help was created for, by the WoG Team with a lot of effort on their part. I am not an expert guitar player, but I learned enough to play some Blues by reading some manuals (e.g., "The Folksinger's Guitar Guide") and practicing.

It is hard for me to grasp that people who want to use something would rather not be an expert at it and use it well (I would like to be an expert guitar player), but maybe so.

Then there are people who don't want to learn ERM but just want the results. I thought those were the ones you were referring to. Hence the "moralizing", in response to that issue.

As I said, in general I am not so much trying to moralize as assuming that people who ask questions here do want to learn ERM, and trying to explain that reading the whole manual up front, counter-intuitive as it may seem, really does save time and frustration, in my experience. People who write manuals don't usually re-explain the basic concepts over and over at each command, but usually they do explain them and give examples at least once, somewhere.

(If the explanations can be improved I am certainly willing to update ERM Help (3.58f) to do so.)

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


Known Hero
Editing Heroes Without Limits
posted March 12, 2013 08:52 PM

Quote:
Felipe, there is no reason the game crashes with that command unless there are some additional scripts around which you did not show.

Try this:

!?CM0;
!!VRv10:+1;
!!UN&v10=1:I1/1/0/100/0;
!!UN&v10=2:O1/1/0;
!!VRv10&v10=2:S0;

and keep right-clicking on adventure map.


I was using trigger !?PI;
For some reason you canīt use the command UN:O with this trigger. It works well with !?CM as you proposed and !?TM as I am using now

Thanks

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


Responsible
Supreme Hero
posted March 12, 2013 08:56 PM
Edited by JimV at 20:58, 12 Mar 2013.

Felipe: Those commands will crash under a PI trigger, but not under a TM1 trigger. The general reason is that all of the map data is not set up when the PI trigger occurs, and references to data structures which are not set up will cause crashes.

Also, as Salamandre says, some other script might be causing the crash. It is always difficult to answer such questions from afar, without being able to read minds or see distant computer screens.

Majaczek: I still don't know (maybe I will do some experiments later), but I would not use the word "bug" when using something in a way it was probably not designed or tested for. E.g., it is not a bug that a submarine cannot go below a certain depth without its pressure hull collapsing. The WoG Team probably expected the CO commands to work on single Commanders and that Heroes would only have a single "Commander", although they may have more than one commander creature, as is done in "Stargate Atlantis". For extra creatures they wrote the Henchman script. So I would expect to have to use extra creatures with creature commands, not Commander commands. But I have never tried to do the latter (because I did not think it would work), so I may well be wrong. (If in fact I understand what you are saying.)

P.S. in both this and my previous reply I was too slow to respond before more comments came in as I was typing.

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


Promising
Undefeatable Hero
My BS sensor is tingling again
posted March 12, 2013 09:00 PM

Quote:
Okay, remove the word "expert". (I thought it would motivate, as in "You too can be an expert.") People who want to learn how to script should read ERM Help and practice. That is what ERM Help was created for, by the WoG Team with a lot of effort on their part. I am not an expert guitar player, but I learned enough to play some Blues by reading some manuals (e.g., "The Folksinger's Guitar Guide") and practicing.

It is hard for me to grasp that people who want to use something would rather not be an expert at it and use it well (I would like to be an expert guitar player), but maybe so.

Then there are people who don't want to learn ERM but just want the results. I thought those were the ones you were referring to. Hence the "moralizing", in response to that issue.

As I said, in general I am not so much trying to moralize as assuming that people who ask questions here do want to learn ERM, and trying to explain that reading the whole manual up front, counter-intuitive as it may seem, really does save time and frustration, in my experience. People who write manuals don't usually re-explain the basic concepts over and over at each command, but usually they do explain them and give examples at least once, somewhere.

(If the explanations can be improved I am certainly willing to update ERM Help (3.58f) to do so.)



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

Tavern Dweller
posted March 13, 2013 12:04 AM

Thanks for your help JimV and Salamandre.

However, this is only part of the battle - the standard specialist bonus shows the benefits when the stack is viewed from the Hero screen, so altering the A/D values during the battle is not a complete solution. I could not find a way to modify attributes of a hero's army outside of battle - is this possible in ERM?

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


Admirable
Omnipresent Hero
Wog refugee
posted March 13, 2013 12:21 AM

Well yes is possible, but why would anyone need stats changed in hero screen, as those changes are only useful in battles.

If still you want to do such thing, check era manual in mod manager then events:

Open hero window ^

!?FU77004;

Close hero window ^

!?FU77005;

Check current hero, if galthran, change stats using MA trigger. When close window, bring back stats to original, but as I said is work for nothing.
____________
Era II mods and utilities

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


Responsible
Supreme Hero
posted March 13, 2013 12:31 AM

The ten thousand hour figure was arrived at by studying cases like Mozart (music) and Roger Federer (tennis) and Grand Master chess players. ERM is much simpler and less demanding than those activities. In any case a good way to get started and become at least mediocre at something is to read an instruction book.

My older brother John was President of his Chess Club in high school and somehow got me to play him a game of chess every night during his senior year. He beat me every night, for about 50-100 games. Then he went to college and I saw a paperback book at a store by Renfield called "How to Play Chess" or something like that. I bought it and read it and when he came back from college in the summer I played him three times, won all three, and he has never played me again. There were/are still many people who can beat me at chess, but not so many as before I read the book.

While I have been typing this, as usual my email tells me two more comments have been posted, so I will slip my usual conclusion and see if anyone wants to learn ERM.

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


Responsible
Supreme Hero
posted March 13, 2013 01:03 AM
Edited by JimV at 01:14, 13 Mar 2013.

Crunch, I am not sure what you want to do either, but here are what the ERM commands that alter creature properties do (as explained in ERM Help):

A Hero's Attack and Defense skills are added to each of the Hero's troops in battle. HE:F can modify a Hero's Primary Skills (A/D/P/K).

The Secondary Skills Offense and Armorer affect the damage done by and received by a Hero's troops in battle. One of the Expert Tutorials describes how to change the amount of these effects.

MA:A, D, etc. modify the properties of a specific creature type - that is all creatures of that type on the map.

Hero specialties HE:X can add bonuses to a specific creature type and its upgrade (if it has a standard one) that is owned by a specific Hero.

BM:A,D, etc. can modify the properties of any troop (stack) in battle.

EA:B experience-based bonuses add to a creature's properties in battle.

Except for Speed, which can affect Hero movement points, the battle properties of a creature only have an effect in battle, as Salamandre says. You can see a creature's total battle skills (the sum of all influences) by right-clicking on the stack in battle. Most of these effects are not shown in the Hero Screen when you click on a troop slot there (as was true in Heroes 3 as well as WoG). However this could be done by intercepting the slot-click with the approriate CM trigger, checking for and summing all the bonuses (Hero-based, experience-based), adding the result to the base (MA:?) values and temporarily updating the value with MA for display purposes. In Era 2, as Salamandre says, you could use the new Era trigger for opening a Hero Screen to initiate this process for all troop slots. In Wog 3.58f or both you could use a CM trigger, slot by slot. (What to use as a trigger to restore the original base values in this case takes a bit of thought, which I will leave to the student.)

A complicated ERM script such as that requires knowledge of many different ERM commands. This is why one should read all of ERM Help. You will not be able to plan such scripts yourself until you do read all of ERM Help (and practice it).

P.S. I forgot to mention terrain-based bonuses, such as Gremlins on Snow or Pikemen on Grass. These are also not shown in the Hero Screen but are shown in battle. Unless you know in advance where the next battle will be (possible in a very constrained map, I suppose) if your goal is to show in the Hero Screen exactly what you will see in battle for creature properties, that goal does not seem feasible.

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

Tavern Dweller
posted March 13, 2013 01:08 AM

Hi Salamandre,

Still slightly off desired functionality, as the user then loses the ability to view the original A/D of the monster. Thanks for your help anyway, I will just leave off the ability for the user to view the modified A/D from the hero screen.

Cheers mate.

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


Responsible
Supreme Hero
posted March 13, 2013 03:40 AM
Edited by JimV at 03:54, 13 Mar 2013.

View original + (special) bonus in Hero Screen, e.g. Attack 5(7): not too difficult. Change the Hero specialty (HE:X) on the fly (temporarily) to apply the different special bonus to the upgraded creature.

Example: see Orrin's special ability in "The Dragon Slaughter". Orrin can upgrade almost any shooter to a better type of shooter, and any non-alive, non-undead creature to an Ice Elemental. This is done by changing his specialty whenever a shooter troop is clicked in his Hero Screen, then changing it back to Archery. You could adapt that script, just changing the type of Hero Specialty, the Hero number, and the types of creatures it applies to.

Or just increase the Hero's Attack and Defense temporarily since these also show up in the (bonus) total. There is usually more than one way to do things in ERM. Changing HE:X is probably easier though - less calculation involved, assuming your bonus system works the same way as the HE:X one does.

Of course this part of the script is for Hero-Screen display purposes only. The real effective part will take place in battle under the BF trigger, as discussed previously.


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

Tavern Dweller
posted March 13, 2013 04:58 AM

Champion, thanks JimV!

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


Known Hero
Editing Heroes Without Limits
posted March 13, 2013 11:51 AM

Hum... my problem with new objects of the same number persist.

When I put new Arenas with !!UN:i and one off them is visited all of them become visited.

I didnīt find a specific command to set the arena number.


The new whirlpools or subterranean gates also have problems.

The whirlpools do not connect with one another and the subterranean gate connects with far distant subterranean gates.

Is there a generic command to set the object number?


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


Admirable
Omnipresent Hero
Wog refugee
posted March 13, 2013 01:04 PM
Edited by Salamandre at 13:06, 13 Mar 2013.

I don't recall the maximum number of arenas a map can have but would be easy to test. Then try this:

ZVSE

!?CM0&-200;
!!UN:U4/0/?y-1; get the number of arenas on map
!!IF:M^There are %Y-1 arenas^;
[insert here exit if y-1 already at maximum]
!!VRy-1:+1;
!!UN:I10/10/0/4/0; place arena
!!OB10/10/0:Cy-1; give it a number not used
!!IF:V200/1; disable script

No idea about whirlpools and gates, but you can try same, use OB:C and give a number not used. In case it does not work, disable them then script destination, hero will be teleported to the other.

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


Responsible
Supreme Hero
posted March 13, 2013 01:48 PM
Edited by JimV at 13:52, 13 Mar 2013.

As already posted, ERM Help has this to say about Arenas, Whirlpools, and Subterranean Gates:
-----------------------------------------------
Other Objects
Some other objects not listed above (aside from rocks, trees, etc.) may need to be set up with the generic object command; you can try changing their control number so as not to duplicate an existing object of the same type, but this is by no means guaranteed to work. Also, some objects not listed may actually work fine with no set up required--but they have not been tested yet. Proceed at your own risk.
-----------------------------------------------
The generic object command is !!OB, and the control number (word) is OB:C. Sometimes - not always - OB:C simply contains the number of the object. You will have to test first: read the OB:C? value for a set of Arenas for a test map and see if they are 0, 1, 2, etc. My guess is they are and adjusting OB:C may work for them, but as ERM Help says, proceed at your own risk.

For Whirlpools and SG's, my guess is you are out of luck. The UN:I simply places an object, we already know that it does not integrate objects into the Heroes 3 database. However, you could provide the integration yourself with ERM. That is, disable the triggers, and under a !?OB trigger for the object, teleport the Hero (HE-1:P) to the desired location or a random choice among a set of locations. It is even possible to do this with the Teleport sound effect disabled and a Whirlpool sound substituted, but I will let you read ERM Help to find out how to do this.

P.S. I see I duplicated Salamandre's information, but will let this post stand due to a small amount of supplemental information in it.

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


Admirable
Omnipresent Hero
Wog refugee
posted March 13, 2013 01:55 PM

Just tested, does not work with arenas. I think when you place a new one, it is given number 0 by default and then no matter what number you give it, it still remains stored somewhere. So every arena placed will be set to visited if you visit one. But surely works with objects having their own receiver.

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


Honorable
Supreme Hero
posted March 13, 2013 02:50 PM

Salamandre, it means that there is a list of Arena settings, same as mines and mills and OB:C holds object's index. Setting number manually will probably corrupt adjacent memory.

 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 150 ... 192 193 194 195 196 ... 200 250 300 350 400 407 · «PREV / NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.4336 seconds