;
; Events text for The Once and Future King Scenario
; by Jonathan Lee, jkl7@cornell.edu
;
;

@BEGINEVENTS
@debug

@IF
NOSCHISM
DEFENDER=anybody 
@THEN
@ENDIF

;THE APPEARANCE OF KNIGHTS OF THE ROUND TABLE

@IF
TURN
turn=50
@THEN
endtext
createunit
owner=Kingdom of Britain
unit=Sir Galahad
veteran=yes
homecity=none
locations
44, 122
51, 115
50, 124
64, 116
endlocations
TEXT
^A new champion has arisen.  Pious, chivalrous, virtuous and gallant,
Sir Galahad is the epitamy of knighthood.
ENDTEXT
playwave
newgovt.wav
@endif

@IF
TURN
turn=40
@THEN
endtext
createunit
owner=Kingdom of Britain
unit=Mordred
veteran=yes
homecity=none
locations
44, 122
51, 115
50, 124
64, 116
endlocations
TEXT
^Sir Modred, a young knight of mysterious origins enters Arthur's service.
He soon proves to be a fierce warrior and wise advisor.
ENDTEXT
@endif


@IF
TURN
turn=30
@THEN
endtext
createunit
owner=Kingdom of Britain
unit=Sir Perceval
veteran=yes
homecity=none
locations
50, 116
51, 115
50, 124
64, 116
endlocations
TEXT
^Young Perceval enters Arthur's service.  The King knights him after
he captures a defeats a treacherous felon in single combat.
ENDTEXT
@ENDIF

@IF
TURN
turn=10
@THEN
endtext
createunit
owner=Kingdom of Britain
unit=Sir Lancelot
veteran=yes
homecity=none
locations
50, 116
51, 115
50, 124
64, 116
endlocations
TEXT
^A landless French knight presents himself at Arthur's court.  Swearing fealty
to Arthur, he becomes the King's greatest champion and most trusted
advisor.  His name is Sir Lancelot du Lac.
ENDTEXT

@ENDIF

;BARBARIANS and BRIGANDS

@if
randomturn
denominator=10
@then
createunit
owner=barbarians
unit=raiders
veteran=no
homecity=none
locations
64, 96
67, 99
72, 98
endlocations
Text
^Saxon raiders have landed in East Anglia!  Peasants are 
alarmed.
endtext
@endif

@if
randomturn
denominator=10
@then
createunit
owner=barbarians
unit=raiders
veteran=no
homecity=none
locations
52, 76
63, 89
endlocations
Text
^Danes land in Northumbria!  Peasants are alarmed.
endtext
@endif

@if
randomturn
denominator=10
@then
createunit
owner=barbarians
unit=raiders
veteran=no
homecity=none
locations
67, 99
64, 96
72, 98
endlocations
Text
^Saxon raiders have landed in East Anglia!  Peasants are 
alarmed.
endtext
@endif

@if
randomturn
denominator=10
@then
createunit
owner=barbarians
unit=raiders
veteran=yes
homecity=none
locations
27, 55
26, 46
28, 46
endlocations
Text
^Pict uprising in Scottish Highlands!  Local peasants are alarmed.
endtext
@endif

@if
randomturn
denominator=5
@then
createunit
owner=barbarians
unit=brigands
veteran=no
homecity=none
locations
45, 79
42, 78
43, 69
endlocations
@endif

@if
randomturn
denominator=8
@then
createunit
owner=barbarians
unit=brigands
veteran=no
homecity=none
locations
36, 104
31, 99
24, 108
endlocations
@endif

@if
randomturn
denominator=5
@then
createunit
owner=barbarians
unit=brigands
veteran=no
homecity=none
locations
58, 100
62, 98
endlocations
@endif

@if
randomturn
denominator=8
@then
createunit
owner=Kingdom of Cornwall
unit=brigands
veteran=no
homecity=none
locations
43, 113
49, 103
65, 109
endlocations
@endif

;DEATHS

@if
unitkilled
unit=King Arthur
attacker=anybody
defender=anybody
@then
text
^King Arthur is slain in combat.  His knights vow to carry on the struggle but
with his death, Britain has lost her best hope.  
endtext
@endif
 
@if
unitkilled
unit=Sir Lancelot
attacker=anybody
defender=anybody
@then
text
^Having killed countless foes, Sir Lancelot is eventually overcome by their sheer
numbers, and slain.  All of Britain mourns at the loss.
endtext
@endif

@if
unitkilled
unit=Sir Bedivere
attacker=anybody
defender=anybody
@then
text
^While preparing for battle, Sir Bedivere is assasinated in his tent
by enemy agents.  His fellow knights vow to avenge his death. 
endtext
@endif

@if
unitkilled
unit=Sir Gawaine
attacker=anybody
defender=anybody
@then
text
^Through treachery and trickery, Sir Gawaine is slain in combat.  
His friends and fellow knights vow to avenge his death.
endtext
@endif

@if
unitkilled
unit=Sir Kay
attacker=anybody
defender=anybody
@then
text
^Sir Kay, Arthur's loyal seneschal, is slain in combat.  The King mourns
his loss, as will all of Britain.
endtext
@endif

@if
unitkilled
unit=Sir Agravaine
attacker=anybody
defender=anybody
@then
text
^While bravely leading his men into combat, Sir Agravaine is struck
down by an enemy arrow.  His men fight bravely to avenge his death but the
day is lost.  
endtext
@endif

@if
unitkilled
unit=Sir Bors
attacker=anybody
defender=anybody
@then
text
^Sir Bors is slain in combat.  His courage and nobility will be missed by all.
endtext
@endif

@if
unitkilled
unit=Mordred
attacker=anybody
defender=anybody
@then
text
^Sir Mordred boldy leads his men versus the enemy.  He is believed
slain, but his body is never found.
endtext
@endif

@if
unitkilled
unit=Sir Galahad
attacker=anybody
defender=anybody
@then
text
^The enemies of the Crown inflict a crushing defeat on the Britons.
In an act of supreme gallantry, Sir Galahad sacrifices his life, allowing
his companions to escape.
endtext

@endif
@if
unitkilled
unit=Sir Tristam
attacker=Kingdom of Cornwall
defender=anybody
@then
text
^Sir Tristam is slain by the foul minions of King Mark of Cornwall.
His lover, the Queen Isolde commits suicide.
endtext
@endif

@if
unitkilled
unit=Merlin
attacker=anybody
defender=anybody
@then
text
^Enemies of Camelot attempt to slay Merlin but the wiley old wizard
has a few tricks up his sleeves.
endtext
createunit
owner=Kingdom of Britain
unit=Merlin
veteran=yes
homecity=none
locations
67, 99
72, 98
64, 96
endlocations
@endif

;CITIES

@if
citytaken
city=Tintagel
attacker=Kingdom of Britain
defender=anybody
@then
Text
^Castle Tintagel falls to the Arthur's knights and King Mark flees for
his life.  The peasants of Cornwall celebrate their liberation and rise
up to join Arthur's cause.
endtext
createunit 
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
24, 124
22, 122
28, 120
endlocations
justonce
@endif

@if
citytaken
city=Tintagel
attacker=Kingdom of Britain
defender=anybody
@then
createunit 
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
28, 120
24, 124
22, 122
endlocations
justonce
@endif

@if
citytaken
city=Eoforwic
attacker=Kingdom of Britain
defender=anybody
@then
text
^Eoforwic falls to Arthur's knights!  King Pellinore flees for his life.
endtext
@endif


@if
citytaken
city=Caernarvon
attacker=Kingdom of Britain
defender=anybody
@then
text
^The Welsh are routed as British forces storm Caernarvon.  King Caradoc flees for his life.
endtext
@endif

@if
citytaken
city=Liones
attacker=Kingdom of Britain
defender=anybody
@then
text
^Liones, the heart of Lyonesse, is liberated by Arthur!  The evil King Melodias flees to
Scotland.
endtext
@endif

@if
citytaken
city=Eadwinsburgh
attacker=Kingdom of Britain
defender=anybody
@then
text
^Arthur's victorious knights seize the Scottish capital!  King Urien flees into the Highlands,
promising revenge.
endtext
@endif


;PEASANTS

@if
turn
turn=15
@then
text
^Northumbrian peasants revolt against Pellinore and rally to Arthur's 
cause.
endtext
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
49, 79
55, 83
endlocations
@endif

@if
turn
turn=15
@then
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
55, 83
49, 79
endlocations
@endif


@if
turn
turn=15
@then
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
49, 79
55, 83
endlocations
@endif

@if
turn
turn=15
@then
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
49, 79
55, 83
endlocations
@endif


@if
turn
turn=25
@then
text
^Scottish peasants revolt against the oppressive King Urien.  King Arthur grants them
his protection.
endtext
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
30, 62
27, 59
endlocations
@endif

@if
turn
turn=25
@then
createunit
owner=Kingdom of Britain
unit=peasants
veteran=no
homecity=none
locations
29, 51
36, 66
endlocations
@endif

;NEGOTIATION

@if
turninterval
interval=3
@then
makeaggression
who=Kingdom of Wales
whom=Kingdom of Britain
@endif

@if
turninterval
interval=3
@then
makeaggression
who=Kingdom of Northumbria
whom=Kingdom of Britain
@endif

@if
randomturn
denominator=4
@then
makeaggression
who=Kingdom of Scotland
whom=Kingdom of Britain
@endif

@if
randomturn
denominator=5
@then
makeaggression
who=Kingdom of Lyonesse
whom=Kingdom of Britain
@endif

@if
turn
turn=every
@then
makeaggression
who=Kingdom of Cornwall
whom=Kingdom of Britain
@endif

@if
negotiation
talker=Kingdom of Britain
talkertype=humanorcomputer
listener=Kingdom of Scotland
listenertype=humanorcomputer
@endif

@if
negotiation
talker=Kingdom of Scotland
talkertype=humanorcomputer
listener=Kingdom of Britain
listenertype=humanorcomputer
@endif


@ENDEVENTS
