Author: zookeeper
Date: Sun Oct 17 20:16:26 2010
New Revision: 47075
URL: http://svn.gna.org/viewcvs/wesnoth?rev=47075&view=rev
Log:
Made IF_ALLIED use [store_side] instead of [store_unit] and prevented the
condition from passing if neither side exists. Probably fixes the macro being
broken.
Modified:
trunk/data/core/macros/conditional-utils.cfg
Modified: trunk/data/core/macros/conditional-utils.cfg
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/data/core/macros/conditional-utils.cfg?rev=47075&r1=47074&r2=47075&view=diff
==============================================================================
--- trunk/data/core/macros/conditional-utils.cfg (original)
+++ trunk/data/core/macros/conditional-utils.cfg Sun Oct 17 20:16:26 2010
@@ -87,37 +87,31 @@
#! amount=-10
#! [/gold]
#! )}
- [store_unit]
- [filter]
- side={PLAYER1_SIDE}
- canrecruit=yes
- [/filter]
- variable=leader1
- mode=replace
- kill=no
- [/store_unit]
- [store_unit]
- [filter]
- side={PLAYER2_SIDE}
- canrecruit=yes
- [/filter]
- variable=leader2
- mode=replace
- kill=no
- [/store_unit]
+ [store_side]
+ side={PLAYER1_SIDE}
+ variable=player1_side
+ [/store_side]
+ [store_side]
+ side={PLAYER2_SIDE}
+ variable=player2_side
+ [/store_side]
[if]
[variable]
- name=leader1.team_name
- equals=$leader2.team_name
+ name=player1_side.team_name
+ not_equals=$empty
+ [/variable]
+ [variable]
+ name=player1_side.team_name
+ equals=$player2_side.team_name
[/variable]
[then]
{ACTION_WML}
[/then]
[/if]
[clear_variable]
- name=leader1
+ name=player1_side
[/clear_variable]
[clear_variable]
- name=leader2
+ name=player2_side
[/clear_variable]
#enddef
_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits