#textdomain wesnoth-tsg # I'm putting The South Guard's common balancing macros in here. # This should make my WML a little more sane. Most of these # I've shamlessly pillaged from The Rise of Wesnoth, The Useful WML Fragments Wiki, # and the generous advice of the collected fora. #define CUSTOM_SG_FLAG flag=flag/SG-flag-[1~4].png:150 flag_icon=flag/SG-flag-icon.png #enddef #define INCREASE_INCOME SIDE AMOUNT [store_side] side={SIDE} variable=_increase_income_stored_side [/store_side] [modify_side] side={SIDE} income="$($_increase_income_stored_side.income + {AMOUNT})" [/modify_side] #enddef #define CAN_PASS_BARRIER X Y [object] silent=yes [filter] x,y={X},{Y} [/filter] [effect] apply_to=movement_costs replace=yes [movement_costs] impassable=1 [/movement_costs] [/effect] [effect] apply_to=defense replace=yes [defense] impassable=50 [/defense] [/effect] [/object] #enddef #define PLACE_BARRIER SCROLLX SCROLLY CASTERID ANIM DURATION MASKX MASKY MASK [scroll_to] x,y={SCROLLX},{SCROLLY} [/scroll_to] # Haven’t figured out how to make this working yet: http://forums.wesnoth.org/viewtopic.php?f=21&p=608089#p608089 #[animate_unit] # flag=recruiting # [filter] # id={CASTERID} # [/filter] #[/animate_unit] [delay] time=$({DURATION} * 2/3) accelerate=yes [/delay] [sound] name=lightning.ogg [/sound] [color_adjust] red,green,blue=100,100,100 [/color_adjust] [delay] time=$({DURATION} * 1/3) accelerate=yes [/delay] [color_adjust] red,green,blue=0,0,0 [/color_adjust] [terrain_mask] x,y={MASKX},{MASKY} border=yes mask={MASK} [/terrain_mask] [redraw] [/redraw] [delay] time=$({DURATION} * 2/3) accelerate=yes [/delay] #enddef