wesnoth/data/campaigns/The_Deceivers_Gambit/scenarios/09_Omaranth.cfg
Dalas121 74da2a1724
TDG: add to schema, and fix schema issues (#9786)
While adding TDG to mainline, I missed adding it to the schema. As a result, a lot of issues went unnoticed.

This PR adds TDG to the schema, and fixes the various discovered errors. This PR also updates the schema to reflect the engine supporting multiple [filter] tags in events, and to reflect the engine supporting [change_theme] without keys.
2025-01-21 19:50:18 -06:00

1328 lines
53 KiB
INI
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#textdomain wesnoth-tdg
#
# this mission revolves around defending delfador's cave, while also destroying enough cave entrances that you don't get overwhelmed
# it's a lot easier if you have poachers from S08 - they're very strong vs the zombie drakes
#
# it's also your first mission without Delfador
#
[scenario]
id,map_file,name=09_Omaranth,09_Omaranth.map,_"Omaranth"
next_scenario,victory_when_enemies_defeated=10_Houses_of_the_Dead,no
{WINTER_SCHEDULE} turns=13
current_time=3
{SCENARIO_MUSIC weight_of_revenge.ogg}
{EXTRA_SCENARIO_MUSIC nunc_dimittis.ogg}
{ADD_WEATHER_SNOW}
{DE_TRACK {JOURNEY_09_NEW}}
#######################################################################################################################################################
# DEFINE SIDES
#######################################################################################################################################################
#############################
# DELFADOR
#############################
[side]
side,controller,color=1,human,red
id,defeat_condition,gold=Delfador,never,{ON_DIFFICULTY4 80 80 80 40}
team_name,user_team_name=wesnoth,_"Delfadors Hirelings"
fog=yes
{FLAG_VARIANT loyalist}
[/side]
#############################
# UNDEAD
#############################
[side]
side,controller,color=2,ai,white
no_leader,hidden,gold,income=yes,yes,0,-2
team_name,user_team_name=undead,_"Omaranths Flight"
{FLAG_VARIANT6 ragged}
[/side]
[event]
name=side 2 turn
first_time_only=no
{RESET_SIDE_AI 2 defensive 0.99 0.01}
{MODIFY_SIDE_AI 2 retreat_factor=0}
{MODIFY_SIDE_AI 2 ({GOAL_LOCATION 1 x,y=16,6})}
[/event]
#############################
# ANIMALS
#############################
[side]
side,controller,color=3,ai,green
no_leader,hidden,gold,income=yes,yes,0,-2
team_name,user_team_name=fauna,_"Fauna"
{FLAG_VARIANT6 ragged}
[/side]
#######################################################################################################################################################
# PREPARE MAP
#######################################################################################################################################################
[event]
name=prestart
#############################
# SCENERY
#############################
{PLACE_IMAGE scenery/cave-entrance2.png 17 1}
#define S09a_SCENERY DX DY
{PLACE_IMAGE scenery/village-human-burned3.png "$(20+{DX})" "$(8+{DY})"}
{PLACE_IMAGE "items/bones.png" "$(21+{DX})" "$(7+{DY})"}
{PLACE_IMAGE "items/bones.png" "$(14+{DX})" "$(6+{DY})"}
{PLACE_IMAGE "items/bones.png~FL()" "$(19+{DX})" "$(5+{DY})"}
{PLACE_IMAGE "items/bones.png~FL()" "$(18+{DX})" "$(8+{DY})"}
{PLACE_IMAGE "items/bones.png" "$(18+{DX})" "$(9+{DY})"}
{PLACE_IMAGE "items/bones.png~FL()" "$(19+{DX})" "$(9+{DY})"}
{PLACE_IMAGE "items/bones.png~FL()" "$(22+{DX})" "$(8+{DY})"}
[remove_event]
id=gold_pickup
[/remove_event]
{REMOVE_LABEL 0-99 0-99}
{IF} {VARIABLE_CONDITIONAL s09_gold_picked_up not_equals yes} {THEN(
{PLACE_IMAGE items/gold-coins-small.png "$(19+{DX})" "$(8+{DY})"}
{SET_LABEL "$(19+{DX})" "$(8+{DY})" _"{ON_DIFFICULTY4 60 60 60 30} gold"}
[event]
name=moveto
id=gold_pickup
{FILTER side,x,y=1,"$(19+{DX})","$(8+{DY})"}
[message]
speaker=Delfador
message=_"Whoever cleared this place out left behind some gold. Thats {ON_DIFFICULTY4 60 60 60 30} more for the treasury."
[/message]
{SOUND gold.ogg}
[gold]
side,amount=1,{ON_DIFFICULTY4 60 60 60 30}
[/gold]
{REMOVE_IMAGE $unit.x $unit.y}
{REMOVE_LABEL 0-99 0-99}
{VARIABLE s09_gold_picked_up yes}
[/event]
)} {/IF}
#enddef
{S09a_SCENERY 0 0}
#############################
# FAUNA
#############################
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "Dragonfly" "Dragonfly" "Grand Dragonfly" "Grand Dragonfly" } 12 18 ({GUARDIAN})}
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "none" "Dragonfly" "Dragonfly" "Dragonfly" } 25 14 ({GUARDIAN})}
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "none" "none" "Dragonfly" "Dragonfly" } 4 9 ({ROLE dflies}{ZONE_GUARDIAN 4 9 ( radius=5 {FILTER role=dflies} )}) }
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "none" "none" "Dragonfly" "Dragonfly" } 5 11 ({ROLE dflies}{ZONE_GUARDIAN 5 11 ( radius=5 {FILTER role=dflies} )}) }
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "Dragonfly" "Grand Dragonfly" "Grand Dragonfly" "Grand Dragonfly" } 10 11 ({ROLE dflies}{ZONE_GUARDIAN 10 11 ( radius=5 {FILTER role=dflies} )}) }
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "Icemonax" "none" "Great Icemonax" "Great Icemonax"} 8 2 ({ZONE_GUARDIAN 8 2 x,y=0-99,0-5}) }
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "Icemonax" "Icemonax" "Icemonax" "Icemonax" } 7 2 ({ZONE_GUARDIAN 7 2 x,y=0-99,0-5}) }
{GENERIC_UNITC 3 {ON_DIFFICULTY4 "Icemonax" "Great Icemonax" "Great Icemonax" "Great Icemonax"} 17 4 ({ZONE_GUARDIAN 17 4 x,y=0-99,0-5}) }
#############################
# DELFADOR
#############################
{RECALL_XY Delfador 26 20}
{RECALL_XY $saurian_guide_id 23 19}
{MODIFY_UNIT id=$saurian_guide_id canrecruit no}
{GIVE_OBJECT_TO id=$saurian_guide_id ({EFFECT overlay add=misc/leader-expendable.png})}
{SCROLL_TO 23 19}
[/event]
#######################################################################################################################################################
# PLAY SCENARIO
#######################################################################################################################################################
[event]
name=start
{DELAY 500}
{MOVE_UNIT id=Delfador 22 19} {DELAY 500}
{RECALL_COMPANION 25 20} {DELAY 500}
{RECALL_BANDIT 1 26 20 "Outlaw" ( {ADD_MODIFICATION {TRAIT_RESILIENT}} {ADD_MODIFICATION {TRAIT_STRONG}} {ANIMATE})}
{MODIFY_UNIT x,y=26,20 role escort1}{MODIFY_UNIT x,y=26,20 facing nw} # can't use {ROLE}/{FACING}, because we're recalling not creating
{DELAY 500}
{STORE_UNIT_VAR id=$saurian_guide_id name saurian_guide_name}
[message]
speaker=Delfador
#po: $saurian_guide_name is a female saurian name generated with the default Wesnoth name generator
message=_"What ails you, $saurian_guide_name? I have trusted you thus far a sign of good faith — please dont make me regret that decision."
[/message]
[message]
speaker=$saurian_guide_id
message=_"Oh Great One, the other Great One livesss in thessse cold mountain sssnowsss. But it is dangerousss! I am eldessst of my tribe... near sssixteen years of age. Age hasss made me weak; too weak to travel thessse landsss without help."
[/message]
[message]
speaker=$saurian_guide_id
message=_"But you are young! You are mighty! Your fire ssshall warm usss in the cold and protect usss from the dangersss! Together, yesss, together we ssshall reach the valley!"
[/message]
{SCROLL_TO 17 1}
[remove_shroud]
side,x,y,radius=1,13,2,1
[/remove_shroud]
{HIGHLIGHT_IMAGE 13 2 items/gohere.png ()}
{SCROLL_TO 22 19}
#############################
# OBJECTIVES
#############################
[objectives]
[objective]
#po: $saurian_guide_name will be a female saurian name generated with the default Wesnoth name generator
description= _ "Move $saurian_guide_name to the marked hex"
condition=win
[/objective]
[objective]
description= _ "Death of Delfador"
condition=lose
[/objective]
[objective]
#po: $saurian_guide_name will be a female saurian name generated with the default Wesnoth name generator
description= _ "Death of $saurian_guide_name"
condition=lose
[/objective]
{TURNS_RUN_OUT}
[gold_carryover]
carryover_percentage,bonus=40,yes
[/gold_carryover]
[note]
#po: $saurian_guide_name will be a female saurian name generated with the default Wesnoth name generator
description= _ "$saurian_guide_name will not follow you to the next scenario."
[/note]
[note]
description= _ "Amidst the craggy mountains, daylight is scarce. <i>(shorter days / longer nights)</i>"
[/note]
[/objectives]
{UNSTORE_SKILLS} # restore the skills we chose in S08
{RESELECT_SKILLS_AFTER_OBJECTIVES () ()}
[/event]
#############################
# EXPLAIN MATRIARCHY
#############################
[event]
name=die {FILTER side=3}
[event]
name=new turn
{FILTER_CONDITION( {NOT( {HAVE_UNIT( side=3 {FILTER_VISION side=1} )} )} )}
[message]
speaker=Delfador
message=_"$saurian_guide_name, could we not have brought augurs along on this journey? Ive mastered many forms of magic, but the light of a healer is beyond my reach."
[/message]
[message]
speaker=$saurian_guide_id
#po: the matriarch assumes both Delfador and the drake are female
message=_"Oh Great One, you know it isss forbidden! The malesss are not permitted! Only you and I; usss femalesss may look upon the other Great One; your sssister, our massster, our god!"
[/message]
[message]
speaker=Delfador
message=_"Us females? Err, yes, thats right."
[/message]
[/event]
[/event]
#############################
# BONES MESSAGE
#############################
[event]
name=moveto
{FILTER( side=1 {FILTER_LOCATION x,y,radius=18,6,5} )}
{FILTER_CONDITION( {HAVE_UNIT race=lizard} )}
[remove_shroud]
side,x,y,radius=1,19,8,3
[/remove_shroud]
{SCROLL_TO 19 8}
[message]
speaker=Delfador
scroll=no
message=_"So many bones! And they dont look human... Is such death all work of your great dragon?"
[/message]
[message]
speaker=$saurian_guide_id
#po: there were living drakes here only 20-30 years ago, but saurians have a very short lifespan.
message=_"No, this valley is cursssed... My grandmother usssed to sssay there were once many powerful creaturesss in thisss place, but they were ssslain long before I wasss hatched. Now only our Great One remainsss."
[/message]
[message]
speaker=$saurian_guide_id
message=_"But once you find her, then there ssshall be two! Together the Great Onesss will be unssstoppable!"
[/message]
[/event]
#############################
# MATRIARCH DIES
#############################
[event]
name=last breath
{FILTER id=$saurian_guide_id}
[message]
speaker=$saurian_guide_id
message=_"Oh Great One! Sssave me!"
[/message]
{KILL id=$saurian_guide_id ANIMATE=yes}
[endlevel]
result=defeat
[/endlevel]
[/event]
#############################
# TIME OVER
#############################
[event]
name=turn 10
{FILTER_CONDITION( {HAVE_UNIT race=lizard} )}
[message]
speaker=$saurian_guide_id
message=_"The sssnow, the windsss, it chillsss usss... Oh Great One, even with your warmth, we cannot ssstay here long!"
[/message]
[message]
speaker=Delfador
message=_"We must keep moving."
[/message]
[/event]
[event]
name=turn 12
{FILTER_CONDITION( {HAVE_UNIT race=lizard} )}
[message]
speaker=$saurian_guide_id
message=_"The cold chillsss me ssso! I cannot sssurvive much longer!"
[/message]
[/event]
[event]
name=time over
{FILTER_CONDITION( {HAVE_UNIT race=lizard} )}
[message]
speaker=$saurian_guide_id
message=_"Ssso... cccold... Oh Great One, I have failed you..."
[/message]
{KILL race=lizard ANIMATE=yes}
[endlevel]
result=defeat
[/endlevel]
[/event]
#############################
# PART 1 VICTORY
#############################
[event]
name=moveto
{FILTER id,x,y=$saurian_guide_id,13,2}
{MOVE_UNIT id=Delfador 12 2}
{MODIFY_UNIT id=Delfador,$saurian_guide_id facing nw}
{FIRE_EVENT skill_polymorph_stoat_cancel}
{FIRE_EVENT skill_polymorph_bear_cancel}
{FIRE_EVENT skill_polymorph_crab_cancel}
{FIRE_EVENT skill_polymorph_roc_cancel}
{FIRE_EVENT skill_levitate_cancel} # otherwise he dies when the map gets bigger and he ends up over mountain
{KILL side=3}
{FADE_MUSIC_OUT 500}
{REPLACE_SCENARIO_MUSIC silence.ogg}
{FADE_MUSIC_IN 100}
{FIRE_EVENT play_survival}
[/event]
#######################################################################################################################################################
# PART 2
#######################################################################################################################################################
[event]
name=play_survival
[heal_unit]
{FILTER side=1}
amount=full
moves=full
restore_attacks=yes
[/heal_unit]
#############################
# MATRIARCH FLEES
#############################
#define REDRAW
[redraw]
clear_shroud=yes
[/redraw]
#enddef
[message]
speaker=Delfador
message=_"Well?"
[/message]
[message]
speaker=$saurian_guide_id
message=_"Yesss, oh Great One, thisss is the place! Thisss is the lair of the other Great One, your sssister, our massster, our god!"
[/message]
{MOVE_UNIT id=$saurian_guide_id 13 2} {REDRAW}
{MOVE_UNIT id=Delfador 12 2} {REDRAW}
{MODIFY_UNIT id=Delfador,$saurian_guide_id facing nw}
[message]
speaker=$saurian_guide_id
message=_"Sssimply continue down the valley, and you ssshall meet your sssissster! I dare go no further. Oh massstersss, please forgive usss..."
[/message]
{MOVE_UNIT id=$saurian_guide_id 13 3} {REDRAW}
{MODIFY_UNIT id=Delfador facing se}
{MOVE_UNIT id=$saurian_guide_id 26 20} {REDRAW}
{KILL id=$saurian_guide_id}
{DELAY 500}
#############################
# CHANGE MAP
#############################
[replace_map]
map_file=09b_Omaranth.map
expand,shrink=yes,yes
[/replace_map]
{STORE_SKILLS}
{VARIABLE skill_fireball3 yes}
{FIRE_EVENT refresh_delfador_skills} # get rid of Delfador's familiar, if it exists
[store_time_of_day]
variable=s09_tod # to make the transition more seamless, start at the same ToD
[/store_time_of_day]
#############################
# CHANGE TIME
#############################
[modify_turns]
value,current=15,1
[/modify_turns]
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals dawn } {THEN( {VARIABLE current_time 0} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals morning } {THEN( {VARIABLE current_time 1} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals midday } {THEN( {VARIABLE current_time 1} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals afternoon } {THEN( {VARIABLE current_time 1} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals dusk } {THEN( {VARIABLE current_time 2} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals first_watch } {THEN( {VARIABLE current_time 3} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals midnight } {THEN( {VARIABLE current_time 4} )}
{/IF}
{IF} {VARIABLE_CONDITIONAL s09_tod.id equals second_watch} {THEN( {VARIABLE current_time 5} )}
{/IF}
[replace_schedule]
{WINTER_SCHEDULE}
current_time=$current_time
[/replace_schedule]
#############################
# SHIFT UNITS AND SCENERY
#############################
{REMOVE_IMAGE 0-99 0-99}
{S09a_SCENERY 14 16}
[store_unit]
{FILTER()}
variable=stored_s09a_units
[/store_unit]
[foreach]
array=stored_s09a_units
[do]{TELEPORT_UNIT id=$this_item.id "$($this_item.x+14)" "$($this_item.y+16)"}
[/do]
[/foreach]
{CLEAR_VARIABLE stored_s09a_units}
{MODIFY_UNIT side=1 facing nw} # otherwise teleport makes them all face se
[reset_fog]
{FILTER_SIDE side=1}
reset_view=yes
[/reset_fog]
{REDRAW}
#############################
# BONES AND KEEPS
#############################
{PLACE_IMAGE "items/bones.png" 16 7}
{PLACE_IMAGE "items/bones.png~FL()" 22 13}
{PLACE_IMAGE "items/bones.png" 23 15}
{PLACE_IMAGE "items/bones.png" 8 13}
{PLACE_IMAGE "items/bones.png~FL()" 7 16}
{PLACE_IMAGE "items/bones.png" 16 20}
{PLACE_IMAGE "items/bones.png" 29 10}
{PLACE_IMAGE scenery/dwarven-keep-tile.png 14 9}
{PLACE_IMAGE scenery/dwarven-keep-tile.png 18 15}
{PLACE_IMAGE scenery/dwarven-keep-tile.png 5 20}
{PLACE_IMAGE scenery/dwarven-keep-tile.png 26 8}
#############################
# CAVES
#############################
{PLACE_IMAGE scenery/cave-entrance1.png 16 6}
{PLACE_IMAGE scenery/cave-entrance2.png 9 6}
{PLACE_IMAGE scenery/cave-entrance3.png 4 8}
{PLACE_IMAGE scenery/cave-entrance4.png 3 15}
{PLACE_IMAGE scenery/cave-entrance3.png 11 17}
{PLACE_IMAGE scenery/cave-entrance4.png 8 19}
{PLACE_IMAGE scenery/cave-entrance2.png 14 19}
{PLACE_IMAGE scenery/cave-entrance2.png 31 17}
{PLACE_IMAGE scenery/cave-entrance4.png 30 13}
{PLACE_IMAGE scenery/cave-entrance2.png 24 2}
{PLACE_IMAGE scenery/cave-entrance4.png 29 4}
{PLACE_IMAGE scenery/cave-entrance2.png 31 7}
#############################
# DELFADOR BECOMES AFRAID
#############################
{MODIFY_UNIT id=Delfador facing nw}
[message]
speaker=Delfador
message=_"Hmmph. Whats she so afraid of; its just one measly dragon. Ill burn it to cinders and call myself Delfador Dragonsbane! The poets will sing my praises through the streets of Weldyn!"
[/message]
{DELAY 250}{MOVE_UNIT id=Delfador 23 15} {REDRAW} {DELAY 250}
[message]
speaker=Delfador
message=_"After all, the heroes of old used to slay dragons all the time, right?"
[/message]
{DELAY 500}{MOVE_UNIT id=Delfador 21 13} {REDRAW} {DELAY 500}
[message]
speaker=Delfador
message=_"Well, now that I think of it, I only remember reading about one single slain dragon..."
[/message]
{DELAY 750}{MOVE_UNIT id=Delfador 21 12} {REDRAW} {DELAY 750}
[message]
speaker=Delfador
message=_"And Prince Haldric did have a whole company of the Green Isles best knights to help..."
[/message]
{DELAY 2000}
[message]
speaker=Delfador
message=_"Uh oh."
[/message]
{DELAY 100}
{MOVE_UNIT id=Delfador 23 15}
#############################
# DRAKE APPEARS
#############################
{SOUND drake-hit-2.ogg}
{REVEAL x,y,radius=18,9,5}
[unit]
{SINGLEUNITWML_OMARANTH}
x,y,facing,animate=18,9,se,yes
[/unit]
{DELAY 250}
[message]
speaker=Omaranth
message=_"SOMETHING STIRRS.
A HUMAN COMES."
[/message]
{MODIFY_UNIT id=Delfador facing nw}
{DELAY 250}{QUAKE drake-die.ogg}{DELAY 750}
[message]
speaker=Omaranth
message=_"IT IS FEEBLE.
IT IS WEAK.
IT WILL DIE."
[/message]
[message]
speaker=Delfador
message=_"...wait a minute, thats not a dragon, its merely a drake! The saurians must have mistaken it for a true dragon on account of its fire breath."
[/message]
[message]
speaker=Delfador
message=_"So you are the villain behind all of this. Delfador Drake-Slayer isnt quite so catchy as Dragonsbane, but Ill take what I can get!"
[/message]
{MOVE_UNIT id=Delfador 19 10}
{MOVE_UNIT id=Omaranth 16 6}
[store_unit]
{FILTER id=Omaranth}
kill,variable=yes,stored_omaranth
[/store_unit]
[message]
speaker=Delfador
message=_"Hey, get back here!"
[/message]
{MOVE_UNIT id=Delfador 18 9}
{MODIFY_UNIT id=Delfador facing se}
[message]
speaker=Delfador
message=_"This drake is important — we cannot let it escape. My companions, I task you to guard this cave entrance while I chase the drake inside. When next you see me, Ill be holding the beasts scalp!"
[/message]
#############################
# DEPLOY INITIAL UNITS
#############################
{GET_COMPANION_ID}
{RECALL_COMPANION 20 10} # in case our previous companion died
{MODIFY_UNIT id=$companion_id canrecruit yes}
[set_extra_recruit]
id=$companion_id
extra_recruit={DELFADOR_BANDIT_RECRUIT}
[/set_extra_recruit]
{IF} {VARIABLE_CONDITIONAL poachers_were_recruited equals yes} {THEN(
[allow_extra_recruit]
id,extra_recruit=$companion_id,Poacher
[/allow_extra_recruit]
)} {/IF}
{MOVE_UNIT id=$companion_id 20 10} {REDRAW}
{IF} {HAVE_UNIT role=escort1} {THEN( {MOVE_UNIT role=escort1 22 10} )} {ELSE(
{RECALL_BANDIT 2 22 10 "Shadow Mage" ({ADD_MODIFICATION {TRAIT_STRONG}} {ADD_MODIFICATION {TRAIT_RESILIENT}} {ANIMATE})}
{MODIFY_UNIT x,y=22,10 role escort1}{MODIFY_UNIT x,y=22,10 facing sw} # can't use {ROLE}/{FACING}, because we're recalling not creating
)} {/IF}
{REDRAW}
{RECALL_BANDIT 1 20 11 "Footpad" ({ADD_MODIFICATION {TRAIT_STRONG}} {ADD_MODIFICATION {TRAIT_RESILIENT}} {ANIMATE})}
{MODIFY_UNIT x,y=20,11 role escort2}{MODIFY_UNIT x,y=20,11 facing sw} # can't use {ROLE}/{FACING}, because we're recalling not creating
{REDRAW}
[message]
speaker=$companion_id
message=_"You got it, boss. Well watch th cave entrance, an make sure you don get trapped inside."
[/message]
{MOVE_UNIT id=Delfador 16 6}
[store_unit]
{FILTER id=Delfador}
kill,variable=yes,stored_delfador
[/store_unit]
[message]
speaker=$companion_id
message=_"Sounds like a pretty easy job. All we gots to do is wait round ere for the boss to come back out."
[/message]
#############################
# OBJECTIVES
#############################
[objectives]
[objective]
description= _ "Relax. What could go wrong?"
condition=win
[/objective]
[gold_carryover]
carryover_percentage,bonus=40,yes
[/gold_carryover]
[note]
description= _ "Amidst the craggy mountains, daylight is scarce. <i>(shorter days / longer nights)</i>"
[/note]
[note]
description= _ "In this scenario $companion_name is your leader, and can recruit / recall."
[/note]
[/objectives]
#############################
# CREATE CAVES
#############################
#define INITIALIZE_CAVE ID X Y
{NAMED_UNIT 2 (Cave Entrance) {X} {Y} {ID} "" (
[modifications]
[object]
{EFFECT status add=unhealable}
[/object]
[/modifications]
)}
#------------------------
# STORE CAVE WHEN TRIGGERED
#------------------------
[event]
name,first_time_only=store_cave,no {FILTER id={ID}}
[store_unit]
{FILTER id={ID}}
kill,variable=yes,{ID}
[/store_unit]
#------------------------
# UNSTORE CAVE WHEN CLEAR
#------------------------
[event]
name=exit hex {FILTER x,y={X},{Y}}
[event]
name=enter hex # wait until after the unit finishes exiting, or we overwrite it
{FILTER_CONDITION( {VARIABLE_CONDITIONAL {ID}.length greater_than 0} )}
[unstore_unit]
variable={ID}
[/unstore_unit]
{CLEAR_VARIABLE {ID}}
[/event]
[/event]
[event]
name=die {FILTER( x,y={X},{Y} {NOT(type=Cave Entrance)} )}
{FILTER_CONDITION( {VARIABLE_CONDITIONAL {ID}.length greater_than 0} )}
[unstore_unit]
variable={ID}
[/unstore_unit]
{CLEAR_VARIABLE {ID}}
[/event]
[/event]
#------------------------
# COLLAPSE WHEN DESTROYED
#------------------------
[event]
name=die {FILTER id={ID}}
{QUAKE cave-in.ogg}
{QUAKE cave-in.ogg}
{REMOVE_IMAGE {X} {Y}}
{PLACE_IMAGE terrain/misc/rubble-water.png {X} {Y}}
{PLACE_IMAGE terrain/misc/detritus/detritusA-5.png {X} {Y}}
[/event]
#------------------------
# CAVE DEFENDERS
#------------------------
[event]
name=pre attack {FILTER_SECOND id,side={ID},2}
# spawn defenders in a fixed sequence, instead of random. Luckily/unluckily multiple empty caves (or multiple full caves) in a row can make a big difference, so prevent that
[set_variables]
name=defenders
[value]
type={ON_DIFFICULTY4 "none" "none" "Walking Corpse" "Walking Corpse"}
[/value]
[value]
type={ON_DIFFICULTY4 "none" "Walking Corpse" "Walking Corpse" "Walking Corpse"}
[/value]
[value]
type={ON_DIFFICULTY4 "none" "Walking Corpse" "Soulless" "Soulless" }
[/value]
[value]
type={ON_DIFFICULTY4 "none" "none" "none" "none" }
[/value]
[value]
type={ON_DIFFICULTY4 "none" "Walking Corpse" "Soulless" "Soulless" }
[/value]
[/set_variables]
{IF} {VARIABLE_CONDITIONAL next_defender equals $empty} {THEN(
{VARIABLE next_defender 0}
)} {ELSE(
{VARIABLE_OP next_defender add 1}
{VARIABLE_OP next_defender modulo $defenders.length}
)} {/IF}
{IF} {VARIABLE_CONDITIONAL defenders[$next_defender].type not_equals none} {THEN(
[fire_event]
name=store_cave
[primary_unit]
x,y,type={X},{Y},"Cave Entrance"
[/primary_unit]
[/fire_event]
{GENERIC_UNIT 2 $defenders[$next_defender].type {X} {Y}} {ANIMATE} {VARIATION drake}
{FIRE_EVENT explain_cave_defenders}
)} {/IF}
{CLEAR_VARIABLE defenders}
[/event]
#enddef
#------------------------
# CREATE CAVES
#------------------------
{INITIALIZE_CAVE cave00 16 6}
{MODIFY_UNIT id=cave00 side 1}
{GIVE_OBJECT_TO x,y=16,6 ({EFFECT overlay add=misc/hero-icon.png})}
{INITIALIZE_CAVE cave01 9 6}
{INITIALIZE_CAVE cave02 4 8}
{INITIALIZE_CAVE cave03 3 15}
{INITIALIZE_CAVE cave04 11 17}
{INITIALIZE_CAVE cave05 8 19}
{INITIALIZE_CAVE cave06 14 19}
{INITIALIZE_CAVE cave07 31 17}
{INITIALIZE_CAVE cave08 30 13}
{INITIALIZE_CAVE cave09 24 2}
{INITIALIZE_CAVE cave10 29 4}
{INITIALIZE_CAVE cave11 31 7}
[event]
name=explain_cave_defenders
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Look out! One o them was lurkin just inside the cave entrance!"
[/message]
[/event]
[event]
name=die
{FILTER side=2}
{FILTER_CONDITION( {NOT({HAVE_UNIT( side=2 )})} )}
{FILTER_CONDITION( {NOT({HAVE_UNIT( id=Delfador )})} )}
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Thats the last one o them, and with all the caves collapsed there wont be no more! Nothin left to do but wait for Delfador to come back out, and relax... for real this time. Great work everybody."
[/message]
{ACHIEVE s09}
[endlevel]
result=victory
{NEW_GOLD_CARRYOVER 40}
[/endlevel]
[/event]
#############################
# PREPARE CAVES AND CORPSES
#############################
# prevent caves from resting
{MODIFY_UNIT type="Cave Entrance" resting no}
#############################
# SPAWN UNITS FROM CAVES
#############################
# store each initial cave location
[store_locations]
{FILTER side,type=2,"Cave Entrance"}
variable=cave_locations
[/store_locations]
#------------------------
# DEFINE EMERGE MACROS
#------------------------
#define EMERGE TURN UNITS
[event]
name=side 2 turn {TURN}
{VARIABLES_SPLIT emerging_units type (,) {UNITS}}
[foreach]
array=emerging_units
[do]
[random_placement]
variable,num_items,allow_less=loc,1,yes
{FILTER_LOCATION( find_in=cave_locations {NOT({FILTER( {NOT(type=Cave Entrance)} )})} )} # pick a random cave_location, that doesn't already have a non-cave unit on it
[command]
# if there's not a cave at this location, skip spawning
# don't FILTER_LOCATION for caves, or else the spawn rate isn't reduced when caves get destroyed
{IF} {NOT({HAVE_UNIT x,y,type=$loc.x,$loc.y,"Cave Entrance"})} {THEN(
[continue]
[/continue]
)}{/IF}
{IF} {VARIABLE_CONDITIONAL this_item.type equals none} {THEN(
[continue]
[/continue]
)}{/IF}
# otherwise, store the cave and spawn the unit
[fire_event]
name=store_cave
[primary_unit]
x,y,type=$loc.x,$loc.y,"Cave Entrance"
[/primary_unit]
[/fire_event]
{GENERIC_UNIT 2 $this_item.type $loc.x $loc.y} {ANIMATE} {VARIATION drake}
# prevent new zombies/ghosts from moving very far on the first turn
{RANDOM "1..3"}
{MODIFY_UNIT x,y=$loc.x,$loc.y moves $random}
{CLEAR_VARIABLE moves}
[/command]
[/random_placement]
[/do]
[/foreach]
{CLEAR_VARIABLE emerging_units,this_item,cave}
[/event]
#enddef
#define EMERGE_CORPSE_TINY TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"none"
"Walking Corpse"
"Walking Corpse"
"Walking Corpse"
} )} #enddef
#define EMERGE_CORPSE_SMALL TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Walking Corpse"
"Walking Corpse"
"Soulless"
"Soulless"
} )} #enddef
#define EMERGE_CORPSE_MEDIUM TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Walking Corpse"
"Walking Corpse, Walking Corpse"
"Soulless, Walking Corpse, Walking Corpse"
"Soulless, Walking Corpse, Walking Corpse"
} )} #enddef
#define EMERGE_CORPSE_LARGE TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Soulless, Walking Corpse"
"Soulless, Walking Corpse, Walking Corpse, Walking Corpse"
"Soulless, Soulless, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse"
"Soulless, Soulless, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse"
} )} #enddef
#define EMERGE_CORPSE_HUGE TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Soulless, Walking Corpse, Walking Corpse"
"Soulless, Soulless, Soulless, Walking Corpse, Walking Corpse"
"Soulless, Soulless, Soulless, Soulless, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse"
"Soulless, Soulless, Soulless, Soulless, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse, Walking Corpse"
} )} #enddef
#define EMERGE_MIXED_MEDIUM TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Walking Corpse"
"Ghost, Walking Corpse"
"Ghost, Walking Corpse, Walking Corpse, Walking Corpse"
"Ghost, Walking Corpse, Walking Corpse, Walking Corpse"
} )} #enddef
#define EMERGE_MIXED_LARGE TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Ghost"
"Ghost, Walking Corpse, Walking Corpse"
"Ghost, Ghost, Walking Corpse, Walking Corpse"
"Ghost, Ghost, Walking Corpse, Walking Corpse"
} )} #enddef
#define EMERGE_MIXED_HUGE TURN
{EMERGE {TURN} ({ON_DIFFICULTY4
"Ghost, Walking Corpse"
"Ghost, Ghost, Soulless, Walking Corpse"
"Ghost, Ghost, Ghost, Soulless, Walking Corpse, Walking Corpse, Walking Corpse"
"Ghost, Ghost, Ghost, Soulless, Walking Corpse, Walking Corpse, Walking Corpse"
} )}
#enddef
#------------------------
# SPAWN UNITS EACH TURN
#------------------------
{EMERGE_CORPSE_MEDIUM 1} # initial emerge must have at least 1 corpse even on Easy, or else the messages don't make sense
{EMERGE_CORPSE_SMALL 2}
{EMERGE_CORPSE_SMALL 3}
{EMERGE_CORPSE_MEDIUM 4}
{EMERGE_CORPSE_MEDIUM 5}
{EMERGE_CORPSE_MEDIUM 6}
{EMERGE_MIXED_MEDIUM 7}
{EMERGE_MIXED_MEDIUM 8}
{EMERGE_CORPSE_LARGE 9} # remember that the player is expected to be collapsing caves, which prevents their spawns. Killing 50% of caves means only 50% of enemies spawn
{EMERGE_CORPSE_LARGE 10}
{EMERGE_MIXED_LARGE 11}
{EMERGE_MIXED_LARGE 12}
{EMERGE_CORPSE_HUGE 13}
{EMERGE_CORPSE_HUGE 14}
{EMERGE_MIXED_HUGE 15}
# {EMERGE_CORPSE_HUGE 16}
# {EMERGE_MIXED_HUGE 17}
# {EMERGE_MIXED_HUGE 18}
# {EMERGE_CORPSE_HUGE 19}
# {EMERGE_MIXED_HUGE 20}
# {EMERGE_MIXED_HUGE 21}
# {EMERGE_MIXED_HUGE 22}
# {EMERGE_CORPSE_HUGE 23}
# {EMERGE_CORPSE_HUGE 24}
# {EMERGE_MIXED_HUGE 25}
# {EMERGE_MIXED_HUGE 26}
# {EMERGE_MIXED_HUGE 27}
# {EMERGE_CORPSE_HUGE 28}
# {EMERGE_MIXED_HUGE 29}
# {EMERGE_CORPSE_HUGE 30}
# {EMERGE_CORPSE_HUGE 31}
# {EMERGE_CORPSE_HUGE 32}
# {EMERGE_MIXED_HUGE 33}
# {EMERGE_CORPSE_HUGE 34}
# {EMERGE_MIXED_HUGE 35}
#######################################################################################################################################################
# PART 2 EVENTS
#######################################################################################################################################################
#############################
# INITIAL UNDEAD CUTSCENE
#############################
[event]
name=side 1 turn end
{SOUND wind.ogg}
{DELAY 1000}
[message]
role=escort1
message=_"Brrr... Its suddenly so c-c-cold..."
[/message]
#############################
# PLACE SHROUD
#############################
{SOUND wail-long.wav} {DELAY 2000}
#define CONTRACT_SHROUD EXTRA_VISION
# specify x,y so we don't give this to units on the recall list (since REMOVE_OBJECT's SUF doesn't catch these for some reason)
{GIVE_OBJECT_TO (side,x,y=1,0-99,0-99) (id=bonus_vision {EFFECT vision increase={EXTRA_VISION}})}
[modify_side]
side,shroud=1,yes
[/modify_side]
[place_shroud]
side=1
x,y=0-99,0-99 # cover all tiles with shroud, including ones we've seen earlier
[/place_shroud]
{REDRAW}
{REMOVE_OBJECT bonus_vision ()}
[reset_fog] # fog was already close; don't let it expand again
{FILTER_SIDE side=1}
reset_view=yes
[/reset_fog]
{REDRAW}
{SOUND magic-dark-big-miss.ogg} {DELAY 750}
#enddef
{CONTRACT_SHROUD 20}
{CONTRACT_SHROUD 10}
{CONTRACT_SHROUD 5}
{CONTRACT_SHROUD 0}
[message]
id=$companion_id
message=_"Uhh, hello? Whos there? Boss, is that you?"
[/message]
#############################
# ZOMBIES APPEAR
#############################
#define SHOW_ZOMBIE_EMERGING X Y SND X2 Y2
{SCROLL_TO {X} {Y}}
{DELAY 250}
[lift_fog]
x,y,radius={X},{Y},1
[/lift_fog]
[remove_shroud]
side,x,y,radius=1,{X},{Y},1
[/remove_shroud]
{DELAY 250}
[store_unit]
{FILTER x,y={X},{Y}}
variable,kill=stored_cutscene_cave,yes
[/store_unit]
{SOUND {SND}}
{GENERIC_UNIT 2 "Walking Corpse" {X} {Y}} {ANIMATE} {VARIATION drake}
{DELAY 250}
{MOVE_UNIT x,y={X},{Y} {X2} {Y2}}
# {KILL x,y={X2},{Y2}}
[place_shroud]
side,x,y,radius=1,{X},{Y},1
[/place_shroud]
[unstore_unit]
variable=stored_cutscene_cave
[/unstore_unit]
{CLEAR_VARIABLE stored_cutscene_cave}
{DELAY 500}
#enddef
{SHOW_ZOMBIE_EMERGING 3 15 zombie-hit-3.ogg 6 15}
{SHOW_ZOMBIE_EMERGING 31 17 zombie-hit-4.ogg 28 17}
{SHOW_ZOMBIE_EMERGING 24 2 zombie-hit-6.ogg 22 4}
[event]
name=side 2 turn refresh
{MODIFY_UNIT side=2 moves 0} # otherwise the 22 4 zombie can get really close to your cave
[/event]
#############################
# ZOMBIE ATTACKS
#############################
{GENERIC_UNIT 2 Soulless 30 20} {VARIATION drake}
{STORE_UNIT_VAR role=escort1 x victimX}
{STORE_UNIT_VAR role=escort1 y victimY}
{MOVE_UNIT type=Soulless $victimX $victimY}
{ANIMATE_ATTACK type=Soulless () no x,y=$victimX,$victimY}
{CLEAR_VARIABLE victimX,victimY}
[message]
role=escort1
message=_"Aaaah!"
[/message]
{STORE_UNIT_VAR type=Soulless x victimX}
{STORE_UNIT_VAR type=Soulless y victimY}
{ANIMATE_ATTACK role=escort1 () yes x,y=$victimX,$victimY}
{KILL type=Soulless ANIMATE=yes}
{CLEAR_VARIABLE victimX,victimY}
#############################
# DISCUSS OPTIONS
#############################
[message]
role=escort1
message=_"Hell no! Curse it all, I didnt sign up for fighting zombies!"
[/message]
[message]
speaker=$companion_id
message=_"Cmon everyone, grab your weapons an get ready. Ive a feeling were about to have the fight o our lives!"
[/message]
# do this after the cutscene, or else we might see a zombie do something by accident
[remove_shroud]
side,x,y,radius=1,16-17,5-6,4 # main cave
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,18,9,1
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,20,10-11,1
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,22,10,1
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,22,14,1
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,26,17,1
[/remove_shroud]
[remove_shroud]
side,x,y,radius=1,30,20,1
[/remove_shroud]
[lift_fog]
{FILTER_SIDE side=1}
x,y,radius=16-17,5-6,3
multiturn=yes # ensure the player can see when enemies get near your main cave
[/lift_fog]
{REPLACE_SCENARIO_MUSIC the_city_falls.ogg}
{APPEND_MUSIC siege_of_laurelmor.ogg}
#############################
# OBJECTIVES
#############################
[objectives]
[objective]
description= _ "Protect Delfadors cave entrance until turns run out"
condition=win
[/objective]
[objective]
description= _ "Delfadors cave entrance is destroyed" # you can still win even if your leader dies
condition=lose
[/objective]
[gold_carryover]
carryover_percentage,bonus=40,no
[/gold_carryover]
[note]
description= _ "Amidst the craggy mountains, daylight is scarce. <i>(shorter days / longer nights)</i>"
[/note]
[/objectives]
#############################
# CAVE EXPLANATION
#############################
# only create this event after adding fog, or it never triggers
[event]
name=sighted
{FILTER side,type=2,"Cave Entrance"}
{FILTER_SECOND side=1}
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Look, a frozen cave, jus like the one Delfador went down! Ill bet thesere where all the undead are climin out of. Quick now, if we knock down the entrance we can trap em inside!"
[/message]
[objectives]
[objective]
description= _ "Protect Delfadors cave entrance until turns run out"
condition=win
[/objective]
[objective]
description= _ "Delfadors cave entrance is destroyed" # you can still win even if your leader dies
condition=lose
[/objective]
[gold_carryover]
carryover_percentage,bonus=40,no
[/gold_carryover]
[note]
description= _ "Destroy hostile cave entrances to trap enemies inside."
[/note]
[note]
description= _ "Amidst the craggy mountains, daylight is scarce. <i>(shorter days / longer nights)</i>"
[/note]
[/objectives]
[/event]
[/event]
#############################
# FIRST PLAGUE
#############################
[event]
name=last breath
{FILTER( side=1 {NOT({FILTER_LOCATION( terrain=*^V* )})} )} # plague doesn't work on villages
{FILTER_SECOND( type_adv_tree="Walking Corpse" )}
{FILTER_CONDITION( {NOT( {HAVE_UNIT id=Delfador} )} )} # don't trigger if Delfador has already returned; it would sound strange
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Oh no... you don look so good. Don die on me now, you hear? You got lots left to live for!"
[/message]
{KILL id=$unit.id ANIMATE=yes FIRE_EVENT=yes}
{GENERIC_UNIT 2 "Walking Corpse" $unit.x $unit.y} {ANIMATE}
{MODIFY_UNIT x,y=$unit.x,$unit.y moves 0}
{MODIFY_UNIT x,y=$unit.x,$unit.y attacks_left 0}
[message]
x,y=$unit.x,$unit.y
message=_"RraaaAAARRRGGG!"
[/message]
[/event]
#############################
# GHOST SPOTTED
#############################
[event]
name=sighted
{FILTER side,type_adv_tree=2,Ghost}
{FILTER_SECOND side=1}
{FIRE_EVENT explain_ghost}
[/event]
[event]
name=attack
{FILTER type_adv_tree=Ghost}
{FIRE_EVENT explain_ghost}
[/event]
[event]
name=attack
{FILTER_SECOND type_adv_tree=Ghost}
{FIRE_EVENT explain_ghost}
[/event]
[event]
name=explain_ghost
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Ghost!! This jus keeps gettin worse! Howre we supposed to fight somethin our weapons cant even touch!?"
[/message]
[/event]
#############################
# DEATH MESSAGES
#############################
[event]
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=new turn
{FILTER_CONDITION( {NOT( {HAVE_UNIT id=Delfador} )} )} # don't trigger if Delfador has already returned; it would sound strange
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Cmon, dont give up! We can pull through this!"
[/message]
[event] # don't track more deaths until after this message, to ensure we don't play both messages on the same turn
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=die {FILTER side=1}
[event]
name=new turn
{FILTER_CONDITION( {NOT( {HAVE_UNIT id=Delfador} )} )} # don't trigger if Delfador has already returned; it would sound strange
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"...boss? Hey, boss, you comin out o that cave anytime soon? We could really use your help out here..."
[/message]
[/event]
[/event]
[/event]
[/event]
[/event]
[/event]
[/event]
[/event]
[/event]
[/event]
#######################################################################################################################################################
# VICTORY / DEFEAT
#######################################################################################################################################################
[event]
name=time over
#############################
# UNDEAD START TO DIE
#############################
{FADE_MUSIC_OUT 1000}
{DELAY 100}
{REPLACE_SCENARIO_MUSIC silence.ogg}
{DELAY 100}
{FADE_MUSIC_IN 100}
{SOUND lightning.ogg}
{COLOR_ADJUST 100 100 200} {DELAY 150}
{COLOR_ADJUST 0 0 0} {DELAY 250}
{KILL_COUNT 3 (
side=2
{NOT type="Cave Entrance"}
[filter_vision]
side=1
[/filter_vision]
) ANIMATE=yes}
{GET_COMPANION_ID}
[message]
speaker=$companion_id
message=_"Wha— whats happening!?"
[/message]
#############################
# UNDEAD FINISH DYING
#############################
{KILL_COUNT 5 (
side=2
{NOT type="Cave Entrance"}
[filter_vision]
side=1
[/filter_vision]
) ANIMATE=yes}
{KILL (side=2 {NOT type="Cave Entrance"}) }
[message]
speaker=$companion_id
message=_"Thank the gods! Its finally over."
[/message]
[message]
{NOT id=$companion_id}
message=_"Im alive... I cant believe it..."
[/message]
[message]
speaker=$companion_id
message=_"I think we won! ...but how?"
[/message]
#############################
# CLEANUP AND VICTORY
#############################
[endlevel]
result=victory
{NEW_GOLD_CARRYOVER 40}
linger_mode,carryover_report=no,no
[/endlevel]
[/event]
[event]
name=victory
{MODIFY_UNIT id,canrecruit=$companion_id,yes canrecruit no}
{KILL type="Cave Entrance"} # so we don't end up with it on our recall list
{CLEAR_VARIABLE saurian_guide_id,saurian_guide_name,s09_tod,s09_gold_picked_up}
{CLEAR_VARIABLE next_defender,cave_locations}
{CLEAR_VARIABLE cave00,cave01,cave02,cave03,cave04,cave05,cave06,cave07,cave08,cave09,cave10,cave11,cave12}
[/event]
#############################
# CAVE IS DESTROYED
#############################
[event]
name=die
{FILTER id=cave00}
{GET_COMPANION_ID}
[message]
side=1 {NOT id=$companion_id}
message=_"The center crypts collapsin! Weve failed!"
[/message]
[message]
speaker=$companion_id
message=_"We did our best, but the boss aint comin back out anytime soon. Wed better scram back down south before the same happens to us."
[/message]
[endlevel]
result=defeat
[/endlevel]
[/event]
[/event]
{HERODEATHS}
[/scenario]
#undef CONTRACT_SHROUD