UNIVERSAL
BATTLE
PARAMETERS
(BU)
RECEIVER
During combat, you may check/set/get parameters on taken actions. These receivers may be used/called only in !?BG(!?BR) trigger section.
Note: Now a usage of !!BG, !!BM, !!BH, !!BU, !!BF in complete AI battle is controlled in the ERM interpreter and you will get the corresponding error message.
!!BU:XXXX; | Check/set/get some universal parameters of the battle |
OPTIONS
C?$; | Check if the battle has ended
(on this turn) $=1 if yes $=0 if not Comments: Command C may be called from the BG1 trigger section or later. |
D#/?$; | Get or check a dead monster stack to $ at position #. $ = number of dead monster -1 if not any monster stack at that position -2 if there is alive stack at that position |
E#/?$; |
Get or check the stack number to $ of a living monster at position #. Comments: This command may be used to determine which stack is at a given position on the battlefield when you only know the battlefield position. If no alive monster is at that position, a value of -1 will be returned for $ instead. |
G$;![]() |
GET/CHECK/SET
the special terrain type and terrain modifier in combat Command syntax: !!BU:G$ $ is type of terrain. (see format BI) 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. |
Mz$;![]() |
Add a message to the combat log Comments: This differs from MM:M in that MM:M just shows the message and does not add it to 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 action or whatever), but you can't actually replace the original text; it's going to show up regardless. |
O#/?$; | Get or check an obstacle flag to $ at position #. Bit mask: $=0 if there is NO obstacle at the position $&1 if there is a magic obstacle at the position $&2 if there is an obstacle at the position $&4 if quick sand obstacle (magic) $&8 if land mine obstacle (magic) |
R; | Redraw a battlefield after
taking some action Suggestion: do not use this command in !?BF trigger and before it. |
S#1/#2/#3/#4/#5/#6; | Summon a stack of monster on a battle field. #1 - Type of monster (See Format C) #2 - Number of monsters #3 - Position #4 - Side (0=left or 1=right) of owner #5 - Hero's slot number (-1 -no slot) #6 - Redraw (1) or not (0) Restrictions: 1. It must be correct position number 2. It must be free of other monsters and obstacles position. 3. There may be no more than 20 stacks on each side. |
T?$; | Check if the battle has a
Tactics phase $=1 if yes $=0 if no |
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. |
Grid of the battlefield