mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-17 02:43:26 +00:00
[filter_condition] in scenario 6b
This commit is contained in:
parent
965dfb4899
commit
ae0fca377d
@ -768,18 +768,16 @@
|
||||
id=Dwarf Conscript
|
||||
[/filter]
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[have_unit]
|
||||
id=Dwarf Sergeant
|
||||
[/have_unit]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "I love you, Sarge..."
|
||||
[/message]
|
||||
[/then]
|
||||
[/if]
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "I love you, Sarge..."
|
||||
[/message]
|
||||
[/event]
|
||||
|
||||
# Event 2.2: Wounded Troll
|
||||
@ -836,28 +834,26 @@
|
||||
id=Vengeful Dwarf
|
||||
[/filter]
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[have_unit]
|
||||
id=Grog
|
||||
[/have_unit]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
{VARIABLE saved_grog yes}
|
||||
{VARIABLE saved_grog yes}
|
||||
|
||||
[message]
|
||||
speaker=Grog
|
||||
message= _ "Thank you. Grog got lost and there were so many smelly dwarves. If you hadn’t come Grog would have been killed. Grog owes you his life."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Grog
|
||||
message= _ "Thank you. Grog got lost and there were so many smelly dwarves. If you hadn’t come Grog would have been killed. Grog owes you his life."
|
||||
[/message]
|
||||
|
||||
[modify_unit]
|
||||
[filter]
|
||||
id=Grog
|
||||
[/filter]
|
||||
side=1
|
||||
moves=5
|
||||
[/modify_unit]
|
||||
[/then]
|
||||
[/if]
|
||||
[modify_unit]
|
||||
[filter]
|
||||
id=Grog
|
||||
[/filter]
|
||||
side=1
|
||||
moves=5
|
||||
[/modify_unit]
|
||||
[/event]
|
||||
|
||||
# Event 3: Tunnel cave-ins
|
||||
@ -1120,21 +1116,19 @@
|
||||
id=Jorgi
|
||||
[/filter]
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[variable]
|
||||
name=bridge_blown
|
||||
numerical_equals=0
|
||||
[/variable]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
[message]
|
||||
speaker=Jorgi
|
||||
message= _ "I couldn’t do it. Blow the backup charges! If we can’t stop them then maybe the black lake will."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Jorgi
|
||||
message= _ "I couldn’t do it. Blow the backup charges! If we can’t stop them then maybe the black lake will."
|
||||
[/message]
|
||||
|
||||
{BACKUP_CHARGES}
|
||||
[/then]
|
||||
[/if]
|
||||
{BACKUP_CHARGES}
|
||||
[/event]
|
||||
|
||||
# if player crosses bridge before killing Jorgi, then blow charges
|
||||
@ -1149,21 +1143,19 @@
|
||||
side=1
|
||||
[/filter]
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[variable]
|
||||
name=bridge_blown
|
||||
numerical_equals=0
|
||||
[/variable]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
[message]
|
||||
speaker=Jorgi
|
||||
message= _ "They’ve crossed the chasm! Blow the backup charges! If we can’t stop them then maybe the black lake will."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Jorgi
|
||||
message= _ "They’ve crossed the chasm! Blow the backup charges! If we can’t stop them then maybe the black lake will."
|
||||
[/message]
|
||||
|
||||
{BACKUP_CHARGES}
|
||||
[/then]
|
||||
[/if]
|
||||
{BACKUP_CHARGES}
|
||||
[/event]
|
||||
|
||||
# Event 5: Vampire Bats
|
||||
@ -1420,7 +1412,7 @@
|
||||
name=new turn
|
||||
first_time_only=no
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[have_unit]
|
||||
x=27-30
|
||||
y=13-17
|
||||
@ -1430,44 +1422,42 @@
|
||||
name=tentacle_count
|
||||
less_than=3
|
||||
[/variable]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
{CREATE_TENTACLE}
|
||||
{CREATE_TENTACLE}
|
||||
{CREATE_TENTACLE}
|
||||
{CREATE_TENTACLE}
|
||||
#ifndef EASY
|
||||
{CREATE_TENTACLE}
|
||||
{CREATE_TENTACLE}
|
||||
#endif
|
||||
|
||||
#choose what message to say
|
||||
[if]
|
||||
[variable]
|
||||
name=tentacle_count
|
||||
numerical_equals=0
|
||||
[/variable]
|
||||
#choose what message to say
|
||||
[if]
|
||||
[variable]
|
||||
name=tentacle_count
|
||||
numerical_equals=0
|
||||
[/variable]
|
||||
|
||||
[then]
|
||||
[message]
|
||||
x,y=24-30,12-20
|
||||
side=1
|
||||
message= _ "What are those?!"
|
||||
[/message]
|
||||
[/then]
|
||||
|
||||
[else]
|
||||
[message]
|
||||
x,y=24-30,12-20
|
||||
side=1
|
||||
message= _ "Here come more of them!"
|
||||
[/message]
|
||||
[/else]
|
||||
[/if]
|
||||
|
||||
[set_variable]
|
||||
name=tentacle_count
|
||||
add=1
|
||||
[/set_variable]
|
||||
[then]
|
||||
[message]
|
||||
x,y=24-30,12-20
|
||||
side=1
|
||||
message= _ "What are those?!"
|
||||
[/message]
|
||||
[/then]
|
||||
|
||||
[else]
|
||||
[message]
|
||||
x,y=24-30,12-20
|
||||
side=1
|
||||
message= _ "Here come more of them!"
|
||||
[/message]
|
||||
[/else]
|
||||
[/if]
|
||||
|
||||
[set_variable]
|
||||
name=tentacle_count
|
||||
add=1
|
||||
[/set_variable]
|
||||
[/event]
|
||||
|
||||
#tentacle death counter
|
||||
@ -1941,85 +1931,77 @@
|
||||
[/not]
|
||||
[/filter]
|
||||
|
||||
[if]
|
||||
[filter_condition]
|
||||
[variable]
|
||||
name=took_belt
|
||||
numerical_equals=0
|
||||
[/variable]
|
||||
[/filter_condition]
|
||||
|
||||
[then]
|
||||
[message]
|
||||
speaker=unit
|
||||
[message]
|
||||
speaker=unit
|
||||
|
||||
message= _ "Based on the runes covering the walls this must be the tomb of some ancient dwarf. The tomb seems empty except for this ornate stone coffin. The skeleton inside the coffin has long since vanished into dust. All that’s left are a few ceremonial trinkets and this shining golden belt. Inscribed on this inside are the words: <i>“May you have the toughness to stay standing long after your enemies fall.”</i> Grave robbing is never a good thing to do, but this belt looks magical and its former owner certainly won’t miss it."
|
||||
[option]
|
||||
message= _ "I fear no ghosts, I’ll take it."
|
||||
[command]
|
||||
[set_variable]
|
||||
name=took_belt
|
||||
value=1
|
||||
[/set_variable]
|
||||
message= _ "Based on the runes covering the walls this must be the tomb of some ancient dwarf. The tomb seems empty except for this ornate stone coffin. The skeleton inside the coffin has long since vanished into dust. All that’s left are a few ceremonial trinkets and this shining golden belt. Inscribed on this inside are the words: <i>“May you have the toughness to stay standing long after your enemies fall.”</i> Grave robbing is never a good thing to do, but this belt looks magical and its former owner certainly won’t miss it."
|
||||
[option]
|
||||
message= _ "I fear no ghosts, I’ll take it."
|
||||
[command]
|
||||
[set_variable]
|
||||
name=took_belt
|
||||
value=1
|
||||
[/set_variable]
|
||||
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "The belt fits perfectly! Somehow I feel stronger and tougher. This is too easy, there seem to have been no traps set upon the coffin. Today’s my lucky day."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "The belt fits perfectly! Somehow I feel stronger and tougher. This is too easy, there seem to have been no traps set upon the coffin. Today’s my lucky day."
|
||||
[/message]
|
||||
|
||||
[object]
|
||||
[filter]
|
||||
x=49
|
||||
y=24
|
||||
side=1
|
||||
[/filter]
|
||||
[object]
|
||||
[filter]
|
||||
x=49
|
||||
y=24
|
||||
side=1
|
||||
[/filter]
|
||||
|
||||
id=DwarvenBelt
|
||||
name= _ "Dwarven Belt"
|
||||
description= _ "The maximum hit points of the unit who wears this belt will increase by 12."
|
||||
id=DwarvenBelt
|
||||
name= _ "Dwarven Belt"
|
||||
description= _ "The maximum hit points of the unit who wears this belt will increase by 12."
|
||||
|
||||
[effect]
|
||||
apply_to=hitpoints
|
||||
increase_total=12
|
||||
[/effect]
|
||||
[/object]
|
||||
[effect]
|
||||
apply_to=hitpoints
|
||||
increase_total=12
|
||||
[/effect]
|
||||
[/object]
|
||||
|
||||
{NAMED_NOTRAIT_UNIT 9 (Ghost) 47 22 (Angry Ghost) ( _ "Angry Ghost")}
|
||||
# wmllint: recognize Angry Ghost
|
||||
{NAMED_NOTRAIT_UNIT 9 (Ghost) 47 22 (Angry Ghost) ( _ "Angry Ghost")}
|
||||
# wmllint: recognize Angry Ghost
|
||||
|
||||
[message]
|
||||
speaker=Angry Ghost
|
||||
message= _ "You who disturb my rest, come and join me in death!"
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Angry Ghost
|
||||
message= _ "You who disturb my rest, come and join me in death!"
|
||||
[/message]
|
||||
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "Then again, maybe I spoke too soon."
|
||||
[/message]
|
||||
[/command]
|
||||
[/option]
|
||||
[message]
|
||||
speaker=unit
|
||||
message= _ "Then again, maybe I spoke too soon."
|
||||
[/message]
|
||||
[/command]
|
||||
[/option]
|
||||
|
||||
[option]
|
||||
message= _ "On second thought, it’s better to leave the dead in peace."
|
||||
[option]
|
||||
message= _ "On second thought, it’s better to leave the dead in peace."
|
||||
|
||||
[command]
|
||||
[allow_undo]
|
||||
[/allow_undo]
|
||||
[/command]
|
||||
[/option]
|
||||
[/message]
|
||||
[/then]
|
||||
|
||||
[else]
|
||||
[allow_undo]
|
||||
[/allow_undo]
|
||||
[/else]
|
||||
[/if]
|
||||
[command]
|
||||
[allow_undo]
|
||||
[/allow_undo]
|
||||
[/command]
|
||||
[/option]
|
||||
[/message]
|
||||
[/event]
|
||||
|
||||
#at victory, clear variables:
|
||||
[event]
|
||||
name=victory
|
||||
|
||||
{CLEAR_VARIABLE i}
|
||||
{CLEAR_VARIABLE bridge_blown}
|
||||
{CLEAR_VARIABLE tentacle_count}
|
||||
{CLEAR_VARIABLE tentacle_deaths}
|
||||
|
Loading…
x
Reference in New Issue
Block a user