Sie sind auf Seite 1von 57

New ERM for 3.

58 - October 21, 2004


FLAGS:
System Flag changes and additions:
1) Flag 996 is automatically cleared (set to False) when any !!LE command execut
es and is set to 1 (True) if there is no Placed Event at the location specified
by the LE command (you know that a Placed Event is removed after usage sometimes
).
Flag 997 and 998 are set as follows:
2) Flag 997 returns the MP state of a battle.
=0 (False) if we have a local battle
=1 (True) if we have a network battle
Then if Flag 997=1, then
Flag 998=0 if an AI attacks a Human player at a distant PC
Note that the battle here runs at only ONE PC, but this PC is a distant one fo
r the current active PC.
Flag 998=1 if we have a Human vs Human battle. Here we have a real MP battle.
You may use both flags in BA0 or BA50 trigger like this:
!?BA0&997/998;
...
Here we go if this is a Human vs Human MP battle
3) For the previous two system Flags (already mentioned in ERM Help), here's a s
ummary of their meanings:
Flag 999 means "Is the User sitting before a screen the Current player?"
Flag 999 is set to 1 (True) if the current player (when trigger worked out) is
a player "here" and 0 (False) if he or she is at another (remote) PC. For examp
le, a mouse click trigger activated during another player's turn.
For the AI, Flag 999 will always be 0. If flag 999 is set, you can be sure that
this is a human and he is here. Flag 999 is working for all triggers
Flag 1000 is a Human/AI owner check and also real versus theoretical battle ch
eck.
=1 (True) - Human
=0 (False) - AI
For battle triggers (e.g., !?BA0, !?BG, !?BF, !?BR, etc.) Flag 1000 is a check
for a real vs. theoretical AI battle. If Flag 1000=1 (True), it means there's a
real battle (at least one human opponent). If Flag 1000=0 (False), it means tha
t it's a theoretical AI-only battle.
VARIABLES:
1) Trigger-based local variables:
y-1...y-100 are integer variables
e-1...e-100 are floating point variables
You may use them in the same places that you use y and e variables now.
Specific features:
1. They are NOT saved in the saved game. Actually every trigger section will run
completely and you cannot save and load a game being inside a trigger section.
2. These variables are local for every trigger and if even one trigger works out
inside another trigger section, they will have a different set of variables. As
you can see you cannot pass values from trigger to trigger using these variable
s.
3. All variables are set to 0 at any trigger start, so you can use this as a def
ault value.
4. All functions called from a particular trigger can access and share that trig
ger's set of variables, since they're trigger-based and not function-based.
2) New hero variables (now there's 200): w101..w200
These work everywhere that the first 100 w variables work except for one excep
tion: !!HT:W There you can use only the first 100 w variables.
NEW TRIGGERS:
BA52, BA53, CM5, GM0, GM1, MF1, MG0, MG1, MM0, MM1, MR0, MR1, MR2, PI, SN, TH0
, TH1
1) Two new triggers for start/end of battle: !?BA52; !?BA53;
!?BG and !?BF work at both sides and if the variables are the same, they will
give you the identical effect at both sides.
Only user related actions are not synchronous for both sides and BA0/BA50 and
BA1/BA51 triggers make a difference.
New BA triggers:
!?BA52 - called at a battle start at both sides
!?BA53 - called at a battle end at both sides
So at a battle start:
1. If it is an attacker's PC (or non MP game) BA0 is called
2. If it is a defender's PC BA50 is called
3. BA52 is called.
At battle end:
1. If it is an attacker's PC (or non MP game) BA1 is called
2. If it is a defender's PC BA51 is called
3. BA53 is called.
This means that if you want to have an identical code for BA0 and BA50, you ju
st need to make one section with BA52 header.
NOTE. If you want to test scripts in MP mode you cannot do it at the first gam
e turn (day one). You need to pass one day so all players will have an identical
environment.
2) New trigger for left-mouse click on the adventure map: !?CM5;
It may be used with all CM receiver commands that you use for right mouse clic
k: T, S, I, F, A, P, R.
3) Two new Triggers for Saving/Loading: !?GM0; !?GM1;
!?GM0 - is called right after loading a saved game but before showing the map.
!?GM1 - is called right before saving the game but after choosing the game to
save.
Example:
**********
ZVSE
!?GM0;
!!IF:M^Loaded^;
!?GM1;
!!IF:M^Saving^;
**********
Comments:
!?GM1 will also be called every time the game performs an autosave (i.e., each
day after pressing the End Turn button). If you wish to prevent this for some r
eason, you can disable the autosave with the UN:J5 command. Normally this isn't
advisable, however, as the autosave provides an important backup for the player
in case anything goes wrong.
4) New trigger for a stack taking physical damage: !?MF1;
!?MF1; (before an action)
5) Two new triggers for spell casting on the adventure map:
!?MG0; - pre trigger
!?MG1; - post trigger
Sequence:
- player clicks the "cast spell" icon
- !?MG0; works out (you can adjust current hero spells)
- Magic Book appears and a player chooses a spell
- Spell casting
- !?MG1; works out (the cast spell number is stored in v997)
Example:
************
ZVSE
!?MG0;
!!IF:M^Magic is ready to cast^;
!?MG1;
!!VRy-10:Sv997;
!!IF:M^Magic was cast. Spell number: %Y-10^;
************
Comments:
This doesn't work for AI heroes, only human players.
6) New Trigger for control over scroll text during a battle: !?MM0; (or just !?M
M;)
This trigger works when WoG is trying to show hint text in the scroll field (e.g
., "fly here").
Comments:
The !?MM0 trigger only functions prior to an action being chosen. So, for exampl
e, if I cast a spell, the display hints that show up while choosing a target don
't occur within the !?MM0 trigger at all. Once the target's been chosen and the
spell's been cast, it returns to using the !?MM0 trigger until the next action i
s taken.
7) New Trigger for town screen when you move the mouse over an object: !?MM1;
Now you can trigger ERM code when a player moves the mouse pointer inside the to
wn screen. It will work when you go over a section and when you go off a section
.
This trigger works out after standard behavior (usually hint text displaying).
8) New Combat Triggers for Stack Resistance ERM control: !?MR0; (or just !?MR) a
nd !?MR1;
!?MR0; works out just before calculating a resistance correction for a stack.
And !?MR1 works out after calculating. So here is the sequence:
- we have a basic damage from a spell (M,S,D);
- !?MR0 is called (M,S,D,F[=D]);
- WoG calculates a standard resistance correction (S,M, D->F);
- !?MR1 is called (M,S,D,F);
- end of correction (F).
Here M means a monster type, S means a spell number, D means the basic damage,
F means the corrected damage.
Standard WoG correction function calculated F from D and returned it.
For creatures that have no resistance F=D.
9) New Trigger for Dwarf-style Magic Resistance: !?MR2;
!?MR2; will work out when the game calculates dwarf-style magic resistance.
You may use !!MR and other triggers.
!!MR:N, !!MR:M works as before (described in !?MR0 and !?MR1 trigger
section). The !!MR:F here is used as a percentage (0..100) of a chance
for the spell to work.
Example:
**********
ZVSE
!?MR2;
!!MR:F0; all creatures are completely immune to all
**********
10) New trigger: !?PI;
Post Instruction.
This trigger works out a bit later than instruction are executed but
after the majority of settings are done for the map.
The other specific thing here is that this trigger works out ONLY
if you start a new game but not if you load a saved game (so the same
way as instructions do).
Example:
**********
ZVSE
!#IF:M^Instr^;
!?PI;
!!IF:M^Post Instr^;
**********
If you start this map, you will have two messages: "Instr" and then
"Post Instr". When the first message appears, almost no settings are
done for the map and when the second message appears, the most
settings are done already. If you load a saved game, you will have no
messages at all.
11) New Trigger for sound support: !?SN;
This triggers for any sound (WAV or M82, but NOT MP3). It triggers every time th
e game is trying to produce any sound. There is a corresponding receiver: !!SN.
12) Two New Trigger for Town Hall access. !?TH#;
!?TH0; is called when you enter a Town Hall
!?TH1; is called when you leave a Town Hall
Comments:
1. You could use the TH1 trigger to check for a new building built in a town.
2. You could also use it to reset the build flag with the CA:R command to allo
w additional building the same day.
NEW RECEIVERS (and commands for them): CB, EA, EX, IP, MF, MM, MP, MR, SN
1) New object receiver (Other Objects page): !!CB
Creature Bank setup.
!!CBx/y/l:... - receiver
Commands:
M$1/$2 - set/get/check a bonus creature type $1 and number $2
The number of bonus creatures should be >0 and <128.
To remove bonus creatures, set it to type -1 and number 0.
G#1/$2/$3 - set/get/check a guard creature in slot #1 (0...7), to type $2 and
number $3.
R#1/$2 - set/get/check a resource bonus. Resource type #1 and amount $2. You m
ay set all 7 resources simultaneously.
T$ - set/get/check whether CrBank is taken already (1) or not yet (0). Note, t
hat if you reset a bank to not taken (set to 0), you still should set at least o
ne guard stack unless you want the next hero that visits to get the treasure for
free.
V$ - set/check/get a word of visiting of a player. This is a bit mask, so red
is 1, blue is 2, tan is 4, green is 8 and so on.
Artifact bonus.
A1/$ - get/check number of artifacts in the bonus list (you cannot set it).
A2/#/$ - get/set/check an artifact $ at position # (0...) in the bonus list.
A3/$ - add an artifact $ to the end of the bonus list.
A4/$ - remove artifact at position $ (0...) in the bonus list.
Comments.
You can make an almost unlimited list of artifacts for any Creature Bank.
You cannot set a scroll as an artifact; the game will treat it wrong and then
crash.
The CB receiver should also work with Dragon Utopia, Crypt, Derelict Ship, and
Shipwreck.
2) New Receiver for adding stack experience support to ERM: !!EA
You may use !! and !# syntax.
Format:
!!EA$:...
$ is a type of monster.
Commands:
F$1/$2;
Get a number of the bonus line that has a specific ability or find the number
of the next free line.
$1 - ability number.
$2 - line index (-1,0...13)
Comments:
You may only get or check the second parameter but not set it. So the call lik
e this is a standard:
!!EA...:F65/?v100;
This will return the index of a line that keeps 'A' (65) bonus ability for a c
reature (attack bonus).
If the line is not found, it will return a line that is empty.
If you set $1 to 0, you will find the first free bonus line.
If $2 returns -1, there is no more room in the ability list for this creature.
Extended syntax for EA:F command: !!EA:F$1/$2/$3;
!!EA:F$1/$2/$3;
$1 ia an ability type
$2 is a modifier (-1 = does not matter, takes the first found)
$3 is a var to store the search result.
M$; - set/get experience multiplier
The value of $ is 1000 times more than used. So for 0.75 you will get
750. If you want to set it to 1, you should use M1000;
U$; - set/get experience upgrade multiplier.
The value of $ is 1000 times more than used (see M command).
L$; - set/get an experience scale and limit.
C$; - set/get an experience Cap.
This is the maximum percent of experience that a unit can gain from a single
battle.
B#1/$2/..../$15; set/get an experience line.
#1 - bonus line index (0...19) (you cannot "get" it)
$2 - Flags. For now:
0 - ability is disabled
1 - ability is enabled
$3 - ability (this is a numeric representation of a char)
$4 - modifier (this is a numeric representation of a char or a number for "#
..." parameter)
$5 - a value for a Rank 0 (no experience)
...
$15 - a value for a Rank 10 (max experience)
A$1/$2; - set an AI modifier.
$1 - difficulty level index (0...4)
$2 - modifier
This modifier is a multiplier that is used for AI hero's experience to get th
e resulting experience distributed to his/her stacks.
It is 1 (easy), 2, 3, 4, 5 (Impossible) by default.
S$1/$2; - set an AI modifier.
$1 - difficulty level index (0...4)
$2 - modifier
This modifier is additional experience that is used for AI hero's experience
to get the resulting experience distributed to his/her stacks.
It is 50 (easy), 100, 200, 300, 400 (Impossible) by default.
T$1/$2; - set an AI modifier.
$1 - difficulty level index (0...4)
$2 - modifier
This modifier is a multiplier that is used for AI hero's experience to get th
e resulting experience distributed to AI town garrison stacks. If the EA:A modif
ier is set to 0, the town garrison experience will be 0 regardless of the value
set here.
It is 10 (easy), 25, 50, 75, 100 (Impossible) by default.
H$1 - set a human experience modifier
$1 - modifier
This modifier is a multiplier that is used for human control heroes to determ
ine the experience gained by each army stack after a victorious battle. The defa
ult value is 100 (100% of the experience the hero gains from the battle).
Comments:
Settings are stored in a saved game.
For A, S and T and H commands the type of monster in EA$ may be any, say, 0 be
cause it is not used.
P$; - Experience for the final level of an experience line.
This is the experience after level 10 and to the maximum experience that a cre
ature may have. The syntax is the same as for EX:L command, for example, i.e. EA
...:P$
Support for stack experience on the battle field.
You can set experience points, experience lines and experience parameters for
any creature on the battle field.
Use any !!EA command for this. To refer to a stack on a battle field you need
to mention a stack index in negative range:
!!EA-1:... stack 0
!!EA-2:... stack 1
..
!!EA-42:... stack 41
As before you can use a positive value to apply the command to a type of creat
ure.
You may set experience parameters for any stack on the battlefield, right in B
A0 (BA50) trigger sections or later during a battle.
EA:E - set experience for a battlefield stack.
E$1/$2/$3/$4;
$1 - experience points
$2 - modifier (as for HE:C modifier - parameter 6)
$3 - creature type
$4 - creature number
You may use d modifier for $3 and $4 to not change the default creature type (
will be set automatically to a correct creature type).
Example:
!!EA:-2:E1000/2/d/d;
Set (2) experience points (1000) for creatures that are located in a stack num
ber 1 on the battle field.
Comment:
You may use this command ONLY for a stack on a battlefield.
So it should be !!EA-1:... !!EA:-42:...
EA#1:D?$; - Check if experience bonus lines were copied to a stack on the battle
field.
# is a stack index (reversed) -1...-42
$ a variable to get a "copied" value.
Comments:
If $ returns 0, the settings are taken from a default creature type bonuses an
d were not copied to a temporary BF settings for this stack. Actually it may hap
pen if you summon a stack.
If $ returns number 1...7, the stack bonus lines was copied and that was a sta
ck 0...6 in an attacking army.
If $ returns number 8...14, the stack bonus lines was copied and that was a st
ack 0...6 in an defending army.
If $ returns -1, this is a stack that was not in an attacking or defending arm
y but bonus lines for it were copied already.
So if you summon a stack and use this command, it returns 0 (bonus line was no
t copied). If then you use any command of EA:MULPCBO to not check but set anythi
ng for this particular stack and then check EA:D again, it will return -1.
The typical sequence is:
- check whether the bonus lines is copied with EA:D
- if no, use EA:O to copy them.
- now make any particular change with EA:MULPCB
EA#:O$; - copy all bonus lines and parameters.
# is a target creature type or stack.
$ is a source creature.
Comments:
This command copies all bonus lines and experience parameters of one creature
(on the battlefield or a type of creature) to a creature/stack.
Example.
!!EA-2:O0;
This command will set all bonus lines stack 1 on a battlefield (-2) to have th
e bonus lines of Pikemen.
Also all experience parameters (Upgrade multiplier and so on) are also copied.
This command is useful if you summon a stack and you want it to have specific
lines of another monster or for dynamic changing of any stack experience paramet
ers.
This command does not set experience points itself.
Extended syntax for EA:O command: EA#1:O$/#2;
Extended EA:O command. You may use it with the first syntax and also:
EA#1:O$/#2;
#1 - destination stack
$ - source stack
#2 - copying modifier
0 (default) - just copy source to destination
1 - if destination on Battlefield (BF):
- copy to destination plus all the same type of friendly stacks
if destination is a standard creature index:
- nothing will be done
2 - if destination on BF:
- copy to destination plus all the same type of enemy stacks
if destination is a standard creature index:
- nothing will be done
3 - if destination on BF:
- copy to destination plus all the same type of attacker's stacks
if destination is a standard creature index:
- copy to all the same type of attacker's stacks
4 - if destination on BF:
- copy to destination plus all the same type of defender's stacks
if destination is a standard creature index:
- copy to all the same type of defender's stacks
5 - if destination on BF:
- copy to destination plus all the same type stacks
if destination is a standard creature index:
- copy to all the same type of stacks
R$1/$2; - Artifact support for battlefield stacks.
EA...:R$1/$2 - set/check/get artifact and option
$1 = artifact index
$2 = artifact option
Comment.
For now only one artifact index ($1) is supported - 156 (banner).
For now only options 0...8 ($2) are supported.
3) New Receiver for creature stack experience: !!EX
Syntax:
!!EX$1/$2:...
$1 - hero index (-1, 0...MaxHeroInd)
$2 - slot index (0...6)
or
!!EX$1/$2/$3/$4:...
$1 - x coordinate (0...)
$2 - y coordinate (0...)
$3 - level of the map (0,1)
$4 - slot index (0...6)
Here you may give the location of a Hero, Town, Mine, or Garrison at positio
n x/y/l.
Commands:
A$1/$2/$3; set/check/get stack info
$1 - monster type
$2 - number of creatures
$3 - experience per creature
T$; set/check/get stack monster type
$ - monster type
N$; set/check/get stack number of creatures
$ - number of creatures
E$; set/check/get stack experience
$ - experience per creature
Extended EX Receiver. You may also use 5 parameters.
!!EX$1/$2/$3/$4/$5:...
$1 - x position
$2 - y position
$3 - map level
$4 - slot index (0...6)
$5 - type of owner
1 = Hero
2 = Town
3 = Mine
4 = Garrison
other = any first found
Comments
If you use 4 parameters, the fifth one will default to "any first found". The
searching goes in the order: heroes, towns, mines, garrisons.
Artifact support for stack artifacts.
R$1/$2 - set/check/get artifact and option
$1 = artifact index
$2 = artifact option
Comment.
For now only one artifact index is supported - 156 (banner)
For now only options 0...8 are supported
Extended syntax for stack artifacts (R command): !!EX...:R$1/$2/$3/$4;
!!EX...:R$1/$2/$3/$4;
$1 - has art or not (0=no, 1=yes)
$2 - type of art (for now only 156).
$3 - subtype of art (options 0...15 - we use not all yet)
$4 - number of art copies (0...3)
Comments
You can use get or set syntax.
EX Receiver command for stack combining: !!EX...:C$1/$2/$3(/$4/$5/$6)
!!EX...:C$1/$2/$3(/$4/$5/$6) combine stack experience
$1 - type of source stack
= 0 - hero by type
$2 - hero index (-1 = current)
$3 - hero's slot (0...6)
($4)- warning type (see below)
= 1 - hero by position
= 2 - town by position
= 3 - mine by position
= 4 - garrison by position
$2 - x position
$3 - y position
$4 - map level
$5 - army slot (0...6)
($6)- warning type
Returns.
The function set v1 variable.
= -1 - stack of different creatures (nothing combined)
= 0 - error occurred (nothing combined)
= 1 - combined successfully
Comments.
This function will add the source stack to the main stack assuming they are of
the same creature type. All experience is distributed. Artifacts are summed.
If you set warning type to 1 (default is 0), you will not get a message that c
reature types of two stacks are different. You may use it.
Example:
A hero visits an object and his stack 3 is added to stack 1 (they should be of
the same type):
!?OB5/3/0;
!!EX-1/1:C0/-1/3;
Another example.
You visit an object and you current hero "adds" a stack number 1 in a town wit
h an entrance at 3/2/0 to the stack number 3.
!?OB5/3/0;
!!EX-1/3:C2/3/2/0/1;
4 ) New receiver and commands to support network based battles: !!IP
!!IP - network service for a battle.
Commands:
V$1/$2 - send v vars from v[$1] to v[$2] (included both) to the opponent side.
R - reset random generator at both sides to the same sequence (do not use this
yet).
Also, a new !!FU command is added: FU:D
D - call a function at the opposite side. The syntax is the same as for FU:P c
all.
Some descriptions.
Now during a battle you may pass the values of v vars to the other side and ca
ll functions at the other side.
Say, you run a user dependent script (like stack splitting). The script runs a
t one side because it runs as a reaction to a human action (mouse click). So all
that you change at this side will not be changed on the other side.
Now you can pass all changed values to the other side not running a script the
re.
Example.
On the one side you run a mouse event driven script:
...
!!VRv1234:S999;
On the other side v1234 will still keep the old value.
To fix it use:
...
!!VRv1234:S999;
!!IP:V1234/1234;
The last command will immediately send the value of v1234 to the other side.
Now to the second part of the problem. Say you use some specific command that
has some effects on the battlefield (say you cast a spell with ERM).
Again, if it is done only at one side, there will be a problem because it is n
ot done on the other side. Now you may use a distant call for those cases. This
means that you call a function but it runs not at this local PC but at a distant
one (the opponent's PC).
Up to 16 x parameters are transferred.
Example.
On one side you have:
...
!!BMv10:Mi/y5/5;
To make it run correctly you should make some changes:
...
!!BMv10:Mi/y5/5;
!!FU12345:Dv10/i/y5/5;
!?FU12345;
!!BMx1:Mx2/x3/x4;
That is all. How it works. FU:D immediately transfer all x parameters to the o
ther side and makes a call of FU1234 there. So BMv10:M... command runs at one PC
and BMx1:M... at the other PC. If you pass all in the right order, you will see
the same effect at both sides.
Note that you can pass some vars with IP:V command and then call FU:D to pass
more than 16 x parameters to the other side.
Now, an example that you can check (tested):
***********
ZVSE
!?BG0;
!!IF:M^Hi!^;
!!VRv99:S99; !!VRv100:S100; !!VRv101:S101;
!!IP:V99/100;
!!FU123:D1/2/3/4/5;
!?FU123;
!!IF:M^V99=%V99, V100=%V100, V101=%V101, X1=%X1, X2=%X2, X3=%X3, X4=%X4, X5=%X5^
;
***********
You will see "Hi!" message at any action of a stack, then you will see a messa
ge "V99=99, V100=100, V101=0, X1=1, X2=2, X3=3, X4=4, X5=5" at the other PC. The
n you get "Hi!" at the other PC.
If you continue, you may notice that the next time the message will be: "V99=9
9, V100=100, V101=101, X1=1, X2=2, X3=3, X4=4, X5=5". So v101 is changed. This i
s because first you send v99 and v100 through the network and call a function th
at shows a message (and this is why
v101 is 0). But then the BG0 trigger will work out at the defender's side and v1
01 will be set to 101.
This example is only an example because in the script:
!?BG0;
!!IF:M^Hi!^;
!!VRv99:S99; !!VRv100:S100; !!VRv101:S101;
will work fine (identical) at both sides.
But if you run a script as a reaction to a human related event (mouse click ge
nerally), you need to think how to transfer changes to the other side.
Command to transfer W vars during a battle: !!IP:W$1/$2/$3;
!!IP:W$1/$2/$3; - Transfer hero based W vars
$1 - hero index
$2 - first W var index to transfer
$3 - last W var index to transfer
Also
!!IP:F$1/$2; - transfer flags
$1 - first flag index to transfer
$2 - last flag index to transfer
Command to set a player-receiver of your !!IP transfers: !!IP:D$;
Syntax: !!IP:D$;
$ = player index (-1 = all)
Comments.
Now you may transfer vars and call distant functions not only during a battle
but also on the map. So to point who you send the vars/call functions to you sh
ould set the destination player with this command. This works the same way as fo
r hero's w vars. So if you set !!IP:D, it will be the same until you (or someone
else) changes it.
Note that if you save and then load the game, the state of the destination playe
r is undefined so set it in every trigger that sends data.
Note also that if you send to all players (-1), all sent vars and distantly ca
lled functions will run at every PC in the game even in the current one. So firs
t it runs through all players one by one and the last player sends it to sending
initiator. This is a good way to inform all sides about specific changes.
5) New receiver for a stack taking physical damage: !!MF
Syntax:
!!MF:XXXX;
Commands:
N$ - a stack number (0...41)
D$ - a damage
F$ - a corrected damage
E$ - enable (1)/disable(0) taking a damage
W$ - get/check a type of attacker
$ = 2 - tower shot
= 1 - moat
= 0 - other
Comments:
You may check a stack number to get detailed info on this stack.
Damage and a corrected damage keep the same value on trigger switching (first
!?MF1 trigger section). We recommend not to change the D$ value for it is the in
itial damage that the game wants to apply to the stack and if you have more than
one !?MF1; trigger section, this command may be used to find the initial damage
value. Instead you can set a new damage value with the F$ command. Anyway, the
real damage that is used by the game after the trigger works out is taken from t
he F$ command. You may ignore the damage completely by using the E$ command (it
is enabled by default).
To simulate a block ability with ERM you can use a !?MF1; trigger, calculate a
chance to work out, disable damage with !!MF:E0; command, show the block animat
ion with !!BM:Q84; (set a bit "took a defense action", if you want) and add a co
rresponding message to the battle log with !!MM:Sz#; command.
6) New Receiver to Get/Set/Check scroll text during a battle or Get the position
of the mouse on the battlefield: !!MM
Syntax:
!!MM:$;
Commands:
D$ - Get or check the current position (code) that a mouse moves over (same as
the CM:D command). You can set this value too but we don't know what will happe
n (maybe nothing).
Mz# - Get/Set/Check the message displayed in the scroll bar. z# is a z variabl
e to set or store a message.
Example:
!?MM0;
!!MM:M?z5;
!!MM:D?i;
!!VRz10:S^P:%Vi M:%Z5^;
!!MM:Mz10;
This will show the position and original message when you move the mouse over
a battle field.
Sz# - add a message to the battle log.
7) New Receiver (MP3 Control): !!MP
Command:
S#/^filename^;
S#/$; where $ is the index of a z variable
Sets a custom MP3 file to play instead of predefined or user defined game music.
# is from 1..199 and the complete list is below.
Comments: Do not include the extension ".mp3". This is added automatically.
Example of setting a custom music file named "Code.mp3":
ZVSE
!?OB6/6/0; // visit something at 6/6/0
// Set Castle music to Code.mp3 in DATA folder
!!MP:S1/^..\data\Code^;
If you put an mp3 file in the mp3 folder, you do not need to mention a folder
itself:
!!MP:S1/^Code^;
Or if you have a file in the maps folder:
!!MP:S1/^..\maps\Code^;
8) New Receiver for Stack Resistance ERM control: !!MR
Syntax:
!!MR:XXXX;
You may call it ONLY from inside !?MR trigger sections.
Commands: M$,S$,D$,F$,N$.
M$ - monster type. (Format C).
Comments:
Usually you can use it for getting the number but you can also set the value (
make sense only in !?MR0 trigger) to simulate the resistance (actually there is
only golems resistance and Elementals sensitivity).
S$ is a spell number. (Format SP).
Comments:
Again, most useful to get the index but if you set it in !?MR0, you can adjust
Elementals sensitivity, for example. The basic damage is calculated before the
triggers work so changing the spell number does not change the damage.
D$ is the basic (without resistance) damage.
Comments:
This may be got or set. Both make sense. If you change this in !?MR0, your val
ue will be used as a basic spell damage for the creature by resistance calculati
ng routine.
F$ is the final (corrected) damage.
Comments:
If you check it in !?MR0, it will be equal to D$ value. Setting this value in
!?MR0 makes no sense for this value will be set by resistance calculating routin
e. Though it is very useful to be set in !?MR1. Using this way you can ignore a
default WoG resistance and set your
own value that will be returned as a final damage applied to the creature stack.
N$ is a stack number on the battle field (0...41).
Comments:
You can only get this value. There is a VERY IMPORTANT thing here! You know th
at the AI calculates losses without real battle if no human player takes part in
the battle. Moreover, the AI calculates possible battles every AI hero step to
estimate whether it may attack a human hero or not. This means that this command
will work ONLY if there is a real battle (even if it is a quick battle, it IS a
real battle). You know that we have flag 1000 in !?BA trigger to determine a re
al battle. So all that was said about !?BA trigger is identical for !?MR
trigger. Anyway, there is a check and you will get a syntax error if you try to
use N$ command not in the real battle.
9) New Receiver sound support: !!SN
The SN Receiver lets you play external or internal sound files at almost any typ
e.
Attention! If you try to play a sound, !?SN trigger will occur. So you can subst
itute even a sound played by ERM.
There are some limitations. First, sound files cannot be longer than 10 seconds.
Longer sound files will only play the first 10 seconds of sound. Second, when t
he game tries to play a sound it checks whether it is already being played now.
If yes, it just runs another copy. If no, it loads the sound again. To search fo
r the name it uses only the first 12 characters, assuming that the file is DOS b
ased 8.3 and is located in the DATA folder. So if you expect that the sound is p
layed rarely, it is not a problem at all, otherwise check it first.
Commands:
S$ - Get/Check/Set the sound file name to a z variable (Format SN).
Pz# - Play a sound file now named z#.
Here is a short tour of how to change sounds for objects.
For example, we may want to change a sound when we visit a learning stone.
First we need a file with a new sound. We'll use a sound file named 1.wav in t
his example. Then we need a "silent" file to avoid "resource not found" message
(you may find the ZQUIET.WAV file in the data folder).
Now place some learning stones on the map and add an ERM script:
***************
ZVSE
!?OB100; visit learning stone
!!VRz10:S^..\data\1.wav^; external WAVE or 82M file
!!SN:Pz10; Play it now !
!?SN; sound trigger
!!SN:S?z-10; store a sound file name
!!VRi:S0; !!VRz-9:S^Gazebo.wav^; !!VRi&z-10=z-9:S1; learning stone?
!?SN&i=1; continue if learning stone
!!VRz-10:S^ZQUIET.WAV^; nothing just silence
!!SN:Sz-10; shut up !
NEW COMMANDS FOR EXISTING RECEIVERS:
AR, BA, BM, BU, CA, CM, CO, DO & FU, DW, HE, IF, LE, OW, TR, UN, VR
NEW FORMAT FOR AR RECEIVER: !!AR$:XXXX;
New style for AR receiver - indexed.
- coordinates are in v[$],v[$+1],v[$+2]
NEW BA RECEIVER COMMANDS: Q, S
1) New BA Receiver command to control Quick Combat battles: !!BA:Q$;
!!BA:Q$ - set/check/get Quick Battle flag.
$ = 1 if quick battle is enabled and 0 if disabled.
2) New BA Receiver command to check for a siege battle: !!BA:S$;
!!BA:S$; get/check siege battle type
$ - type
= 0 - ordinary battle
= 1 - siege battle with Fort
= 2 - siege battle with Citadel
= 3 - siege battle with Castle
Comment.
You may not set this parameter.
NEW BM RECEIVER COMMANDS: U1, U2, U3, U4, U5, V
1) Three New BM Receiver commands for setting monster stats:
!!BM...:U1/$; - get/check/set stack's minimum damage
!!BM...:U2/$; - get/check/set stack's maximum damage
!!BM...:U3/$; - get/check set stack's number of shots
2) New BM Receiver command to change a spell to cast for a creature: !!BM..:U4/$
;
!!BM...:U4/$;
This command may be used for monster spell checking and changing.
Comments:
You may only change the spell for creatures that cast spells already but you s
hould choose a spell of the same kind. For example, if a creature normally casts
a spell on a friendly unit (say Ogre Magi's Blood Lust), you may change it to a
ny other single-stack beneficial spell (say Mirth or Haste) but not to another t
ype of spell (such as Slow or Magic Arrow), otherwise the AI will never use it.
However, if you only need a human player to be able to cast the spell with that
creature, almost all spells will work.
This example also "fits" a Commander case. They are set to cast spells like Og
re Magi. So to make a "monster" Commander cast spells you need to set it to any
correct value.
Also note that this command has no effect on creatures whose spell is determin
ed randomly each round, such as Master Genies and Faerie Dragons.
3) New BM Receiver command to return the index of a cloned stack (clone spell ca
st through ERM): !!BM#:U5/$;
!!BM#:U5/$;
$ - index of this stack's clone.
If there is no clone for this stack, it returns -1, otherwise it returns 0...4
1 - a number of the stack that IS a clone of this one.
BTW, you can set it. So if you clone a stack and then reset this field to -1,
the cloned stack will not be a clone of this one.
4) New BM Receiver command to show combat animations: !!BM#:V#;
!!BM#:V#;
# is a number of animation (Format AC)
This will show the animation on the stack.
NEW BU RECEIVER COMMANDS: G, M, V
1) New BU Receiver command to control special terrain modifiers: !!BU:G$;
Get/check/set the special terrain type and terrain modifier in combat.
Command syntax:
!!BU:G$;
-1 - no modifier
0 - coastal battle (does not attend a battle)
1 - Cursed Ground
2 - Magic Plains
3 - Holy Ground
4 - Evil Fog
5 - Clover Field
6 - Lucid Pools
7 - Fiery Fields
8 - Rocklands
9 - Magic Clouds
Comments:
If you set it BEFORE the game sets a background image for a battle, this will
use this value to pick up a corresponding background.
If you change it during a battle, you will affect the rest of the battle.
2) New BU Receiver command to add a new scroll text message: !!BU:Mz$;
Command syntax:
!!BU:Mz# - adds a message to the combat
Comments:
This differs from MM:M in that MM:M just shows the message and does not add it t
o the list while BU:M shows it and adds it to the list so you can use the up and
down arrows to scroll the combat message window view and find the message later
.
Also note that additional text can be displayed with this command, (for an actio
n or whatever), but you can't actually replace the original text; it's going to
show up regardless.
3) New BU Receiver command to win a battle: !!BU:V$;
BU:V$; win a battle
$ mean the side to win (0=right (defender), 1=left (attacker))
This will end the battle and the chosen side wins.
As you can see, this command may also be used to lose a battle.
NEW CA RECEIVER COMMANDS: B6, I, R
1) New CA Receiver command to build in town using an internal function: CA...:B6
/#;
!!CA:B6/#;
# - building number to build.
Builds a building in a town using an internal function.
The syntax and the meaning is the same as for CA:B1/# but because it uses an int
ernal function, buildings with multiple levels will be built correctly, and mage
guilds will have spells automatically added (although you can still change them
).
2) New CA Receiver command to set the external appearance of a town: !!CA...:I$;
Command Syntax:
!!CA:I# - sets the external town appearance. You can use only set syntax. Oth
ers make no sense.
Values for #:
0 = default (synchronizes the look with built structures, e.g., a Fort or Cap
itol)
-1 = completely destroyed
1 = destroyed a bit
2 = destroyed more
3 = destroyed a lot
3) New CA Receiver command to control town building flag: !!CA...:R$;
Check or set if a player can build this turn in a town.
!!CA...:R$;
$ = 0 if player/AI may build this turn
$ = 1 if player/AI may not build this turn (already did)
Comment:
You may use R0 any number of times during the turn and thus build any number o
f buildings in a town.
NEW AND UPDATED CM RECEIVER COMMANDS: I, M
1) Updated CM:I command:
Now the CM:I command should always return a correct value in the town screen for
town buildings, even if one structure overlaps another. Also it is set now to -
1 if no structure is found under the cursor.
2) New CM Receiver command to set hint text in the town screen: !!CM:Mz#;
Command Syntax:
!!CM:Mz# - this command can be used to set the hint text in the town screen, re
placing the default hint with your own. You can use global (z1..z1000) or local
(z-1..z-10) z variables.
Comments
To get additional information on where the mouse is situated, you can use other
!!CM commands: T, S, I, F, A.
Example:
!#VRz10:S^Hi, fellow!^;
!?MM1;
!!CM:Mz10;
NEW CO RECEIVER COMMANDS: A1, A2, A3, A4
1) CO:A - Commander artifact support
A1/#1/#2; Add a Commander artifact by type
#1 - artifact type (from 146...155)
#2 - number of won battles
Results:
v1=0 - artifact added
v1=1 - not a Commander artifact
v1=3 - Commander has this artifact already
v1=4 - no free slot
A2/#1; Remove a Commander artifact by type
#1 - artifact type (from 146...155)
Results:
v1=0 - artifact is removed
v1=1 - Commander does not have this artifact
A3/#1/$1/$2; Control a Commander artifact in a slot
#1 - artifact slot (0...5)
$1 - artifact type (from 146...155)
$2 - number of won battles
Results:
You may get/check or set artifact and/or number of won battles.
No additional checks is made for artifact type so be careful to avoid incorre
ct types or duplication.
A4/$1/$2/$3/$4/$5/$6/$7/$8/$9/$10/$11/$12 Control Commander artifacts in all
slots
$1 - artifact type (from 146...155) in slot 0
$2 - number of won battles for art in slot 0
$3 - artifact type (from 146...155) in slot 1
$4 - number of won battles for art in slot 1
$5 - artifact type (from 146...155) in slot 2
$6 - number of won battles for art in slot 2
$7 - artifact type (from 146...155) in slot 3
$8 - number of won battles for art in slot 3
$9 - artifact type (from 146...155) in slot 4
$10 - number of won battles for art in slot 4
$11 - artifact type (from 146...155) in slot 5
$12 - number of won battles for art in slot 5
Results:
You may get/check or set artifacts and/or number of won battles.
No additional checks are made for artifact type so be careful to avoid incorr
ect types or duplication.
Comments:
May not be applied to all Commanders (-2).
USING COMMANDERS WITH ERM:
All Commanders that will be placed on a map with ERM will have the same primar
y and secondary skills and the same statistic (but ability depends on a type of
them). Actually it is one Commander that may have many looks.
If you do not set any parameters for such Commanders, they will have default g
ame start up parameters. So if you want it more powerful, use the CO receiver. T
o apply all changes to only these additional Commanders use index -3 (all Comman
ders at attacking side) and -4 (all
commanders at defending side).
In order to make it into a "real" Commander you must set it to "alive" with th
e CO receiver and you should also set its type. You can give any Commander speci
al abilities or set any Commander stats as you would for a normal Commander.
If you DON'T set a Commander to alive with the CO receiver, it will instead be
a "monster Commander" and will always have Fly and Shooting abilities. Stats and
other abilities for these "monster" Commanders must then be set with other ERM
commands and not the CO receiver.
Note, that you can set all in the BA0/BA50 trigger section or later in the bat
tle. All settings will be lost after a battle and will not be saved in the saved
game.
Also, to be sure that all goes fine, please place a corresponding set of Comma
nders at attacker's side (174...182) and defender's side (183...191).
NEW DO AND FU RECEIVER SYNTAX AND NEW FU COMMAND:
1) FU and DO Receivers have extended syntax to provide return values.
Now you may use "?var" syntax to return values from the call.
You can use a v, y- or y variable to store the return value.
Say:
!!FU...:Pv1/v2/v3/?v4;
Now if you change x4 value inside of the function, say:
!!VRx4:Sx1;
it will be copied to v4 after function return.
Comments:
The value of the variable itself (v4) is not transferred to x4 at a function c
all. Instead the index of the var is transferred (so x4 will keep value 4).
In DO loop the index value (4) will be passed at every iteration.
So if you set it inside of the function body, it will be copied to the variable-
receiver after the end of the iteration and restored to index value at the begin
ning of the next iteration.
Also you may use "=var" syntax to set (parse) the value at every DO loop itera
tion (make no difference with standard "var" syntax for FU call).
Say:
!!VRv35:S10;
!!DO...:P=v35;
Now if you change the v35 inside of the loop body it will be passed to the nex
t iteration taking account changes made for v35:
!!VRv35:Sx1+1;
So now it gives you x1 equal 10,11,12,13... at every iteration.
If you use the standard syntax:
!!VRv35:S10;
!!DO...:Pv35;
you will have x1 = 10,10,10,... at every iteration.
Comments:
You may use any number of such variables in the call.
You may use the same var (see example below) with ? and = syntax.
Example 1:
!?FU2;
!!VRx2:Sx2+17;
!!VRx3:Sx1+17;
!?FU1;
!!FU2:P13/?y-1/?y-2;
!#IF:M^%Y-1,%Y-2^;
!#FU1:P;
!#IF:M^%Y-1,%Y-2^;
You will see "0,0" and then "16,30".
Example 2:
!?FU2;
!!VRx2:Sx1+17;
!!IF:M^x=%X1^;
!?FU1;
!!VRy-1:S33;
!!DO2/1/20/1:P=y-1/?y-1;
!#FU1:P;
You will see 33,50,67...
2) New FU receiver command for network battles: D
D - call a function at the opposite side. The syntax is the same as for FU:P c
all.
See the IP receiver description for more details and examples.
3) New FU receiver command to check for wrong y vars usage: C
!#FU:C$;
It will check only if you try to set a y var outside of a function body (execu
tion time), for this is the main case of the problem (reading is not a problem a
t all if it worked correct).
By default the checking is disabled.
Syntax:
!#FU:C$; enable/disable wrong y usage check.
$=0 - enables run time check
$=1 - disable run time check (default)
This is most logical to use as an instruction and may be useful when testing s
cripts.
Very simple usage. Example:
************
ZVSE
!#FU:C;
!#TM1:S1/999/1/1; set TM1 for red
!?TM1;
!!VRy1:S1;
!!FU123:P;
!?FU123;
!!VRy1:S2;
************
Here when the timer section is executed, you will get a message that y var i
s set outside of the function body.
EXTENDED DW RECEIVER COMMAND: O
1) Extended DW:O command passes control of a dwelling to another player.
!!DWx/y/l:O$/1; pass control over a dwelling to another player
$ = is a new owner.
The second parameter is a dummy but use 1 there.
This syntax changes the owner plus calls an internal structure to adjust all g
rowth numbers for the previous and a new owner. It should also work correctly in
MP mode.
NEW, EXTENDED, AND UPDATED HE RECEIVER COMMANDS: A1, B0, B3, C0, C1, C2, G, O, R
5, R6, S, X
1) Extended HE:A1 command now supports backpack slots: 19..82 are backpack slots
.
2) Updated HE:B0/$ command:
Now if you customize a name but do not set a biography, it will display a hero
's default biography, rather than setting it to the same string as the customiz
ed name. So if you want to name Orin "Orin II", it will still display Orin's def
ault biography.
3) New HE Receiver command to read a hero's default biography: !!HE:B3/?$;
!!HE:B3/?$;
Get a hero's default biography text to a string variable.
This will always return the same text whether you changed the hero's biography t
ext or not.
You may use only get syntax, like this:
!!HE0:B3/?z25;
This will store Orin's default biography in the z25 variable.
4) Extended !!HE:C0, !!HE:C1 and !!HE:C2 syntax for setting or retaining Stack
Experience.
(Note: does not work with HE:C).
Now these commands may have 5 or 6 parameters:
!!HE...:C#/#1/$2/$3/$4/$5
$4 = experience value (default is 0)
$5 = experience modifier (default is 0)
Supported $5 modifier values:
Mode 0 - Use this mode to add additional creatures that have experience.
New creatures have their own experience $4, but old creatures (if you "add" mo
nsters) keep their own experience. The result of experience per creature is calc
ulated as:
Exp=(ExpOld*NumOld+ExpNew*NumNew)/(NumOld+NumNew)
a) Say you have a stack of 10 Monks with Exp 1000 (here and later per creature)
and want to add 5 Monks with experience 3000.
The result will be: (1000*10+3000*5)/15=1666
Ex: HE...:C0/0/d/d100/5000/0;
Add to the stack 100 creatures with exp 5000.
b) If you add a creature of a different type, only the experience of the new cre
atures is taken. So if you have 10 Griffins Exp 1000 and want to add 5 Monks wit
h experience 3000.
The result will be: 3000.
This is used to avoid problems when you move stacks from one slot to another a
nd the experience is mixed. Say you placed a stack of Griffins in the stack 1 an
d then changed it to Monks accidentally forgot to change experience (so it IS a
stack of Monks but the system
thinks that it IS a stack of Griffins). So now adding more Monks, the system wil
l think that you changed the type of creatures and takes only experience of new
creatures.
Exception: if the stack has not gained experience yet the experience will be a
veraged as if you weren't changing the type (same as mode 1).
Note: do not use the 'd' modifier for $4 with mode 0.
Mode 1 - The same as Mode 0 except that there is no check of creature type. So i
t always works according a) formula (above) whatever type of ex and new creature
type you have.
Examples.
a) you want to set creatures in slot to Pikemen and they should have the experie
nce (per creature) of previous creatures in the stack (whatever they were) plus
new 7 creatures has 50 exp. points.
!!HE...:C0/1/0/d7/50/1;
Note: do not use the 'd' modifier for $4 with mode 1.
Mode 2 - Use this mode to set experience for the whole stack.
The stack will always be set to $4 experience.
Example: HE...:C0/0/d/d/5000/2;
The stack will have experience 5000
Note: if you use the 'd' modifier with Mode 2 for $4, it will add the experienc
e instead. This is identical to the operation of mode 3.
Mode 3 - Use this mode to add additional experience to a stack.
Ex: HE...:C0/0/d/d/5000/3;
The stack will have +5000 experience.
New creatures take the experience of the old creatures plus $4. Experience is no
t distributed. So if you have a stack of 10 Monks with Exp 1000, want to add 5 M
onks and add 3000 experience with Mode 3, the result is: 1000+3000=4000.
Ex: HE...:C0/0/d/d5/3000/3;
The stack will have +5 creatures and +3000 experience.
You can also use this mode to add creatures to a stack without reducing the st
ack's experience, or change the type of creatures in the stack while keeping the
experience unchanged.
You may use this modifier for temporary creature type changing as well, becaus
e the new stack will still have the same experience and if you change it then ba
ck, the stack will keep the experience.
!!HE...:C0/1/0/d/0/3;
!!HE...:C0/1/99/d/0/3;
!!HE...:C0/1/0/d/0/3;
Note: if you use the 'd' modifier for $4 with mode 3 it will work the followin
g way:
StackExp=OldExp+OldExp+AdditionalExperience. So if a stack had 2000 experience
, and you add 1000 experience, it will have 2000+2000+1000=5000. Then if you add
another 1000 experience it will have 5000+5000+1000=11000.
Mode 4 - Use this mode to add experience Levels (Ranks) to a stack.
New creatures take the experience of the old creatures plus experience equal t
o $4 levels.
Experience is not distributed. So if you have a stack of 10 Monks with Exp 1000,
and want
to add 5 Monks and add 3 experience levels, the result is:
1000+3levels=????
It uses the next calculation:
- we have E exp
- get a current stack exp. level L0
- get an exp. value E0 for level L0
- get a reminder dE as E-E0
- we have a level bonus L
- get a resulting level L1 as L0+L
- get an exp. value E1 for level L1
- get a final exp. E as E1+dE
Ex: HE...:C0/0/d/d/5/4;
The stack will have +5 experience levels.
Note: do not use the 'd' modifier for $4 with mode 4.
Mode 5 - Use this mode if you upgrade creatures.
The same as Mode 3 but the experience of new creatures is taken as though you ma
de an upgrade of old creatures. The new experience will be the old experience mu
ltiplied by the Upgrade Multiplier plus an experience bonus.
Ex: HE...:C0/0/d/d/500/5;
The stack will have experience as if upgraded +500 experience.
Note: do not use the 'd' modifier for $4 with mode 5.
Mode 10 - Use this mode to add additional creatures with levels (ranks) of exper
ience.
This is the same as Mode 0 but $4 means additional levels (ranks) of new creatu
re type experience.
Ex: HE...:C0/0/d/d100/5/10;
Add to the stack 100 creatures with exp of Rank 5.
Note: do not use the 'd' modifier for $4 with mode 10.
Mode 11 - The same as Mode 10 but regardless of creature types.
This is the same as Mode 1 but you add creatures with experience equal to $4 l
evels (ranks).
Ex: HE...:C0/0/3/d100/5/11;
Add to the stack 100 creatures with exp of Rank 5, but also changing their typ
e to Marksmen.
Mode 12 - Use this mode to set the experience level (rank) for the whole stack.
This is he same as 2 but $4 means experience levels (ranks).
Ex: HE...:C0/0/d/d/5/12;
The stack will have 5 levels (ranks) of experience.
Mode 13 - Use this mode to set the equivalent percentage of experience for a new
type of creature.
This is the same as Mode 3 but it is assumed that you change the type of creat
ures and a new creature experience is taken as the same percentage that the old
creatures have.
So if you have a stack of Monks with exp. X and change it to a stack of Angels
, the new experience will be:
X*MaxA/MaxM+dE
where MaxA is a max experience of an Angel and MaxM is a max experience of a M
onk, dE is the added experience.
Ex: HE...:C0/0/../d/1000/13;
The new stack gets the corresponding experience that the old stack had plus 10
00 exp.
NewExp=OldExp*NewCreatureTypeR10Exp/OldCreatureTypeR10Exp+ExtraExp.
Mode 14 - The same as Mode 13 but an addition is experience levels (ranks).
Ex: HE...:C0/0/../d/3/14;
The new stack gets the corresponding experience that the old stack had plus 3
levels (ranks) of exp.
5) New HE Receiver command to set initial hero's movement points: !!HE#:G$;
!!HE#:G$;
$ - initial hero's movement points.
Comment:
If you set both HE:W and HE:G options to the same value (any), you may dig for
the Grail.
6) Extended HE:O command syntax to use a "neutral" hero in a battle.
Use a dummy second parameter in HE:O command (like HE...:O5/1; ) to use this wa
y. If you use a two parameters syntax, it will directly change the hero's owner.
You can use this to set an unowned hero to defend a neutral monster stack, but
make sure that the owner is changed back to -1 after the battle is over. Note: i
f you change an unowned hero in this way to temporarily give it an owner (number
0..7), it can be read with HE:O, but BA:O will still return -1.
7) New HE Receiver command to set maximum morale: !!HE:R5/$;
$=0 - Maximum Morale not set.
$=1 - Maximum Morale is set.
8) New HE Receiver command to set maximum luck: !!HE:R6/$;
$=0 - Maximum Luck not set.
$=1 - Maximum Luck is set.
9) Extended HE:S command to control a Hero's secondary skill sequence: !!HE#:S$1
/$2/1;
Check or set the sequence of a Hero's secondary skills:
Syntax:
!!HE#:S$1/$2/1;
$1 - is a number in display sequence (0 = not shown, 1..8 = slot index)
$2 - is a skill index (0...27)
Comments:
You may use three types of syntax:
!!HE#:S?#1/#2/1; ask what display slot takes #2 skill to #1 var
!!HE#:S#1/?#2/1; ask what skill occupies display slot #1 to #2 var
!!HE#:S#1/#2/1; set display slot #1 to #2 skill
In the last case if another skill takes this slot, it will be set to
"no slot". You can use the command twice to swap two skill positions.
When setting skills with this command, you must use the following rules:
- you may move any two displayed skills to exchange their position;
- you must NOT set a skill to display if it's below Basic level (no skill);
- you must set skills to display in order (no empty spaces);
Therefore you cannot use the command to hide a skill that's already
displayed. You also can't use it to set a skill to display if the hero
doesn't know the skill. Attempting either will usually display a different
"phantom" skill (perhaps Basic Wisdom) that will crash if clicked on.
10) Extended HE:S command to control the number of skills displayed: !!HE:S$;
Check or set the number of known skills that are displayed:
Syntax:
!!HE:S$;
$ - number of skills to show (0..8).
Comments:
If you want to display only one skill, first swap it's display position to slo
t number 1 and then limit the display to only 1 skill with this command.
11) Extended HE:X command to control specialty settings: !!HE#:X$0/$1/$2/$3/$4/$
5/$6;
!!HE#:X$1/$2/$3/$4/$5/$6/$7; - get/set/check all speciality settings.
$1...$7 - parameters.
Speciality types (defined by $1)
$1=0 Secondary skills
$2=secondary skill number
($3...$7 ignored, preferably 0)
$1=1 Creatures
$2=creature type number
($3...$7 ignored, preferably 0)
$1=2 Resources
$2=resource type
($3...$7 ignored, preferably 0)
$1=3 Spells
$2=spell number
($3...$7 ignored, preferably 0)
$1=4 Creatures extra
$2=creature type number
$3=attack bonus
$4=defense bonus
$5=damage bonus
($6...$7 ignored, preferably 0)
$1=5 Speed and other
$2=subtype
($3...$7 ignored, preferably 0)
$1=6 Upgrades
$2=creature 1 to upgrade
$6=creature 2 to upgrade
$7=creature to upgrade to
($3...$5 ignored, preferably 0)
$1=7 Dragons
$2=no matter (it is a placeholder for a creature type)
$3=attack bonus
$4=defense bonus
$5=damage (low and high) bonus
($6...$7 ignored, preferably 0)
$1=8 Extra WoG speciality
$2=subtype
($3...$7 ignored, preferably 0)
Comment.
You may use 'd' modifier to ignore unchanged settings:
HE:...:X8/2/d/d/d/d/d;
The original syntax (number of parameters < 7)
should work as before.
Example.
To check the current settings use:
!!HE#:X?y5/?y6/?y7/?y8/?y9/?y10/?y11;
NEW AND EXTENDED IF RECEIVER COMMANDS: N, N1, Q
1) New IF Receiver command for 8 picture message box:
!!IF:N#1/#2/#3/#4/#5/#6/#7/#8/#9/#10/#11/#12/#13/#14/#15/#16;
and also: !!IF:N^text^; and !!IF:N1/$;
A message with text and up to 8 pictures of any internal types.
This is the same as you can see if you set a global timed event with some resour
ces.
The syntax is:
!!IF:N...;
If you set more than 3 parameters, the interpreter treats it as pictures types
/numbers the same way as for the IF:Q dialog.
You may set up to 8 pictures (16 parameters) and minimum 2 pictures.
No dialog is shown, just preparation phase.
So:
!!IF:N3/8/10/2/11/3/13/2/17/1000/21/99/22/4;
means that the first picture (3/8) is a resource - sulfur with quantity 8. The
next one is (10/2) a flag of Tan player, then Luck and so on. You can see that
here we have 7 pictures.
Another syntax is:
!!IF:N...;
If you have less than 4 parameters, the interpreter treats it as a command to
show the dialog that was prepared with the previous syntax.
The only parameter here is the text to display:
!!IF:N^text^; - direct text
or
!!IF:N1/$; - z var (standard, local or extended)
In any case, the text is parsed for any format commands and as a result you wi
ll not see something like this "Hi %Z10!" but "Hi Slava!".
There is one limitation to the text: it can not have too many lines. This exam
ple is close to the maximum:
!!IF:N^This
is
a
looo...
..
..
..
..
..
oong
Text^;
If you have more lines, the game crashes.
2) Extended IF:Q command - message type "10": !!IF:Q#/.../10^text^;
If you use IF:Q#/... command with message type 10 (choice of two pictures plus
a Cancel button), the result will be stored not in the flag variable # but in th
e standard ERM variable (v#) but in the range of v1..v1000 only. So you will be
able to take the returned value:
0 = escape pressed
1 = left picture is chosen
2 = right picture is chosen
NEW AND EXTENDED LE RECEIVER COMMANDS: A, B1, B2, B3, B4, N, S
1) Extended LE functionality: Pandora's Box.
Now you can use the !!LE receiver to program Pandora's Box.
All LE commands should work. To trigger it, use !?OB trigger with any kind of sy
ntax.
Note: you still can't change the number of secondary skills, artifacts, or spell
s (same as an event), only change existing ones.
2) Extended LE:A, LE:N and LE:S commands:
!!LE...:A$; get the number of artifacts
!!LE...:N$; get the number of secondary skills
!!LE...:S$; get the number of spells
You can use a set syntax but it will change nothing.
3) Four new LE Receiver commands to control artifacts: !!LE...:B#/$;, !!LE...:B2
/#/$;
Control Artifact bonus.
B1/$ - get/check number of artifacts in the bonus list (you cannot set it).
B2/#/$ - get/set/check an artifact $ at position # (0...) in the bonus list.
B3/$ - add an artifact $ to the end of the bonus list.
B4/$ - remove artifact at position $ (0...) in the bonus list.
Comments.
We have the LE:A command already but it allows only to change artifacts in the
bonus list. This new command lets you set, add and remove new artifacts from Lo
cal Events and Pandora's Boxes, like the CB:A command does for Creature Banks.
You can make an almost unlimited list of artifacts for any Local Event or Pand
ora's Box.
You cannot set a spell scroll as an artifact; the game will treat it wrong and
then crash.
NEW AND EXTENDED OW RECEIVER COMMANDS: N, O, S
1) Extended OW:N command syntax to get town number in the town list: !!OW:N#1/#2
/$;
Now you can get a number of a town that is shown in one of 5 slots at the rig
ht side of the adventure map in the town list:
!!OW:N#1/#2/$;
#1 - is an owner (-1=current)
#2 - is an index of the slot (0=top..4)
$ - is a town number (-1=no town,0..N=number of towns)
Comments:
You can use only GET or check syntax.
Example:
!!OW:N2/3/?y10; get the number of a town that is located in the forth slot for
the Blue player and store it in y10.
2) Extended OW:N command syntax to move a town in the town list: !!OW:N#1/#2/#3/
#4;
!!OW:N#1/#2/#3/#4 - move a town in the list
#1 - owner
#2 - action type:
1 = move town to the top of the list
2 = move town one position up
3 = move town one position down
#3 - town list slot of a town (0..4)
#4 - dummy parameter (0)
3) Extended OW:O command syntax to control all active heroes for a player:
!!O#/$1/$2/$3/$4/$5/$6/$7/$8/$9/$10;
!!O#/$1/$2/$3/$4/$5/$6/$7/$8/$9/$10;
#=number of owner (-1=current) (FORMAT E1)
$1 - number of heroes the owner has
$2..$10 - Hero ID numbers owned by this player (-1=no hero) (FORMAT H)
Comments:
This command lets you check the hero numbers of all active heroes (maximum is 8)
that a player has as they appear in the hero list (left side of the main advent
ure map screen). They can also be set if you wish to change the order that heroe
s appear in this list. If the owner has less than 8 heroes, the numbers at the e
nd will have a value of -1.
4) Extended OW:O command syntax to get a hero number in the hero list: !!OW:O#1/
#2/$;
Now you can get the number of a hero that is shown in one of 5 slots at the r
ight side of the adventure map in the hero list:
!!OW:O#1/#2/$;
#1 - is an owner (-1=current)
#2 - is an index of the slot (0=top..4)
$ - is a hero number (-1=no hero,0..N=number of heroes)
Comments:
You can use only GET or check syntax.
Example:
!!OW:O2/3/?y10; get the number of a Hero that is located in the forth slot for
the Blue player and store it in y10.
5) Extended OW:O command syntax to move a hero in the hero list: !!OW:O#1/#2/#3/
#4;
OW:O#1/#2/#3/#4 - move a hero in the list
#1 - owner
#2 - action type:
1 = move hero to the top of the list
2 = move hero one position up
3 = move hero one position down
#3 - hero list slot of a hero (0..4)
#4 - dummy parameter (0)
6) New OW Receiver command for casting spells on the adventure map: !!OW:S;
Syntax:
!!OW:S#1/#2;
#1 - is a case (for now 1 or 2)
In case 1:
#2 - is a spell number to cast (0..9)
The spell will be cast by the current hero.
In case 2:
#2 - is a dummy number (say, 0)
This will open the magic book for the current hero. This is actually a way to
simulate a player clicking the "cast spell" button.
Comments:
1. No spell book is needed and the hero doesn't need to know the spell.
2. The skill level is based on the hero's elemental magic skill (as usual).
3. Spell points are removed from the hero when the spell is cast, but if the he
ro doesn't have enough it will be cast anyway (and it will never be reduced belo
w 0).
4. The hero must still have enough remaining movement points for Dimension Door
or Town Portal to work.
NEW TR RECEIVER COMMAND: G
1) New TR Receiver command to control special terrains (terrain overlays): !!TR.
..:G$;
Command syntax:
!!TR:G?$ - Returns the topmost terrain overlay. You may only use GET or CHECK sy
ntax.
21 - Cursed Ground
46 - Magic Plains
227 - Holy Ground
224 - Evil Fog
222 - Clover Field
225 - Favorable Winds
228 - Lucid Pools
226 - Fiery Fields
231 - Rocklands
229 - Magic Clouds
NEW AND EXTENDED UN RECEIVER COMMANDS:
A, B7..B10, J1..J10, N5..N6, P, Q, R4..R7, U, V
1) Extended UN:A command syntax for Combination Artifact management:
Combination artifact management:
!!UN:A#/$/#1/#2{/#3/#4/#5/#6/#7/#8/#9/#10/#11/#12/#13/#14};
Build/remove a Combo Art.
# - Combo index (0...31)
$ - set/check/get Combo Art Num (0...MaxArtNum)
#1 - Part 1 of Combo art
#2 - Part 2 of Combo art
#3 - Part 3 of Combo art (optional)
.
.
#14 - Part 14 of Combo art (optional)
Results.
Combo art is set up.
If successful ERM Flag 1 is set to 1 otherwise to 0.
Comments.
0. You may use an instruction syntax !#UN:A
1. All Combo settings are kept in a specific table. This table is extended up to
32 entries. So we can have up to 32 combo arts. All standard combos are already
in the table (first 12 entries).
2. You may check whether the table entry is empty or not:
!!UN:A5/?v100/0/0;
Get the combo art number in an entry 5 of a Combo Table to v100. Two zeros in
the end is needed to have at least 4 parameters.
In a check/get syntax extra (zeros) parameters are ignored.
NOTE. The empty entry in the Combo table keeps a combo art number 0.
So in an example above, v100 will have 0 if the entry is empty and you can use i
t.
You may delete a combo art without adding a new one. Use Combo Art number 0 to
do it. Example:
!!UN:A5/0/0/0;
First 0 means remove Combo info in entry 5 of the combo table.
The next two zeros are just to make sure that we have 4 parameters, no less.
Important: only artifacts with an index below 160 may be a part of a Combo art
ifact although any artifact be used for the assembled combination.
2) Extended UN:B commands for new Commander Stones: !!UN:B7..10/%;
Syntax:
!!UN:B7..10/$;
Comments:
Power Stones work as follows:
i) Non-WoGified WoG Map without ERM, with WoG Options set to Commanders Disabled
,
*or* Non-WoGified WoG Map with Commanders enabled by ERM, Power Stones disabl
ed by ERM
(!#UN:P3/0; and !#UN:B7/0; !#UN:B8/0; !#UN:B9/0; !#UN:B10/0;).
*or* WoGified Map with Commanders disabled through WoG Options, Power Stones
option enabled or disabled.
Result: Power Stones act as standard treasure chests.
ii) Non-WoGified WoG Map without ERM, WoG Options set to Commanders Enabled,
*or* Non-WoGified WoG Map with Commanders enabled by ERM (!#UN:P3/0),
Power Stones enabled by ERM or NOT disabled by ERM (!#UN:B7/1; etc. -- the
default for Power Stones is enabled if no UN:B commands for them is included
).
*or* WoGified Map with Commanders Enabled through WoG Options, Power Stones
option
option enabled or disabled.
Result: if hero has a live Commander, Commander gains bonus from Power Stone.
Result: if hero has a dead or no Commander, Option to destroy Power Stone or lea
ve it.
iii) Non-WoGified WoG Map with Commanders disabled by ERM (!#UN:P3/1;).
Result: Power Stones act as more valuable treasure chests (up to 7500 gold/7000
exp.).
3) New UN Receiver command to control a map's hero level limit: !!UN:J1/$1/$2;
Set/check/get a hero level limit for a map.
Syntax:
!!UN:J1/$1/$2;
$1 is a level limit (you can set/check/get it)
$2 is an XP amount for this level
Comments:
Whenever you set or get the level value, the XP amount is always for the curre
nt level limit. So if you set the level, it will return an XP for this new just
set level. So to set and meanwhile get the level and level XP, you can use one c
ommand:
!!UN:J1/35/?y10;
Here you set the level to 35 and get an experience for this level to y10.
4) New UN Receiver command to control player map difficulty: !!UN:J2/$;
Set, check or get a player difficulty level.
Syntax:
!!UN:J2/$;
Set, check or get a difficulty level chosen by player.
If you set the level it may not always keep its value later so use with cautio
n.
5) New UN Receiver command to load a WoGifications setting data file: !!UN:J3/^f
ile^;
Lets you load an external file with WoGification settings.
With this command you can customize the way a map is wogified. The loaded sett
ing will override the settings in the WoG Options screen.
Syntax:
!#UN:J3/^the path to the file^;
The path may have a folders in relative or absolute path (based on
the WoG folder), like this:
^MyOptions.xxx^ - a file in the Heroes home folder
^maps\opt.yyy^ - a file in the maps folder
^.\maps\opt.yyy^ - the same as above ("." means the current folder)
^C:\xxx.yyy^ - a file in the C: root folder
^..\mysets\set001.zzz^ - a file in mysets folder that is a child
folder for the parent folder for the heroes home folder (clear? :-)
6) New UN Receiver command to control AI "thinking" radius: !!UN:J4/$;
ERM command to set AI "thinking" radius:
!!UN:J4/$; set/get/check the radius
$ = 32000 is a SoD default
= 4096 is a current WoG default
This is not a number of squares to analyze, but is the total range of an AI he
ro based on its movement points and the terrain. For grass, one square of distan
ce is about 100 points.
This is not saved in the saved game.
You can change this value at any moment, for example, making one AI player or
even a specific hero more clever than another.
Caution: if this value is set too low, an AI hero may just sit there and not m
ove at all.
7) New UN Receiver command for to disable Autosave: !!UN:J5/$;
Disable Autosave.
!!UN:J5/$;
$ = 1 enable autosave
$ = 0 disable autosave
Comments:
The state of disabling won't be saved in a save game file, so if you need auto
save to remain disabled, you should also put this command after a Load Game trig
ger (!?GM0).
In most cases it isn't advisable to disable the autosave, because the autosave
provides an important backup for the player in case anything goes wrong.
8) New UN Receiver command to generate a random artifact: !!UN:J6/#/$;
!!UN:J6/#/$; generate a random artifact of a specific level.
# - (set) artifact level (-1=random, 1=no class, 2=treasure, 4=minor, 8=major,
16=relic)
$ - (get/check) random artifact of a level
Comments:
This function returns only enabled artifacts. Artifact level 1 includes The Gr
ail, Spell Book, Spell Scroll, and all War Machines.
Example:
!!UN:J6/2/?v10; - get a random Treasure artifact to v10
You can add level numbers together to cover several classes. e.g., 18=treasure
& relic.
If you generate more than one random artifact number from the same trigger, th
e artifact numbers will be unique, so you can be assured of getting a selection
of different artifacts without duplicates.
9) New UN Receiver command to control a town's Artifact Merchant: !!UN:J7/#/$;
Check/Get/Set Artifact Merchant's artifact
!!UN:J7/#/$;
# - slot index (0...6)
$ - artifact in the slot
Comments:
You may use set, get or check syntax.
-1 means no artifact.
Example:
!!UN:J7/3/?v10; - get artifact in slot 3
!!UN:j7/v5/v20; - set artifact in slot v5 to v20
10) New UN Receiver command to check if a file exists: !!UN:J8/$1/$2; or !!UN:J8
/$1/^text^;
!!UN:J8/$1/$2; or !!UN:J8/$1/^text^;
Checks whether a file exists.
$1 - modifier
$2 - index of z var (local, standard or extended from ERT)
z[$2] or ^text^ - a file name (with possible path)
Return:
Flag 1 set to 1 if file exists otherwise 0.
Modifiers:
0 - location is in Heroes home folder
1 - in DATA folder
2 - in MAPS folder
3 - in RANDOM_MAPS folder
4 - in GAMES folder
5 - in DATA\S folder
6 - in DATA\P folder
7 - in DATA\ZVS\LIB1.RES folder
8 - in DATA\ZVS\CMP.RES folder
9 - in ERM_HELP folder
The main purpose of the modifier is to not worry about path. For example, you
have a picture in a script folder. Now this is DATA\S but later we can transfer
them to other folder. Using the modifier you need not know exactly where the scr
ipt folder is located, you just need to use a modifier 5.
Example:
UN:J8/1/^mypic.bmp^ - checks for ..\DATA\mypic.bmp
UN:J8/1/^P\mypic.bmp^ - checks for ..\DATA\P\mypic.bmp
UN:J8/2/^mypic.bmp^ - checks for ..\MAPS\mypic.bmp
Modifier 10 - an absolute path. With this modifier, the file name is the exact n
ame with possible path.
Example. If the modifier is 10 and the name is "Hello.txt", the file will be s
earched for in the current folder. Current folder for Heroes is most probably a
Heroes home folder. If the name is "C:\Hello.txt", the file will be searched for
in the root of disk C:
11) New UN Receiver command to get a path for a file: !!UN:J9/$1/$2;
This command gets Heroes 3 paths so you can create a full path for a file if y
ou need, taking into account a particular player's Heroes folder location.
!!UN:J9/$1/$2;
The command gets a corresponding path to a z variable.
$1 - modifier (the same as for UN:J8)
$2 - index of z var (local or standard)
Example:
It copies an absolute path to the z variable. Say we have heroes installed to
C:\HOMM\WOG, the command UN:J9/2/10 will copy to z[10] the next path: "C:\HOMM\W
OG\". You can just add a name of file you want to use and then use it in any way
you want.
12) New UN Receiver command to output variables to WOGERMLOG.TXT: !!UN:J10;
Use UN:J10 command at any time (writes all non-zero variables to a file).
The log will be stored in WOGERMLOG.TXT.
13) New UN Receiver command to write z variables to an external file: !!UN:N5/#1
/#2/#3/#4;
Write z variable to wog.ini file [common] section:
!!UN:N5/#1/#2/#3/#4; - save z string to wog.ini file
#1 - z var index of string to write string data from
#2 - option index (any positive value)
#3 - (optional parameter) z var index of user-defined section to use instead o
f [common]
#4 - (optional parameter) z var index that keeps the filename (without ".INI"
part) with possible path. Note: if you include parameter 4, you must also includ
e parameter 3.
14) New UN Receiver command to read z variables from an external file: !!UN:N6/#
1/#2/#3/#4;
Read z variable from wog.ini file [common] section:
!!UN:N6/#1/#2/#3/#4; - load z string from wog.ini file
#1 - z var index of string to load string data into
#2 - option index (any positive value)
#3 - (optional parameter) z var index of user-defined section to use instead o
f [common]
#4 - (optional parameter) z var index that keeps the filename (without ".INI"
part) with possible path. Note: if you include parameter 4, you must also includ
e parameter 3.
Comments:
You may save and load regular or local z variables.
Option index should be unique to a save/load procedure (one option number per z
variable).
So if you save a z var as an option 123456, you need to load the saved value (
to any other z var) using the same option 123456.
The value is not stored in a saved game but is stored in an external INI file
(wog.ini, if parameter 4 is omitted). You may use these commands without problem
in instructions.
So to store a variable z-1 named "The_Main_Var" in a file "My.var" in GAMES fo
lder (section "MyLocalSettings"), with option index 4, use:
!!VRy1:S4;
!!VRz-1:S^The_Main_Var^;
!!VRz-2:S^MyLocalSettings^;
!!VRz-3:S^GAMES\My.var^;
!!UN:N5/z-1/y1/-2/-3;
15) Extended UN:P command for setting new hard-coded WoG Options: P9, P10, P900.
.P906
i) !!UN:P9/$; Sylvan Centaur creation.
$=0 - Disabled
$=1 - Enabled
If enabled, Sylvan Centaurs can be created for free by control-clicking on a st
ack of Centaur Captains or Grand Elves in the Hero screen (does not work in any
other screen). An equal number from both stacks is replaced with Sylvan Centaurs
. Thus 10 Grand Elves plus 10 Centaur Captains equal 10 Sylvan Centaurs.
Note: Sylvan Centaurs start at 0 experience and do not keep any stack experience
that the Centaur Captains or Grand Elves had before combining.
ii) !!UN:P10/$; Troop Stacks left will rejoin their owner.
$=0 - Won't rejoin owner
$=1 - Will rejoin owner
If enabled, troop stacks left by right-clicking will rejoin their owner when th
ey're "attacked" by that player.
Note: all previous stack experience is lost when a troop stack is left by right
-clicking.
iii) !!UN:P900/$; Stack Experience.
$=0 - Disabled
$=1 - Enabled
If enabled, troop stacks lead by a hero gain experience if they win the battle.
Experience is equal to the experience the hero gains from the battle. When it g
ains enough experience, a troop stack will gain a rank and may gain bonuses to a
ttack, defense, damage, speed, health, and special abilities. If you combine two
experience stacks, their experience is averaged. Each stack can improve up to r
ank 10. Right-click on a stack's portrait in its info screen to see its current
stack experience details.
iv) !!UN:P901/$; Stack Experience System.
$=0 - Equal shares and each creature gains full experience.
$=1 - Weighted Shares: Lower level creatures gain more than higher level creat
ures.
$=2 - Weighted Shares: Higher level creatures gain more than lower level creat
ures.
$=3 - Equal shares: divided by all creatures.
Note: the stack experience system is currently tested with option 0 (the defaul
t). Other options were earlier attempts at finding the best system to use, but a
lthough rejected, they have been left in place in case anyone wishes to experime
nt with them anyway. If you do want to try another system (UN:P1..UN:P3), you'll
need to also set a higher experience multiplier using the EA:H command for huma
ns, and EA:A (possibly also EA:S and/or EA:T) for AI players since experience is
divided by all creatures in the battle and thus significantly lower.
v) !!UN:P902/$; Leave artifact on the map.
$=0 - Cannot leave artifacts.
$=1 - Can leave artifacts.
This lets you enable leaving of artifacts from a hero's backpack by right-clicki
ng on an empty map square. This is done in the same way that you leave troops.
You may use an old option 2 (may not leave troop) and a new 902 (may leave art
ifacts) together:
UN:P 2 | 902 |
----------------
0 | 0 | - may leave troops only.
0 | 1 | - may leave troops or artifacts.
1 | 0 | - may NOT leave anything.
1 | 1 | - may leave artifacts only.
vi) !!UN:P903/$; Disable cheat codes and cheat menu.
$=0 - cheating is enabled.
$=1 - cheating is disabled.
Disables the cheat codes and menu (if normally enabled). If the cheat menu is en
abled, it will still appear (even if disabled with this option), but clicking on
menu items has no effect.
Note: Although cheat codes do not normally work in multiplayer games, this optio
n will prevent players using the cheat codes and menu by loading saved games in
single player mode.
vii) !!UN:P904/$; and !!UN:P905/$; ERM Error Message Disabling.
$=0 - Error message shown as normal and P905 is set to 1 if an error occurs
$=1 - Error messages are disabled but P905 is set to 1 if an error occurs.
This is ERM Error message disabling feature.
If it is 1, all error messages are disabled, but if any error happens, option
905 will be set to 1.
If it is 0, the message will be shown as normal and option 905 will be set to
1.
Moreover, if the messages are disabled, the execution of the script will not b
e interrupted (the current trigger section). So you may use "risky" commands.
Example:
!?FU...
...
!!UN:P904/1 P905/0; disable error messages
!!HE-1:N?v99; get default hero index to v99
!!UN:P905/?i;
!!FU&i>0:E; leave if error
If you use a standard version:
!?FU...
...
!!HE-1:N?v99;
produces an error message if a default hero is undefined here.
viii) !!UN:P906/$; Disable gaining of stack experience.
$=0 - creatures may gain stack experience from battles (if P900=1).
$=1 - creatures may NOT gain stack experience from battles.
If you set it to 1 and the stack experience system is enabled, stacks will not
gain experience from battles, but you can still give stack experience with ERM.
16) Extended UN:Q command syntax to Win or Lose the game.
If you use a dummy second argument, it will Win or Lose the game using a diffe
rent function than before. So if you found any problems with the old function, t
ry with the new one instead.
Example:
!!UN:Q0/1; to lose (for current player)
!!UN:Q1/1; to win (for current player)
17) New UN Receiver command to redraw the town screen: !!UN:R4;
Syntax:
!!UN:R4; - Redraws town screen.
Comments:
This command must only be used while inside a town screen or it may crash the ga
me. It is primarily of use if a new visiting or garrison hero is added to a town
(with ERM while in the town screen), or if new troops are added to a visiting o
r garrison hero (again, with ERM while in the town screen).
18) New UN Receiver command to set the appearance of the mouse pointer: !!UN:R5/
$1/$2;
!!UN:R5/$1/$2; set mouse pointer appearance.
$1 - mouse pointer type (0..4)
$2 - mouse pointer subtype (0..[depends on type])
Comments:
Displaying any dialog restores the pointer to an arrow.
If you set a pointer to any shape, it will be restored to a default pointer if
you move it unless you disable pointer changing with the UN:R7 command.
19) New UN Receiver command to set a delay: !!UN:R6/$;
Delay command.
UN:R6/$; delay.
$ is a delay in mseconds (1000 is 1 second).
20) New UN Receiver command to control mouse pointer: !!UN:R7/$1/$2; or UN:R7/$1
;
Some more commands for mouse control.
!!UN:R7/$1/$2;
may be
!!UN:R7/$1;
$1 - show (0) / hide (1) mouse pointer
$2 - enable (0) / disable (1) later pointer changing
Comments:
When you visit some objects (like fishing well) when !?OB trigger works out, t
he mouse pointer IS disabled. So to be sure that when your long script works wit
h hourglass pointer, you may turn it ON manually.
Then if you disable pointer changing, it prevents the pointer from changing un
til:
- starting a new game;
- loading a game;
- any standard message appears (may be with ERM);
- any extended WoG dialog shown.
So for fishing well, it may be:
!!UN:R5/1/1; !!UN:R7/0/1;
then if you want to show a message or a question:
!!IF:M...
disable pointer changing again:
!!UN:R5/1/1; !!UN:R7/0/1;
until the end of the script where you can enable pointer changing again:
!!UN:R7/0/0;
21) New faster method for UN:U command.
Now if you use a search object syntax UN:Utype/subtype/index/varindex you can
set index to -1 or -2 (it was allowed to be 1...N before). A value of -1 means i
t will search for the next object of a type, using the coordinates of the previo
usly found object of the same type while a value of -2 means the same but it wil
l search for the previous object of a type on the map, starting from the last co
ordinates.
In the standard syntax (index=1...N), UN:U is searching for each object from t
he beginning of the map and skips them until the index object is found. Thus it
is a long process on larger maps, especially if there are a lot of objects of th
e specified type.
With the new syntax (index=-1 or index=-2) the coordinates returned in v[varin
dex]/v[varindex+1]/v[varindex+2] are used, and a search for an object of the typ
e specified starts from the next square on the map for -1 or the previous square
for -2, not from the beginning. This means that the process should be faster, b
ut it requires that you HAVE NOT CHANGED the returned coordinates of the previou
s search in V vars.
Moreover, for the first (or last) object you should use a standard syntax OR y
ou may set V[xcoord] var to -1 for the first object or -2 for the last object (s
ee examples below).
If you use -1 and -2 as an index of the object to find you may move forward and
backward from the current object. You may use them in any order.
Examples.
**********
It works fine
!!UN:U53/-1/1/1; (get location of mine 1: v1/v2/v3)
...
!!VRv1:S99; (change v1 to anything)
...
!!UN:U53/-1/2/1; (get location of mine 2: v1/v2/v3)
...
**********
It works WRONG!!! for v1 was modified
!!UN:U53/-1/1/1; (get location of mine 1: v1/v2/v3)
...
!!VRv1:S99; (change v1 to anything)
...
!!UN:U53/-1/-1/1; (get location of NEXT mine (2): v1/v2/v3)
...
**********
It works fine
!!UN:U53/-1/1/1; (get location of mine 1: v1/v2/v3)
... (v1/v2/v3 are NOT modified)
!!UN:U53/-1/-1/1; (get location of NEXT mine (2): v1/v2/v3)
... (v1/v2/v3 are NOT modified)
!!UN:U53/-1/-1/1; (get location of NEXT mine (3): v1/v2/v3)
...
**********
It works fine
!!VRv1:S-1; (start search from the first object on the map)
!!UN:U53/-1/-1/1; (get location of NEXT mine (1): v1/v2/v3)
... (v1/v2/v3 are NOT modified)
!!UN:U53/-1/-1/1; (get location of NEXT mine (2): v1/v2/v3)
... (v1/v2/v3 are NOT modified)
!!UN:U53/-1/-1/1; (get location of NEXT mine (3): v1/v2/v3)
...
To see a demonstration of how this syntax works, the following sample script may
be used with a randomly generated XL 2 levels SoD map. It runs through all Crea
ture banks in forward and then backward order.
script:
***************
ZVSE
!#TM1:S1/999/1/1; set TM1 for red
!?TM1;
!!UN:U16/-1/?v100;
!!VRv1:S-1;
!!IF:M^Found %V100 Creature Banks. Now run through all of them.^;
!!DO123/1/v100/1:P;
!!IF:M^Put Shroud.^;
!!UN:H72/72/0/1/100; Close for Red
!!UN:H72/72/1/1/100; Close for Red
!!VRv1:S-2;
!!IF:M^Now run in backward order.^;
!!DO124/1/v100/1:P;
!?FU123;
!!UN:U16/-1/-1/1;
!!UN:Sv1/v2/v3/0/3; Open for Red
!!UN:Lv1/v2/v3/100; Move a look for 100 ms
!?FU124;
!!UN:U16/-1/-2/1;
!!UN:Sv1/v2/v3/0/3; Open for Red
!!UN:Lv1/v2/v3/100; Move a look for 100 ms
***************
22) Extended UN:V command to see if a player used cheat codes.
Now you can check also whether the cheat menu is enabled or disabled and check i
f a player has tried to use cheat codes during the game.
!!UN:V?$1/?$2/$?3/?$4/?$5/?$6/?$7;
$6 =1 if cheat menu is enabled and =0 if disabled.
$7 =1 if the player used cheat codes till now, 0=no.
Comments:
1. You may not enable or disable the cheat menu to be SHOWN but you may check
it.
2. In multiplayer, neither cheat codes nor cheat menu works.
3. If you disable cheating, it works for keyboard codes and for cheat menu (ev
en if it is enabled).
NEW AND EXTENDED VR RECEIVER COMMANDS: M1, M2, M3, M4, M5, M6, U, V, R
1) New VR Receiver command to get a substring: !!VRz#:M1/z#1/#2/#3;
Get a substring.
!!VRz#:M1/z#1/#2/#3
Get a substring from z#1 and set it to z#.
z# - a variable that receives the result; may be standard or local z variable
.
z#1 - a variable that is a source; may be standard, local or extended z variab
le.
#2 - start position of z#1 string to copy (0 based).
#3 - length of substring to copy.
Example:
!!VRz1:S^NTV PLUS for Heroes!^;
!!VRz2:M1/z1/4/7;
In result we have z2 = "PLUS fo"
2) New VR Receiver command to get a token: !!VRz#:M2/z#1/#2;
Get a token.
!!VRz#:M2/z#1/#2
Get a specific token #2 from z#1 and set it to z#.
z# - a variable that receives the result; may be standard or local z variable
.
z#1 - a variable that is a source; may be standard, local or extended z variab
le.
#2 - a token number (0 based).
Comments:
Delimiters are: space, comma, dot, tabulator, new line.
Example:
For a string:
"A string.of ,,tokens
and some more tokens"
We have the next tokens:
0 -> "A"
1 -> "string"
2 -> "of"
3 -> "tokens"
4 -> "and"
5 -> "some"
6 -> "more"
7 -> "tokens"
3) New VR Receiver command for integer to string conversion: !!VRz#:M3/#1/#2;
Integer to alpha conversion.
!!VRz#:M3/#1/#2;
or
!!VRz#:M3/#1;
Convert a number to a string.
z# - a variable that receives the result; may be standard or local z variable
.
#1 - any number (or any numeric variable) to be converted.
#2 - radix; a base of a value (default is 10)
Examples:
!!VRz1:M3/123; -> z1="123"
!!VRz1:M3/123/10; -> z1="123" (the same as above)
!!VRz1:M3/-123; -> z1="-123"
!!VRz1:M3/127/16; -> z1="0x7F" (hexadecimal)
4) New VR Receiver command to get the length of a string: !!VR#:M4/$;
Get the length of a string.
!!VR#:M4/$;
# - z variable
$ - any numerical variable (to store the length)
Comment: Includes the full length, including leading and trailing spaces.
5) New VR Receiver command to get the first non-space position in a string: !!VR
#:M5/$;
Get the first non-space character position.
!!VR#:M5/$;
# - z variable
$ - any numerical variable (to store the position)
Comment: If there are no leading spaces, the position is 0. If the string is e
mpty, the position is -1.
6) New VR Receiver command to get the last non-space position in a string: !!VR#
:M6/$;
Get the last non-space character position.
!!VR#:M6/$;
# - z variable
$ - any numerical variable (to store the position)
Comment: If there are no trailing spaces, the position is the length of the st
ring -1. If the string is empty, the position is 0.
Example:
!!VRz10:S^ Abc def ^; [Assign text to string z10]
!!VRz10:M4/y5; [Get length to y5]
!!VRz10:M5/y6; [Get 1st non-space position to y6]
!!VRz10:M6/y7; [Get last non-space position to y7]
M4: y5 returns 12.
M5: y6 returns 2.
M6: y7 returns 8.
7) New VR Receiver command to search for a substring within a string: VRz#:U<sub
string>;
Format can be: !!VRz#1:Uz#2; or !!VRz#1:U^Text^;
Searches for the substring z#2 or ^Text^ within the z#1 string and sets Flag 1
to TRUE if there is such a substring, otherwise to FALSE.
Z var in both sides may be of any type (standard, local, ERT based). This mean
that this command may be easily ERTified.
Comments:
This uses a case insensitive algorithm, so "Sword" equals "sword" and "SwOrD".
It skips leading and trailing spaces (and new line characters), so " Hi ", "
hI" and " hi " all means just "HI" (all translated to upper case before sear
ching).
It does not skip any space or new line characters that are located inside of t
he text. So "Hi, it's me" and "Hi, it's me" are different.
Both strings are processed before search procedure is executed. So the text li
ke this "Hi,%Z5!" will become "Hi,Slava!" (if z5 is set to "Slava") before proce
ssing.
Example. Here you will have both messages "Yes!" and "Yes again!":
***********
ZVSE
!#VRz100:S^ Sword
^;
!#VRz200:S^
This_is the_sword text
^;
!#VRz200:Uz100;
!#IF&1:M^Yes!^;
!#VRz200:U^
sWorD
^;
!#IF&1:M^Yes again!^;
**********
8) New VR Receiver command for convert a string to a value: !!VR$:Vz#;
Convert string to value.
!!VR$:Vz#
Convert a string to an integer or floating point value
$ is any integer (f...t,v#,w#,x#,y#) or fl.(e) variable
z# - a var that is a source; may be standard, local or extended z
Comments.
You may use a ...e... syntax (engineering fl.p. format).
If value may not be converted it is set to 0.
Leading or trailing space characters are ignored.
Examples:
"123" -> 123
"+123" -> 123 (the same as above)
"-123" -> -123
".325" -> 0.325
"-1.25e+1" -> -12.5 (-1.25 * 10^1)
9) Extended syntax for VR:R command: !!VR:R#/$;
VR:R#/$;
# - dummy parameter (is not used)
$ - random seed to set a random generator to a fixed sequence.
Comment:
If you are not sure that the random generator is in identical stage at both PC
s, you may just reset it to an identical seed and then generate a number.
--------------------------------------------------------------------------------
------------
New Objects (to update Format OB and various sub-formats as appropriate):
Snow objects:
- Learning Stone (type 100, subtype 1)
- Idol (t:38, s:1)
- Library (t:41, s:1)
- Witch hut (t:113, s:1)
- Subter. Entrance (t:103, s:1)
- Knowledge Tree (t:102, s:0) I think I need to change it to s:1
- Tavern (t:95, s:1)
Ghost on the map (t:54, s:159)
Moon Portal (t:63, s66) - Add to WoG Objects page - used by "Mirror of the Home-
Way Script"
New cave (t:63, s:67) - Add to WoG Objects page
"Mithril" Mine (t:63, s:68)
Six land whirlpools (t:63, s:69-74)
--------------------------------------------------------------------------------
---------------
FORMAT LISTS
UPDATED FORMATS:
1) New 3.58 Artifacts to update Format A and Format A1:
156 Warlord's Banner
157 Crimson Shield of Retribution
158 Barbarian Lord's Axe of Ferocity
159 Dragonheart
160 Gate Key
161 Blank Helmet
162 Blank Sword
163 Blank Shield
164 Blank Horned Ring
165 Blank Gemmed Ring
166 Blank Neck Broach
167 Blank Armor
168 Blank Surcoat
169 Blank Boots
170 Blank Horn
2) New Creatures to update Format C:
192 Sylvan Centaur
193 Sorceress
194 Werewolf
195 Hell Steed
196 Dracolich
3) New Dwellings (Creature Generators) to update Format CG:
96 Sylvan Homestead
97 Enchanted Tower
98 Howling Hollow
99 Hellfire Rift
100 Dragon Graveyard
NEW FORMATS:
1)
Format AC
Combat Animations for BM:V command
0 Prayer
1 Lightning
2 Air Shield
3 Magic Mirror
4 Regeneration (Darker)
5 Anti-Magic
6 Blind
7 Counterstrike
8 Death Ripple
9 Inferno
10 Implosion
11 Fire Shield
12 Armageddon (small square area, always upper-left of screen about 5x5 hexes
but only 3x3.5 are on the actual hex grid)
13 Disrupting Ray while flying (wavy lines near attacking hero)
14 Disrupting Ray hitting target
15 Fear
16 Meteor Shower
17 Frenzy
18 Fortune/Good Luck
19 Slow
20 Mirth/Good Morale
21 Hypnotize
22 Protection from Air
23 Protection from Water
24 Protection from Fire
25 Precision
26 Protection from Earth
27 Shield
28 Slayer
29 Destroy Undead
30 Sorrow/Bad Morale
31 Haste
32 Force Field (small)
33 Force Field (large)
34 Remove Obstacle
35 Berserk
36 Bless
37 Lightning bolt (from above)
38 Lightning hitting target
39 Cure
40 Curse
41 Dispel
42 Forgetfulness
43 Fire Wall appearing (small) (yellow flash next to hero)
44 Fire Wall appearing (large) (larger yellow flash next to hero)
45 Frost Ring
46 Ice Bolt hitting target
47 Land Mine Appearing (on hero's head)
48 Misfortune/Bad Luck
49 Lightning hitting target
50 First Aid Tent Healing/Animate Dead/Resurrection (Lighter)
51 Sacrifice
52 First Aid Tent Healing/Animate Dead/Resurrection (Lighter)
53 Fireball
54 Stone Skin
55 Quicksand appearing (small dirty cloud patch over hero's head)
56 Weakness/Acid Breath
57 Land Mine
58 Quicksand disappearing (small dirty cloud patch over hero's head)
59 Land Mine Appearing (on hero's head)
60 Forcefield (briefly appearing by hero)
61 Larger Forcefield (briefly appearing by hero)
62 Fire Wall appearing (small) (yellow flash next to hero)
63 Fire Wall appearing (large) (larger yellow flash next to hero)
64 Magic Arrow hitting target
65 Fire Wall appearing (small) (yellow flash next to hero)
66 Fire Wall appearing (small) (yellow flash next to hero)
67 Poison
68 Bind
69 Disease
70 Paralyze
71 Aging
72 Death Cloud (in middle of battlefield)
73 Death Strike
74 First Aid Healing/Ghost Regeneration
75 Mana Absorption
76 Mana Given to a Hero
77 Mana Drain (Wraiths)
78 Magic Resistance
79 Healing/Animate/Resurrection (Darker)
80 Death Stare
81 Weakness/Acid Breath
82 Small explosion, similar to Land Mine but weaker
83 Ghost Gaining Life force
84 Commanders' Block ability
2)
Format HS
Hero specialty pics as used by UN:G2/#1/3/#3
with #3 being one of the following:
ACCORDING TO STANDARD HEROES
0 - Archery (Orrin)
1 - Archer (Valeska)
2 - Griffin (Edric)
3 - Navigation (Sylvia)
4 - Estates (Lord Haart)
5 - Swordsman (Sorsha)
... [all correct according to hero numbers]
143 - 350 Gold (Grindan)
EXTENSION HEROES
144 - Speed (Sir Mullich)
145 - Expert Fire Magic (Adrienne)
146 - Swordsman (Catherine)
147 - Enchanter (Dracon)
148 - Sharpshooter (Gelu)
149 - Ancient Behemoth (Kilgor)
150 - Black Knights (Lord Haart)
151 - Dragon head (Mutare's spec redesigned)
152 - Swordsman (Roland)
153 - Dragon head (Mutare Drake's spec redesigned)
154 - Ogre (Boragus)
155 - Devil (Xeron)
156 - Darkness (WoG Nagash)
157 - Rebuild (Wog Jeddite)
OTHER CREATURES
158 - Pikeman
159 - Halberdier
160 - Marksman
161 - Royal Griffin
162 - Zealot
163 - Crusader
164 - Champion
165 - Angel
166 - Arch Angel
167 - Centaur
168 - Centaur Captain
169 - Battle Dwarf
170 - Grand Elf
171 - Silver Pegasus
172 - Dendroid Soldier
173 - War Unicorn
174 - Green Dragon
175 - Gold Dragon
176 - Gremlin
177 - Master Gremlin
178 - Obsidian Gargoyle
179 - Iron Golem
180 - Archmage
181 - Master Genie
182 - Naga Queen
183 - Giant
184 - Titan
185 - Familiar
186 - Magog
187 - Cerberus
188 - Horned Demon
189 - Pit Lord
190 - Efreet Sultan
191 - Archdevil
192 - Skeleton Warrior
193 - Zombie
194 - Wraith
195 - Vampire Lord
196 - Power Lich
197 - Dread Knight
198 - Bone Dragon
199 - Ghost Dragon
200 - Infernal Troglodyte
201 - Harpy Hag
202 - Beholder
203 - Medusa
204 - Medusa Queen
205 - Minotaur King
206 - Scorpicore
207 - Red Dragon
208 - Black Dragon
209 - Hobgoblin
210 - Wolf Raider
211 - Orc Chieftain
212 - Ogre Mage
213 - Thunderbird
214 - Cyclops King
215 - Behemoth
216 - Gnoll Marauder
217 - Lizardman Warrior
218 - Dragon Fly
219 - Greater Basilisk
220 - Mighty Gorgon
221 - Wyvern Monarch
222 - Hydra
223 - Chaos Hydra
224 - Pixie
225 - Sprite
226 - Air Elemental
227 - Storm Elemental
228 - Ice Elemental
229 - Energy Elemental
230 - Magma Elemental
331 - Magic Elemental
232 - Firebird
233 - Phoenix
234 - Gold Golem
235 - Diamond Golem
236 - Azure Dragon
237 - Crystal Dragon (old Mutare's spec)
238 - Faerie Dragon
239 - Rust Dragon
240 - Halfling
241 - Peasant
242 - Boar
243 - Mummy
244 - Nomad
245 - Rogue
246 - Troll
247 - Catapult
248 - First Aid Tent
249 - Ammo Cart
250 - Supreme Archangel
251 - Diamond Dragon
252 - Lord of Thunder
253 - Antichrist
254 - Blood Dragon
255 - Darkness Dragon
256 - Ghost Behemoth
257 - Hell Hydra
258 - Sacred Phoenix
259 - Ghost
260 - Emissary of War
261 - Emissary of Peace
262 - Emissary of Mana
263 - Emissary of Lore
264 - Fire Messenger
265 - Earth Messenger
266 - Air Messenger
267 - Water Messenger
268 - Gorynych
269 - War zealot
270 - Arctic Sharpshooter
271 - Lava Sharpshooter
272 - Nightmare
273 - Santa Gremlin
274 - Paladin (Commander)
275 - Hierophant
276 - Temple Guardian
277 - Succubus
278 - Soul Eater
279 - Brute
280 - Ogre Leader
281 - Shaman
282 - Astral Spirit
283 - Sylvan Centaurs
284 - Sorceress
285 - Werewolf
286 - Hell Steed
NEW RESOURCES
287 - Wood
288 - Ore
289 - Wood + Ore
290 - Mithril
291 - Gems + Mercury + Crystal + Sulfur
NEW BASIC SKILLS
292 - Air Magic
293 - Artillery
294 - Ballistics
295 - Diplomacy
296 - Earth Magic
297 - Leadership
298 - Learning
299 - Luck
300 - Pathfinding
301 - Scholar
302 - Scouting
303 - Tactics
304 - Wisdom
305 - Water Magic
NEW SPELLS
306 - Protection from Air
307 - Air Shield
308 - Summon Air Elemental
309 - View Air
310 - Counterstrike
311 - Dimension Door
312 - Disguise
313 - Destroy Undead
314 - Fly
315 - Magic Arrow
316 - Magic Mirror
317 - Titan's Lightning
318 - Visions
319 - Anti-Magic
320 - Protection from Earth
321 - Earthquake
322 - Summon Earth Elemental
323 - Force Field
324 - Implosion
325 - Town Portal
326 - Quicksand
327 - Slow
328 - Sorrow
329 - Shield
330 - Armageddon
331 - Blind
332 - Berserk
333 - Curse
334 - Protection from Fire
335 - Frenzy
336 - Fire Shield
337 - Summon Fire
338 - Bloodlust
339 - Landmine
340 - Misfortune
341 - Sacrifice
342 - Summon Boat
343 - Clone
344 - Dispel
345 - Forgetfulness
346 - Mirth
347 - Remove Obstacle
348 - Scuttle Boat
349 - Teleport
350 - Water Walk
351 - Protection from Water
352 - Summon Water Elemental
SPECIAL
353 - "Special"
354 - View Earth
355 - Dracolich
356 - (Sword with Tower) also at 713
--------- B E G I N N E W C Y C L E -------------
357 - Archery (Orrin, same as 0 and 714)
358 - Archer (Valeska, same as 1)
359 - Griffin (Edric)
360 - Navigation (Sylvia)
...
463 - Logistics (Dessa)
464 - Haste (?)
465 - Precision (Zubin)
...
500 - 350 Gold (Grindan)
501 - Speed (Sir Mullich)
502 - Expert Fire Magic (Adrienne)
503 - Swordsman (Catherine)
504 - Enchanter (Dracon)
...
3)
Format MP
List of MP3 music files:
// Towns 1..9
1="cstletown"
2="rampart"
3="towertown"
4="infernotown"
5="necrotown"
6="dungeon"
7="stronghold"
8="fortresstown"
9="elemtown"
// Terrain 10..18
10="dirt"
11="sand"
12="grass"
13="snow"
14="swamp"
15="rough"
16="underground"
17="lava"
18="water"
// Menus 19..20
19="mainmenuwog"
20="mainmenu"
// AI movement 21..23
21="aitheme0"
22="aitheme1"
23="aitheme2"
// AB Campaigns 24..29
24="bladeabcampaign"
25="bladedbcampaign"
26="bladedscampaign"
27="bladeflcampaign"
28="bladefwcampaign"
29="bladepfcampaign"
// Campaigns 30..40
30="campainmusic01"
31="campainmusic02"
32="campainmusic03"
33="campainmusic04"
34="campainmusic05"
35="campainmusic06"
36="campainmusic07"
37="campainmusic08"
38="campainmusic09"
39="campainmusic10"
40="campainmusic11"
// Combat 41..44
41="combat01"
42="combat02"
43="combat03"
44="combat04"
// Themes 45..48
45="eviltheme"
46="goodtheme"
47="neutraltheme"
48="secrettheme"
// Magic Garden Leprechaun 49
49="looplepr"
// Castle Battle Results 50..51
50="losecastle"
51="defend castle"
// Battle results 52..55
52="losecombat"
53="retreat battle"
54="surrender battle"
55="win battle"
// Scenario Completion 56..58
56="lose campaign"
57="ultimatelose"
58="win scenario"
//59...199 user defined
4)
Format PM
Mouse Pointers
Cursor Type
0 Default Cursors (See Format PM1 for subtype)
1 Adventure Map Cursors (See Format PM2 for subtype)
2 Combat Cursors (See Format PM3 for subtype)
3 Casting Spell in combat icon (Animated spellbook). Subtype number doesn't matt
er.
4 Artifact (See Format A for subtype)
5)
Format PM1
Default Pointers (Type 0)
0 Restore Default (to arrow).
1 Arrow Pointer
2 Busy/Wait (Hourglass)
6)
Format PM2
Adventure Map Pointers (Type 1)
0 Arrow Pointer
1 Busy/Wait (Hourglass)
2 Hero (Helmet)
3 Town
4 Horse
5 Attack (Sword)
6 Boat
7 Anchor
8 Hero Meeting (Double arrows)
9 Rearing Horse
10 Horse (2)
11 Attack (2)
12 Boat (2)
13 Anchor (2)
14 Hero Meeting (2)
15 Rearing Horse (2)
16 Horse (3)
17 Attack (3)
18 Boat (3)
19 Anchor (3)
20 Hero Meeting (3)
21 Rearing Horse (3)
22 Horse (4+)
23 Attack (4+)
24 Boat (4+)
25 Anchor (4+)
26 Hero Meeting (4+)
27 Rearing Horse (4+)
28 Boat
29 Boat (2)
30 Boat (3)
31 Boat (4+)
32 Map Scroll North (Arrow)
33 Map Scroll Northeast (Arrow)
34 Map Scroll East (Arrow)
35 Map Scroll Southeast (Arrow)
36 Map Scroll South (Arrow)
37 Map Scroll Southwest (Arrow)
38 Map Scroll West (Arrow)
39 Map Scroll Northwest (Arrow)
40 Arrow Pointer
41 Dimension Door
42 Scuttle Boat
6)
Format PM3
Combat Pointers (Type 2)
0 Null/Not Allowed
1 Move
2 Fly
3 Shooting (Arrow)
4 Hero (Helmet)
5 Question Mark
6 Arrow Pointer
7 Attack Northeast (Sword)
8 Attack East (Sword)
9 Attack Southeast (Sword)
10 Attack Southwest (Sword)
11 Attack West (Sword)
12 Attack Northwest (Sword)
13 Attack North (Sword)
14 Attack South (Sword)
15 Half Damage (Broken Arrow)
16 Attack Wall (Catapult)
17 Heal
18 Sacrifice
19 Teleport
7)
Format SE1
Stack Experience
Ability Table ($3 for EA:B command)
A Attack: 65
B Block: 66
C Reduce Casting Cost: 67
D Defense: 68
E Death Stare: 69
F Fear: 70
G Santa Gremlin Guards: 71
H Health: 72
L Deflect: 76
M Maximum Damage: 77
O Number of Shots (Ammo): 79
P Number of Spells (Castings): 80
R Retaliations: 82
U Multiple Summon: 85
W Magic Resistance: 87
a Cast Spell After Attack: 97
b Reduce Target Defense: 98
c Cast Non-Direct Damage Spell After Attack: 99
d Defending Bonus: 100
e Double Damage Death Blow: 101
f Flagged Abilities: 102
g Golem Style Damage Resistance: 103
h Hatred Damage: 104
i No Range Penalty: 105
l Summon Clone: 108
m Minimum Damage: 109
o No Obstacle Penalty: 111
p Cast Spell Before Attack: 112
r Regeneration: 114
s Enchant with Spell: 115
u Single Summon: 117
w Spell Immunity: 119
8)
Format SE2
Stack Experience
Flagged Abilities ($4 for EA:B command when $3=102 (f))
1 King 1: 49
2 King 2: 50
3 King 3: 51
A Attack All Around: 65
B Breath (2-hex): 66
D Double Strike: 68
E No Melee Penalty: 69
F Fly: 70
G Dragon Nature: 71
I Immune to Fire: 73
L Alive: 76
M No Morale: 77
P Immune to Mind Spells: 80
R No Retaliation: 82
S Shoot: 83
U Undead: 85
b Strike & Return: 98
c Champion Charge: 99
f Fearless: 102
m Always Positive Morale: 109
r Rebirth: 114
s Shoot when Adjacent: 115
u Unicorn Aura of Resistance: 117
9)
Format SE3
Stack Experience
Non-Direct Damage Spells ($4 for EA:B command when $3=99 (c))
Age: 75
Acid Breath: 80
Berserk: 59
Blind: 62
Curse: 42
Disease: 73
Dispel Beneficial Spells: 78
Disrupting Ray: 47
Forgetfulness: 61
Hypnotize: 60
Misfortune: 52
Poison: 71
Slow: 54
Sorrow: 50
Weakness: 45
10)
Format SE4
Stack Experience
Spell Immunities ($4 for EA:B command when $3=119 (w))
1 Level 1 Hostile Spells: 49
2 Level 1-2 Hostile Spells: 50
3 Level 1-3 Hostile Spells: 51
4 Level 1-4 Hostile Spells: 52
5 All Hostile Spells: 53
6 All Level 1 Spells: 54
7 All Level 1-2 Spells: 55
8 All Level 1-3 Spells: 56
9 All Level 1-4 Spells: 57
: All Spells: 58
B Blind: 66
C Cold spells: 67
D Direct Damage spells: 68
H Hypnotize: 72
I Implosion: 73
K Berserk: 75
L Lightning Spells: 76
M Meteor Shower: 77
N Dispel Beneficial Spells: 78
O Fire Damage spells: 79
P Any Dispel: 80
R Armageddon: 82
S Slow: 83
A Hostile Air Spells: 65
E Hostile Earth Spells: 69
F Hostile Fire Spells: 70
W Hostile Water Spells: 87
a All Air Spells: 97
e All Earth Spells: 101
f All Fire Spells: 102
m Hostile Mind Spells: 109
p Hostile Dispel: 112
w All Water Spells: 119
11)
Format SE5
Stack Experience
Standard Modifiers ($4 for EA:B Command)
+ Add: 43
= Set: 61
% Percent: 37
12)
Format SN
In-game Sound List:
- Start of new day: newday.wav
- Start of new week: newweek.wav
- Start of new month: newmonth.wav
- Treasure chest, Sea Chest: chest.wav
- Artifact: treasure.wav
- After picking up a chest, resource or artifact: randomly chooses from pickup01
.82M, pickup02.82M, pickup03.82M, pickup04.82M, pickup05.82M, pickup06.82M, or p
ickup07.82M
- Hero gains a level: nwherolv.82m
- Pandora's box, Den of Thieves, Black Market, Alter of Sacrifice, Sphinx, Aband
oned Mine, Obelisk, Skeleton (corpse), Pyramid or any "blank" WoG object: myster
y.wav
- Digging up the Grail: UltimateArtifact.wav
- After a monster stack flees, is killed or joins a hero: killfade.82M
- Dwelling, Refugee Camp, School of War, Garrison, Hill Fort: Military.wav
- Creature Bank (including Emissary buildings), Prison: Rogue.wav
- Star Axis, Learning Stone, University, Witch's Hut, Library of Enlightenment,
Scholar, Tree of Knowledge: gazebo.wav
- Sanctuary, Garden of Revelation: GetProtection.wav
- Idol of Fortune, Mystical Garden, Campfire: Expernce.wav
- Windmill, Water Wheel, Flotsam, Wagon, Lean To: genie.wav
- Marletto Tower, Mercenary Camp, Arena: Nomad.wav
- War Machine Factory, Trading Post, Stables, Shipyard, Bottle, Sign, Tavern: St
ore.wav
- School of Magic, Magic Well, Magic Spring: Faerie.wav
- Temple or Magic Shrine: Temple.wav
- Subterranean Gate, Border Guard, Border Gate, Keymaster's Tent, Quest Guard: C
avehead.wav
- Lighthouse, Eye of the Magi, Redwood Observatory, Pillar of Fire, Cartographer
, Cover of Darkness: Lighthouse.wav
- Dragon Utopia: Dragon.wav
- Quest Hut: Quest.wav
- Warrior's Tomb, Crypt: Graveyard.wav
- Rally Flag, Fountain of Youth, Watering Hole, Buoy: Morale.wav
- Mermaid, Swan Pond, Fountain of Fortune, Faerie Ring: Luck.wav
- Whirlpool, Sirens: Danger.wav
- Mine: flagmine.wav
- Casting View Air or View Earth: view.wav

Das könnte Ihnen auch gefallen