Added a HIGHLIGHT_UNIT macro for flashing units
...in the same way HIGHLIGHT_IMAGE does. Not to generally be used in mainline.
This commit is contained in:
parent
da800ee43c
commit
b3606b9ab6
1 changed files with 85 additions and 0 deletions
|
@ -43,6 +43,91 @@
|
|||
{CLEAR_VARIABLE FLOATING_TEXT_temp}
|
||||
#enddef
|
||||
|
||||
#define HIGHLIGHT_UNIT FILTER
|
||||
# Blinks the specified unit(s) a few times. Can be used to pinpoint an
|
||||
# important unit to the player.
|
||||
[store_unit]
|
||||
[filter]
|
||||
{FILTER}
|
||||
[/filter]
|
||||
|
||||
kill=no
|
||||
variable=HIGHLIGHT_UNIT_temp
|
||||
[/store_unit]
|
||||
|
||||
[scroll_to]
|
||||
x,y=$HIGHLIGHT_UNIT_temp[$i].x,$HIGHLIGHT_UNIT_temp[$i].y
|
||||
[/scroll_to]
|
||||
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[kill]
|
||||
x,y=$HIGHLIGHT_UNIT_temp[$i].x,$HIGHLIGHT_UNIT_temp[$i].y
|
||||
fire_event=no
|
||||
animate=no
|
||||
[/kill]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[unstore_unit]
|
||||
variable=HIGHLIGHT_UNIT_temp[$i]
|
||||
find_vacant=no
|
||||
[/unstore_unit]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[kill]
|
||||
x,y=$HIGHLIGHT_UNIT_temp[$i].x,$HIGHLIGHT_UNIT_temp[$i].y
|
||||
fire_event=no
|
||||
animate=no
|
||||
[/kill]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[unstore_unit]
|
||||
variable=HIGHLIGHT_UNIT_temp[$i]
|
||||
find_vacant=no
|
||||
[/unstore_unit]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[kill]
|
||||
x,y=$HIGHLIGHT_UNIT_temp[$i].x,$HIGHLIGHT_UNIT_temp[$i].y
|
||||
fire_event=no
|
||||
animate=no
|
||||
[/kill]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
{FOREACH HIGHLIGHT_UNIT_temp i}
|
||||
[unstore_unit]
|
||||
variable=HIGHLIGHT_UNIT_temp[$i]
|
||||
find_vacant=no
|
||||
[/unstore_unit]
|
||||
{NEXT i}
|
||||
[redraw][/redraw]
|
||||
[delay]
|
||||
time=300
|
||||
[/delay]
|
||||
|
||||
{CLEAR_VARIABLE HIGHLIGHT_UNIT_temp}
|
||||
#enddef
|
||||
|
||||
#define HIGHLIGHT_IMAGE X Y IMAGE BACKGROUND
|
||||
# Scrolls to the given location, blinks the given image in and out a few
|
||||
# times, and then leaves the image in place. Use this to pinpoint an
|
||||
|
|
Loading…
Add table
Reference in a new issue