Unpetrify issue
Moderator: Forum Moderators
Forum rules
- Please use [code] BBCode tags in your posts for embedding WML snippets.
- To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
Unpetrify issue
Hi I have an [unpetrify] in a general healing ability, I suspect 114 has done something to stop the unpetrify working.. can anyone see a problem using unpetrify in this way please?
Code: Select all
#define ABILITY_HEALER
# included in an [abilities] clause
#summon ability relies on summon magus code
[heals]
value=25
id=morehealing
affect_allies=yes
affect_self=no
cumulative=yes
poison=cured
[affect_adjacent]
adjacent=n,ne,se,s,sw,nw
[/affect_adjacent]
[/heals]
[unpetrify][/unpetrify]
[dummy]
name="Healing"
description="Healing - the magus can heal by 25 hp, cure and unpetrify adjacent allies."
[/dummy]
#enddef
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)
Re: Unpetrify issue
[unpetrify] as dummy ability needs id to be useful.
Re: Unpetrify issue
Well from various threads it looks like [unpetrify] doesn't work as an ability and there are a few examples where event is used to set the unit status on adjacent instead of an ability, I have got the below working, but can't seem to restrict the unpetrify to friendly units only, eg an ememy wizard can unpetrify enamy units by standing next to them...
Code: Select all
#define UNPETRIFYFIX
[event]
name=turn refresh
first_time_only=no
[modify_unit]
[filter]
#only allow unpetrify own side unit
[store_unit]
[filter_side]
side=$side_number
[/filter_side]
[filter_adjacent]
role=Magus
[/filter_adjacent]
adjacent=n,ne,se,s,sw,nw
[filter_wml]
[status]
petrified=yes
[/status]
[/filter_wml]
#only allow unpetrify own side unit
[/store_unit]
[/filter]
[status]
petrified=no
[/status]
[/modify_unit]
[/event]
#enddef
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)
Re: Unpetrify issue
You have [store_unit].
Re: Unpetrify issue
thx I'll try removing store unit, perhaps it doesnt need this & can just filter on filter_side/side= etc.
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)
Re: Unpetrify issue
hm nopes mage can still unpetrify enemy units....
Have to try some other options...
Have to try some other options...
Code: Select all
#define UNPETRIFYFIX
[event]
name=turn refresh
first_time_only=no
[modify_unit]
[filter]
#only allow unpetrify own side unit
[filter_side]
side=$side_number
[/filter_side]
[filter_adjacent]
role=Magus
[/filter_adjacent]
adjacent=n,ne,se,s,sw,nw
[filter_wml]
[status]
petrified=yes
[/status]
[/filter_wml]
#only allow unpetrify own side unit
[/filter]
[status]
petrified=no
[/status]
[/modify_unit]
[/event]
#enddef
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)
Re: Unpetrify issue
hm this doesnt work either... utterly bizzare.. something so simple
Code: Select all
#define UNPETRIFYFIX
[event]
name=turn refresh
first_time_only=no
[unpetrify]
[filter_adjacent]
role=Magus
adjacent=n,ne,se,s,sw,nw
[/filter_adjacent]
[filter_side]
side=$side_number
[/filter_side]
[/unpetrify]
[/event]
#enddef
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)
Re: Unpetrify issue
Ok this works
Code: Select all
#define UNPETRIFYFIX
[event]
name=turn refresh
first_time_only=no
[unpetrify]
[filter_adjacent]
role=Magus
adjacent=n,ne,se,s,sw,nw
is_enemy=false
[/filter_adjacent]
[/unpetrify]
[/event]
#enddef
Maintainer of Conquest (Original Gameplay), Conquest+, Conquest+ Space/Ranged, Chaoz Battle of the Wizards, Lazersquad (squad game), WesCraft (building MP game)