+CREDITS
Embryo

Story by Rob Crossley
Skins by Rob Crossley
Other Art by Rob Crossley
Some maps by Jas
Special thanks to Simmen Stenil, Lady Griffon, Halhundo, and Barrettboy
	
Programming by Synthetic Reality
Contact us on the web at:
http://www.synthetic-reality.com
-CREDITS

+STORY
:S 150
:C 255,0,0
:F Freehand591 BT
|The Euphoristic Anarchists proudly present...
:S 200
:C 255,255,0
:F Black
|Embryo
:S 75
:C 255, 50, 10
:F Castellar
|Story, Concept, and most Art by:
:S 50
:C 255,50,10
:F Brush455 BT
|Gandalf the White
:S 75
:C 255, 50, 10
:F Castellar
|Maps by:
:S 50
:C 255,50,10
:F Brush455 BT
|Jas
|Gandalf the White
:S 75
:C 255, 50, 10
:F Castellar
|Additional Support:
:S 50
:C 255,50,10
:F Brush455 BT
|Simmen Stenil
|Barrettboy
|Lady Griffon
|Halhundo
:S 100
:C 204,153,0
:F Black
|"...and so, the five Daemons were exiled to a forsaken realm forever known as 'Hell.'  Gorgan, Elzikso, Onimus, Mientaka, and Elzon were to forever rule this desolate, barren desert for all eternity.
|"From the five Daemons were spawned hideous and vile creatures, the likes of which the world could not begin to imagine.  The Daemon brothers had slowly amassed a great army within 2000 years of time.
|"Of course, over time, the exiles had been forgotten by the people.  The gates to Hell which were once guarded by the finest warriors now are in poor maintenance, and are very weak.  It was only a matter of time before the Daemons broke free...
|"...They overpowered us.  We could not resist, and now they have come to exact revenge upon our souls.  Many brave adventurers have already tried and failed at beating them.  Soon, I fear the entire human race, and the other races for that matter, will be annihilated..."
--The words of Olamu the Gatekeeper
:F Liberty BT
:C 255,0,0
|Your adventure begins here...
-STORY

+TERRAINS
;	arg0	arg1				arg2
;
	0,		"No Hindrance",		0
	1,		"Lava",				10
	2,		"Electricity",		10
	3,		"Mountains",			0
	4,		"Shallow Water",		0
	5,		"Clouds",			0
	6,		"Ice",				0
	7,		"Desert",			5
	8,		"Healing",			-10
	9,		"Impassable",		0
-TERRAINS

+EQUIP
;	arg0	arg1
;	ID		Name

  	0,		"Helmet"
 	1,		"Armor"
 	10,		"Boots"
 	11,		"Shield"
 	12,		"Ring"
 	13,		"Medallion"
-EQUIP

+MAPS

#include maps.txt

-MAPS

+TOKENS
	1,"You agreed to slay the Daemons."
	2,"You have had basic training."
	3,"You have had advanced training."
; Act 1--Elzon-Menzix
	100,"Go to the cemetery to defeat the Apprentice."
	101,"You have killed the Apprentice."
	102,"You received one ability token."
	103,"Enter the underground passageway to slay Reficul."
	104,"You defeated Reficul."
	105,"You got the SingeWick armor."
	106,"Enter the WarpedShrine and kill Natas."
	107,"You have slain Natas."
	108,"Your reward is Klicktack's soldier."
	109,"Defeat Elzon."
	110,"You killed Elzon."
	111,"You now have access to the port."
; Act 2--Mientaka-Elmsea
	200,"Destroy the pirates!"
	201,"You defeated the first wave of pirates."
	202,"You defeated the second wave of pirates."
	203,"You defeated the third wave of pirates."
	204,"Mientaka appears...kill him!"
	205,"You killed Mientaka."
	206,"You now have access to the next island."
; Act 3--Onimus-Quendibar
	300,"You must save Penelope."
	301,"You rescued Penelope."
	302,"You now have the IsenSword."
	303,"Recover the statue of Mientaka."
	304,"You recovered the statue."
	305,"You were rewarded with two ability coins."
	306,"Kill Onimus' gaurds."
	307,"You have slain Onimus' gaurds."
	308,"You have access to Onimus' lair."
	309,"Defeat Onimus."
	310,"Onimus has been killed."
	311,"You now have access to Hell."
; Act 4--Elzikso-Hell
	400,"Follow Elzikso in Hell."
	401,"Kill Elzikso."
	402,"You have defeated Elzikso!"
	403,"You may now pass to the Throne Room."
; Act 5--Gorgan-Shadowfaks
	500,"Kill Gorgan."
	501,"You have defeated Gorgan!"
	502,"You have access to the Final Field."
; Act 6--Final Field
	600,"Kill Olamu!"
	601,"Olamu has breathed his last."
	602,"Congratulations! You beat the main quest!"
; Bank Tokens
	700,"You set up a bank account."
	701,"Your bank account is currently frozen."
	702,"You have room 1 in the Hotel."
	703,"You have room 2 in the Hotel."
	704,"You have room 3 in the Hotel."
	705,"You have room 4 in the Hotel."
; Side Quests, etc.
	800,"Your Hunter rating has reached the level of DaemonSlayer."
	801,"You received the OdysSword."
	802,"You found the GilgaStaff."
	803,"You have the RagnaBow."
	804,"You got the AgamemGun."
	805,"You had the RainArmor forged."
	806,"You defeated Olamu the Gatekeeper."
	807,"You got the GodlyArmor."
	808,"You defeated Omega, the Final Daemon."
	809,"You get the Daemon set of equipment."
	810,"You gave Curtis Loew his drinking money, and now he'll play the blues for you."
	811,"You have an Empty Canteen."
	812,"You filled up the Empty Canteen."
; Other Tokens
	1000,"You gave the walking stick to Wheelchair Dan."
	1001,"Wheelchair Dan gave you the Broken Wheel."
	1002,"You got the Broken Wheel fixed."
	1003,"You used the Fixed Wheel to complete the wagon."
	1004,"You found Mr. Danner's home with the Wagon."
	1005,"You gave Mr. Danner the Rubber Chicken with a Pulley in the Middle."
	1006,"Mr. Danner gave you the Restaurant Coupon."
	1007,"You got the Essence of the Gods."
	1008,"The Great Smithie made the Final Armaments."
-TOKENS

;
;         0
;      7  |  1
;       \ | /
;    6 ---+--- 2
;       / | \
;      5  |  3
;         4
;

+ELEMENTS
;	arg0	arg1				
;
	0,		"Life"		
	1,		"Ice"			
	2,		"Water"			
	3,		"Earth"			
	4,		"Death"		
	5,		"Fire"		
	6,		"Lightning"		
	7,		"Wind"		
-ELEMENTS

+HANDS
;  
; arg0		arg1		arg2		arg3
;  ID		Name		Range		SoundFX
;
	0,		"Sword",	20,			"sword.wav"
	1,		"Staff",	30,			"staff.wav"
	2,		"Bow",		100,			"bow.wav"
	3,		"Harp",	40,			"harp.wav"
	4,		"Hands",	10,			"hands.wav"
	5,		"Mace",		20,			"mace.wav"
	6,		"Dagger",	10,			"dagger.wav"
	7,		"Claw",		20,			"claw.wav"
-HANDS


+ITEMS

#include items.txt

-ITEMS


+SPELLS

#include spells.txt

-SPELLS



+MONSTERS

#include monsters.txt

-MONSTERS


+GROUPS

#include groups.txt

-GROUPS


+LEVELS

#include levels.txt

-LEVELS

+SCENES
;-------------------------------------------------
; SCENE 0 must be primary well of souls
;
SCENE 0	well,	WELL,	"Gates to Hell",	4,	0
; Raging fire as the theme...can you imagine the Gates of Hell WITHOUT fire?
	THEME	7
	MUSIC	well.mid
	ACTOR	1,	"Jim the Townsman", misc,	1,	50,	95
	SELECT	1
	POSE	1,	2,	3
	1: Oh, this is NOT good.
	1: Hey, you! Can you help out here?
	1: Olamu the Gatekeeper was too weak to hold off the Gates!
	1: Now the Daemons are free! Oh, what to do...
	1: Hey! You can stop them!
	1: Just incarnate a soul...
	1: If you're new to these lands, choose NEW.
	1: If you've been here before, then you can RESTORE and INCARNATE again.
	1: Oh, please hurry! Who knows what kind of trouble the Daemons are up to?
	MOVE	1,	50,	150
END

;-------------------------------------------
; SCENE 1 must be primary CAMP scene
;
SCENE 1,	#<str.mapName>,	CAMP,	"Camping",	0,	0
; Theme is chirping birds, because you're in a camp out in the wilderness (even if you aren't, deal with it)
	THEME	8
	MUSIC #<str.mapName>.mid
	BKGND #<str.mapName>.jpg
	STRCMP #<str.mapName>, "Hunting Grounds"
	IF=, @snow
	STRCMP #<str.mapName>, "Shadowfaks"
	IF=, @snow
	STRCMP #<str.mapName>, "Hell"
	IF=, @fire
	GOTO @continue
END

@fire
	THEME	7
	FX	5
	GOTO @continue
END

@snow
	WEATHER 9
	GOTO @continue
END

@continue
; Find out if this is a PK attack
	COMPARE #<num.isPKAttack>, "1"
	IF=, @pk_attack
; Send them to the island selection screen if they can
	IF T502, @select_your_island
; Find out if they can access curtis loew
	IF T810, @curtis_loew_in_camp
END

@pk_attack
; It IS a PK attack, so lets disable flags, healing, and stunning
	LOCK 1
 	FLAGS 45056
; Now, end the scene to let the PKers fight
END

@curtis_loew_in_camp
	MUSIC #<playMusic>.mid
	THEME	0
	ACTOR	1, "Curtis Loew", black, 1, 25, 80
	N: Right-click Curtis to hear his blues.
END

@eventActorclick1
	1: Which song do you want to hear?
	COMPARE #<huntPoints>, "420"
	IF>, @all_songs
	COMPARE #<huntPoints>, "210"
	IF>, @half_songs
	COMPARE #<huntPoints>, "105"
	IF>, @fourth_songs
	COMPARE #<huntPoints>, "50"
	IF>, @five_songs
	COMPARE #<huntPoints>, "10"
	IF>, @one_song
END

@one_song
	MENU "Sweet Child O Mine=@sweet_child_o_mine"
	WAIT 9999
	GOTO @eventActorclick1
END

@five_songs
	MENU "Sweet Child O Mine=@sweet_child_o_mine","Immigration Song=@immigration_song","Bark at the Moon=@bark_at_the_moon","Black Sabbath Medley=@black_sabbath_medley","Crazy Train=@crazy_train"
	WAIT 9999
	GOTO @eventActorclick1
END

@fourth_songs
	MENU "Sweet Child O Mine=@sweet_child_o_mine","Immigration Song=@immigration_song","Bark at the Moon=@bark_at_the_moon","Black Sabbath Medley=@black_sabbath_medley","Crazy Train=@crazy_train","You Shook Me All Night Long=@you_shook_me_all_night_long","Hazy Shade of Winter="hazy_shade_of_winter","Stayin Alive=@stayin_alive","I Just Want You=@i_just_want_you","Knockin On Heavens Door=@knockin_on_heavens_door"
	WAIT 9999
	GOTO @eventActorclick1
END

@half_songs
	MENU "Sweet Child O Mine=@sweet_child_o_mine","Immigration Song=@immigration_song","Bark at the Moon=@bark_at_the_moon","Black Sabbath Medley=@black_sabbath_medley","Crazy Train=@crazy_train","You Shook Me All Night Long=@you_shook_me_all_night_long","Hazy Shade of Winter="hazy_shade_of_winter","Stayin Alive=@stayin_alive","I Just Want You=@i_just_want_you","More...=@more_half"
	WAIT 9999
	GOTO @eventActorclick1
END

@more_half
	WAIT 1
	MENU "Knockin On Heavens Door=@knockin_on_heavens_door","Dee=@dee","NIB=@nib","Over the Mountain=@over_the_mountain","Cum On Feel The Noize=@cum_on_feel_the_noize","Embryo=@embryo","Summer in the City=@summer_in_the_city","Sharp Dressed Man=@sharp_dressed_man","Suicide Solution=@suicide_solution","More...=@more_half_2"
	WAIT 9999
	GOTO @eventActorclick1
END

@more_half_2
	WAIT 1
	MENU "Close My Eyes=@close_my_eyes","Symptom of the Universe=@symptom_of_the_universe","War Pigs=@war_pigs"
	WAIT 9999
	GOTO @eventActorclick1
END

@all_songs
	MENU "Sweet Child O Mine=@sweet_child_o_mine","Immigration Song=@immigration_song","Bark at the Moon=@bark_at_the_moon","Black Sabbath Medley=@black_sabbath_medley","Crazy Train=@crazy_train","You Shook Me All Night Long=@you_shook_me_all_night_long","Hazy Shade of Winter="hazy_shade_of_winter","Stayin Alive=@stayin_alive","I Just Want You=@i_just_want_you","More...=@more_all"
	WAIT 9999
	GOTO @eventActorclick1
END

@more_all
	WAIT 1
	MENU "Knockin On Heavens Door=@knockin_on_heavens_door","Dee=@dee","NIB=@nib","Over the Mountain=@over_the_mountain","Cum On Feel The Noize=@cum_on_feel_the_noize","Embryo=@embryo","Summer in the City=@summer_in_the_city","Sharp Dressed Man=@sharp_dressed_man","Suicide Solution=@suicide_solution","More...=@more_all_2"
	WAIT 9999
	GOTO @eventActorclick1
END

@more_all_2
	WAIT 1
	MENU "Close My Eyes=@close_my_eyes","Symptom of the Universe=@symptom_of_the_universe","War Pigs=@war_pigs","Magic Carpet Ride=@magic_carpet_ride","Steal Away the Night=@steal_away_the_night","Free Bird=@free_bird","Dont Fear the Reaper=@dont_fear_the_reaper","Children of the Grave=@children_of_the_grave","Flying High Again=@flying_high_again","More...=@more_all_3
	WAIT 9999
	GOTO @eventActorclick1
END

@more_all_3
	WAIT 1
	MENU "One=@one","Sabbath Bloody Sabbath=@sabbath_bloody_sabbath","Pinball Wizard=@pinball_wizard","Low Mans Lyric=@low_mans_lyric","You Wear it Well=@you_wear_it_well","Revelation=@revelation","Planet Caravan=@planet_caravan","Bungle in the Jungle=@bungle_in_the_jungle","Sanford and Son=@sanford_and_son","More...=@more_all_4"
	WAIT 9999
	GOTO @eventActorclick1
END

@more_all_4
	WAIT 1
	MENU "Shot in the Dark=@shot_in_the_dark","I Ran=@i_ran","Here I Go Again=@here_i_go_again","Battle of Evermore=@battle_of_evermore","I Dont Know=@i_dont_know"
	WAIT 9999
	GOTO @eventActorclick1
END

@sweet_child_o_mine
	SET playMusic, "academy"
	GOTO @curtis_loew_in_camp
END

@immigration_song
	SET playMusic, "art"
	GOTO @curtis_loew_in_camp
END

@bark_at_the_moon
	SET playMusic, "bank"
	GOTO @curtis_loew_in_camp
END

@black_sabbath_medley
	SET playMusic, "bsmedley"
	GOTO @curtis_loew_in_camp
END

@crazy_train
	SET playMusic, "castle"
	GOTO @curtis_loew_in_camp
END

@you_shook_me_all_nigh_long
	SET playMusic, "catacomb"
	GOTO @curtis_loew_in_camp
END

@hazy_shade_of_winter
	SET playMusic, "catacombfight"
	GOTO @curtis_loew_in_camp
END

@stayin_alive
	SET playMusic, "church"
	GOTO @curtis_loew_in_camp
END

@i_just_want_you
	SET playMusic, "crediting"
	GOTO @curtis_loew_in_camp
END

@knockin_on_heavens_door
	SET playMusic, "cutscene"
	GOTO @curtis_loew_in_camp
END

@dee
	SET playMusic, "dan"
	GOTO @curtis_loew_in_camp
END

@nib
	SET playMusic, "demon"
	GOTO @curtis_loew_in_camp
END

@over_the_mountain
	SET playMusic, "door"
	GOTO @curtis_loew_in_camp
END

@cum_on_feel_the_noize
	SET playMusic, "elf"
	GOTO @curtis_loew_in_camp
END

@embryo
	SET playMusic, "Embryo"
	GOTO @curtis_loew_in_camp
END

@summer_in_the_city
	SET playMusic, "Final Field"
	GOTO @curtis_loew_in_camp
END

@suicide_solution
	SET playMusic, "finish"
	GOTO @curtis_loew_in_camp
END

@close_my_eyes
	SET playMusic, "graveyard"
	GOTO @curtis_loew_in_camp
END

@symptom_of_the_universe
	SET playMusic, "green"
	GOTO @curtis_loew_in_camp
END

@war_pigs
	SET playMusic, "hell"
	GOTO @curtis_loew_in_camp
END

@magic_carpet_ride
	SET playMusic, "Hellfight"
	GOTO @curtis_loew_in_camp
END

@steal_away_the_night
	SET playMusic, "hotel"
	GOTO @curtis_loew_in_camp
END

@free_bird
	SET playMusic, "hunt"
	GOTO @curtis_loew_in_camp
END

@dont_fear_the_reaper
	SET playMusic, "king"
	GOTO @curtis_loew_in_camp
END

@children_of_the_grave
	SET playMusic, "king2"
	GOTO @curtis_loew_in_camp
END

@flying_high_again
	SET playMusic, "loaning"
	GOTO @curtis_loew_in_camp
END

@one
	SET playMusic, "lost"
	GOTO @curtis_loew_in_camp
END

@sabbath_bloody_sabbath
	SET playMusic, "menzix"
	GOTO @curtis_loew_in_camp
END

@pinball_wizard
	SET playMusic, "menzixfight"
	GOTO @curtis_loew_in_camp
END

@low_mans_lyric
	SET playMusic, "quendibar"
	GOTO @curtis_loew_in_camp
END

@you_wear_it_well
	SET playMusic, "quendibarfight"
	GOTO @curtis_loew_in_camp
END

@revelation
	SET playMusic, "saving"
	GOTO @curtis_loew_in_camp
END

@planet_caravan
	SET playMusic, "shadowfaks"
	GOTO @curtis_loew_in_camp
END

@bungle_in_the_jungle
	SET playMusic, "shadowfaksfight"
	GOTO @curtis_loew_in_camp
END

@sharp_dressed_man
	SET playMusic, "Final Fieldfight"
	GOTO @curtis_loew_in_camp
END

@sanford_and_son
	SET playMusic, "shop"
	GOTO @curtis_loew_in_camp
END

@shot_in_the_dark
	SET playMusic, "sleep"
	GOTO @curtis_loew_in_camp
END

@i_ran
	SET playMusic, "title"
	GOTO @curtis_loew_in_camp
END

@here_i_go_again
	SET playMusic, "travel"
	GOTO @curtis_loew_in_camp
END

@battle_of_evermore
	SET playMusic, "well"
	GOTO @curtis_loew_in_camp
END

@i_dont_know
	SET playMusic, "win"
	GOTO @curtis_loew_in_camp
END


 ;-------------------------------------------------
 ; SCENE 2 must be primary FIGHT scene (for automatic fights)
;
SCENE 2,	#<str.mapName>,	FIGHT,	"Fighting",	0,	0
	BKGND #<str.mapName>.jpg
	STRCMP #<str.mapName>, "Hunting Grounds"
	IF=, @snow
	STRCMP #<str.mapName>, "Shadowfaks"
	IF=, @snow
	STRCMP #<str.mapName>, "Hell"
	IF=, @fire
	GOTO @continue
END

@fire
	THEME	8
	FX	5
	GOTO @continue

END

@snow
	WEATHER 9
	GOTO @continue
END

@continue
; Find out if we're on the hunting range--it's a completely different system there
	IF #4, @on_hunting_range
; We aren't on the hunting range, so lets proceed with the regular fight scene
; ...after randomizing the fight music so it doesn't get redundant
	GOTO @fight
END

@fight
	IF T303-T304, @dance_away
	MUSIC #<str.mapName>fight.mid
	FIGHT
	IF LOSE, @add_death
	IF WIN, @add_won
END

@add_death
; take away some gold...just for good measure :-)
	SET goldPercentTaken, "%R100"
	N: You lost #<goldPercentTaken>%% of your gold!
	SET goldTaken, #<num.hostGP>
	MUL goldTaken, #<goldPercentTaken>
	DIV goldTaken, "100"
	TAKE G#<goldTaken>
	N: That's #<goldTaken>G! You should have used the bank!
; Take one point off the current skillRank cookie...this will come into play later
; ...MUCH later
	SUB skillRank, "1"
END

@add_won
; Add a point to the skillRank cookie...again, will come into play later
	ADD skillRank, "1"
END

@on_hunting_range
; We ARE on the hunting range, so we play the hunting music
	MUSIC hunt.mid
	FLAG	14344
; set which monster we fight so that the player fights only ONE monster
	SET huntMonster, "%R12"
; find out if the monster is ID 50-52
	COMPARE #<huntMonster>, "9"
	IF>, @hunting_mini_boss
	COMPARE #<huntMonster>, "4"
	IF=, @reset_hunt
	SET monster.id, #<huntMonster>
	FIGHT	#<huntMonster>
	IF LOSE, @lost_hunt
	IF WIN, @won_hunt
END

@reset_hunt
	SET huntMonster, "3"
	SET monster.id, #<huntMonster>
	FIGHT	#<huntMonster>
	IF LOSE, @lost_hunt
	IF WIN, @won_hunt
END

@hunting_mini_boss
; set the Monster ID to 50-53 by adding 40
	ADD huntMonster, "40"
	SET monster.id, #<huntMonster>
	FIGHT	#<huntMonster>
	IF LOSE, @lost_hunt
	IF WIN, @won_hunt
END

@lost_hunt
	MUSIC hunt.mid
; now we take off a fourth of the hunting points--losing carries quite a penalty on the hunting range
; the points will be used for buying certain, special items at a special shop later as sort of a side quest
	SUB huntPoints, #<monster.level>
	N: You lost #<monster.level> Hunting Points!
	N: You now have #<huntPoints> Hunting Points.
END

@won_hunt
	MUSIC hunt.mid
; add 5 hunting points for winning a battle
	ADD huntPoints, #<monster.level>
	N: You gained #<monster.level> Hunting Points
	N: You now have #<huntPoints> Hunting Points.
END

@dance_away
	MUSIC	#<str.mapName>fight.mid
	SET discoMonster, "%R12"
	COMPARE #<discoMonster>, "4"
	IF=, @dance_reset
	COMPARE #<discoMonster>, "9"
	IF>, @dance_away_miniboss
	SET monster.id, #<discoMonster>
	SET discoFight, #<monster.expPts>
	DIV discoFight, "2"
	COMPARE #<discoLevel>, "40"
	IF=, @dance_away_no_exp
	IF>, @dance_away_no_exp
	FIGHT #<monster.id>, -5#<discoLevel>
	IF WIN, @dance_won
	IF LOSE, @dance_lose
END

@dance_reset
	SET discoMonster, "3"
	SET monster.id, #<discoMonster>
	SET discoFight, #<monster.expPts>
	DIV discoFight, "2"
	COMPARE #<discoLevel>, "40"
	IF=, @dance_away_no_exp
	IF>, @dance_away_no_exp
	FIGHT	#<monster.id>, -5#<discoLevel>
	IF LOSE, @dance_lose
	IF WIN, @dance_won
END

@dance_away_miniboss
	ADD discoMonster, "40"
	SET monster.id, #<discoMonster>
	SET discoFight, #<monster.expPts>
	DIV discoFight, "2"
	COMPARE #<discoLevel>, "40"
	IF=, @dance_away_no_exp
	IF>, @dance_away_no_exp
	FIGHT #<monster.id>, -5#<discoLevel>
	IF WIN, @dance_won
	IF LOSE, @dance_lose
END

@dance_away_no_exp
	FIGHT #<monster.id>, -540
	IF WIN, @dance_won_2
	IF LOSE, @dance_lose
END

@dance_away_2
 	SET discoExp, "0"
	MUL discoExpNeed, "2"
	SET discoExpNeed1, #<discoExpNeed>
	ADD discoLevel, "1"
	N: The Art Collector Leveled up! He is now level #<discoLevel>!
; Add a point to the skillRank cookie...again, will come into play later
	ADD skillRank, "1"
	IF R5, @found_mientaka_statue
END

@dance_won
; Add some experience to the art collector's level.
	ADD discoExp, #<discoFight>
	SUB discoExpNeed1, #<discoFight>
	COMPARE #<discoExp>, #<discoExpNeed>

	IF>, @dance_away_2
	IF=, @dance_away_2
	N: Art Collector gained #<discoFight> Exp Pts.
	N: He needs #<discoExpNeed1> Exp Pts. to level up.
; Add a point to the skillRank cookie...again, will come into play later
	ADD skillRank, "1"
	IF R5, @found_mientaka_statue
END

@dance_won_2
; Add a point to the skillRank cookie...again, will come into play later
	ADD skillRank, "1"
	IF R5, @found_mientaka_statue
END

@found_mientaka_statue
	N: You picked up a Mientaka statue.
	N: The Art Collector took it...go by his place to recieve your reward.
	GIVE T304
END

@dance_lose
; take away some gold...just for good measure :-)
	SET goldPercentTaken, "%R100"
	N: You lost #<goldPercentTaken>%% of your gold!
	SET goldTaken, #<num.hostGP>
	MUL goldTaken, #<goldPercentTaken>
	DIV goldTaken, "100"
	TAKE G#<goldTaken>
	N: That's #<goldTaken>G! You should have used the bank!
; Take one point off the current skillRank cookie...this will come into play later
; ...MUCH later
	SUB skillRank, "1"
; Take away some disco Exp, too.
	SUB discoExp, #<discoFight>
END

;-----------------------------------------------------
; SCENE 3
;
SCENE 3		chambre,	SCENE,	"King's Chambre",	0,	0
	THEME	0
	MUSIC	king.mid
	ACTOR	1,	"King Thengel", king, 1, 25, 90
	SELECT
	POSE	1, 2, 3
; sell some healing items
	OFFER 1, 2, 3, 4, 5, 6, 7, 8, 9
; heal the player
	GIVE H10000
	GIVE M10000
; take us to a label depending on death or certain tokens
	IF DEAD, @dead_player
	IF T111, @open_port
	IF T110, @finish_elzon_quest
	IF T109, @on_elzon_quest
	IF T108, @start_elzon_quest
	IF T102, @next_castle
	IF T101-T102, @finish_summoner_quest
	IF T100-T101, @on_summoner_quest
	IF T1, @start_summoner_quest
; this is the first time you ever talk to Thengel
	1: I am the king of Menzix. My name is Thengel.
	1: At least, I WAS the king, before that %3 of a Daemon came.
	1: Well, we shall have our revenge yet, shall we not?!
	1: Would you like to join the cause to help me out?
; ask player if he wants to join
	ASK	99999
	IF YES, @join_cause
	1: I see you refuse to be my comrade.
	1: Well, that is just too bad.
; take 1000 gold--you should have said yes!
	TAKE G1000
END
 @join_cause
; the player chose yes, so he goes here
	1: This is grand news; a fine ally you will make!
	1: You might want to go to the shop, and then to the Instructors to get some training.
	1: Around my castle you may search, for things to buy.
	GIVE T1
; take us to the start_summoner_quest label
	GOTO @start_summoner_quest
END

@dead_player
; the player is dead, so we need to revive him
	1: I shall revive you now.
	GIVE L1
	GIVE H1000
	GIVE M1000
	1: It seems you took more damage than your body would allow.
END

@start_summoner_quest
	1: Alright, you're ready for your first quest, %2!
	1: You must kill the Apprentice Summoner!
	1: He is desecrating our dead in the graveyard to the southeast!
	1: Kill him and bring me his head!
	GIVE T100
END

@needs_training
	1: I'm sorry, you must be trained in War and Magick before I send you out.
	1: For right now, training you are without.
END

@on_summoner_quest
	1: Well, get to it, sonny boy, GO! Kill the Apprentice!
	1: For now even you are in this!
END

@finish_summoner_quest
	1: Excellent job defeating the enemy.
	1: I am grateful for the help you've given me.
	1: I will now give you one Ability Token.
	GIVE T102
	GIVE I10
	1: Now, I hope you're prepared for your next quest!
; take player to the next_castle label
	GOTO @next_castle
 END

@next_castle
	1: I have referred you to the next Eastern castle.
	1: Hurry, go; he is in dire need of your help!
END

@start_elzon_quest
	1: We've recieved reports that Elzon has gone into hiding.
	1: Go to his cave on the southern part of the island.
	1: This may be our only chance to defeat him!
	GIVE T109
END 
@on_elzon_quest
	1: Hurry and kill that awful creature!
	1: Down to his evil lair you must venture.
END

@finish_elzon_quest
	1: The Daemon has been killed; now go to the port, please.

	1: I've opened it up; you may now set sail on the seas.
	GIVE T111
END

@open_port
	1: The port is open for your sailing pleasures.
	1: On to the next island, to test your measure.
END

;-----------------------------------------------------------
; SCENE 4 Basic Training
;
SCENE 4	art,	SCENE	"Basic Training",	0,	0	
	THEME	0
	MUSIC	academy.mid
	ACTOR	1,	"Instructor", prof, 2, 25, 90
	SELECT	1
	IF T2, @already_trained
	1: Hello, %2.
	1: You need to be basically trained, eh?
	ASK 9999
	IF QNO, @learn_later
	1: I charge a fine of 50 Gold. Pay up and we shall train today.
	1: Please note that if you're familiar with Evergreen (or other worlds), then this is absolutely pointless.
	1: I'll just go over the same basic points that you should know if you're familiar with Well of Souls.
	1: Otherwise, the training will begin in 10 seconds.
	COUNTDOWN 10
	WAIT 10
	GOTO @start_training
END
	
@start_training
	IF -G50, @no_money
	TAKE G50
	1: Click on the MAP button at the bottom. This brings up the map display.
	1: You can right-click on the names in the list in order to view Soul Diary pages, censor skins, etc.
	1: Now, click on the STATS button. You'll see the stats of the player selected in the menu.
	1: Move on to the EQUIP button. You'll see the items you currently have equipped as well as other equippable items.
	1: You can only equip items that you are strong enough to use. Most equipment requires the user be a certain level.
	1: While in the EQUIP screen, you can attack monsters.
	1: You can also use the EQUIP screen to train your hand and to train your pets.
	1: Go into the SPELLS screen now. This brings up a list of your current spells.
	1: Here, you can cast the selected spell on an enemy.
	1: Or, you can use your Participation Points (PP) to hone your skills in an element, or to buy new spells.
	1: Finally, go to the ITEMS menu. This shows all the items you are currently carrying.
	1: To use an item, click on it, and then click on yourself (or whoever you want to use the item on).
	1: This concludes the Basic Training.
	GIVE T2
END

@learn_later
	1: Alright, maybe later then.
	1: I can see you're a busy man.
END

@no_money
	1: You seem to be a deadbeat. You have no money.
	1: If this is some sort of joke, it ain't funny.
	1: That's alright...I can tell you the basics free of charge.
	1: To fight, go to the EQUIP screen and click on the enemies.
	1: What do expect for free?
	1: I started this to get a profit for me.
	GIVE T2
END

@trained_already
	1: You've already passed my course.
	1: If you want to pay 50 Gold again, then for my profit I feel no remorse!
	ASK 9999
	IF YES, @start_training
	1: Yeah, I didn't think you'd want to pay.
	1: But, hey--come back another day!
END

;----------------------------------------------
; Advanced Training

SCENE 5 art,	SCENE	"Advanced Training",	0,	0
	THEME	0
	MUSIC	academy.mid
	ACTOR	1,	"Instructor", prof, 3, 25, 90
	SELECT	1
	IF T3, @already_trained
	1: Hello, %2.
	1: You wish to take your training to the next level?
	ASK 9999
	IF QNO, @learn_later
	1: I charge a fine of 25 Gold. Just pay it, ok?
	1: This course covers everything that is specific to this world, Embryo.
	1: If you feel you can figure it out on your own, then please leave.
	1: Otherwise, training begins in 10 seconds.
	COUNTDOWN 10
	WAIT 10
	GOTO @start_training
END
	
@start_training
	IF -G25, @no_money
	TAKE G25
	1: I'll start off with the story, in case you didn't read it at the beginning.
	1: Five powerful evil Daemons have escaped from Hell because Olamu the Gatekeeper was too weak to hold them back.
	1: They are Elzon, Mientaka, Onimus, Gorgan, and Elzikso. They have scattered throughout our world.
	1: You must destroy all of them to return peace to the lands.
	1: There are many quests to be completed in this world.
	1: However, many of them do not even need to be accomplished.
	1: This is a fairly nonlinear world--all that you are required to do to advance is to kill one of the Daemon brothers.
	1: However, if you complete all the main quests, you will find it much easier to destroy them.
	1: There are even more completely optional side quests which have no impact on the main story whatsoever.
	1: These will further enhance your abilities, though they are often difficult to accomplish.
	1: Just remember--the more quests you complete, the better your chances of destroying the Daemons.
	1: Currently you are a %C #<g.race>. However, your class and race can be changed in a certain sidequest if you so desire.
	1: However, despite the benefits of such a transformation, there will likely be some downfalls as well.
	1: Keep this in mind when you are traversing the world of Embryo.
	1: Now, regarding exploration.
	1: There are four islands in our world. They are Menzix, Quendibar, Allonzo, and Elysium.
	1: Eventually you will explore all of them, and perhaps find even more islands.
	1: Once you go to a new island, it is possible for you to go back to the other islands you've visited.
	1: That concludes your advanced training.
	GIVE T3
END

@learn_later
	1: Alright, maybe later then.
	1: I see you're quite a busy man.
END

@no_money
	1: You seem to be a deadbeat. You have no Gold.
	1: I'll tell you for free, though I may be very old.
	1: To use a spell, click on it, then click on a foe.
	1: What do expect for a price so low?
	1: You passed the course, ok?
	1: Now please go away.
 	GIVE T3
END

@trained_already
	1: You've already passed my course.
	1: If you want to pay 25 Gold again, then for my profit I feel no remorse!
	ASK 9999
	IF YES, @start_training
	1: Yeah, I didn't think you'd want to pay.
	1: But, hey--come back another day!	
END

;--------------------------------------
; Shop

SCENE 6 shop,	SCENE,	"Shop",	0,	0
	THEME	0
	MUSIC	shop.mid
	ACTOR	1,	"Drappel", clerk, 1, 25, 90
	POSE	1,	2,	3
	SELECT	1
; since I'm so lazy, I'll just make this a healing/rez point as well as a shop.
	IF DEAD, @resurrect_in_shop
	GOTO @sell_items
END

@sell_items
	GIVE H10000
	GIVE M10000
; set the lowest level equipment at 5 levels lower than the player
	SET lowLevel, #<num.hostLevel>
	SUB lowLevel, "5"
; set the highest level equipment at 5 levels higher than the player
	SET highLevel, #<num.hostLevel>
	ADD highLevel, "5"
; set the weapon class
	SET weaponClass, #<num.hostClass>
	ADD weaponClass, "11"
; now sell the stuff
	OFFER2	#<lowLevel>,#<highLevel>,#<weaponClass>,		#<lowLevel>,#<highLevel>,10,		#<lowLevel>,#<highLevel>,11,		#<lowLevel>,#<highLevel>,20,		#<lowLevel>,#<highLevel>,21,		#<lowLevel>,#<highLevel>,22,		#<lowLevel>,#<highLevel>,23
	1: Hello, %2. I am Drappel, the  wandering merchant.
	1: So, what can I do for ya? Would you like to purchase?
END

@resurrect_in_shop
; now resurrect them and take them to the shop
	1: I don't sell to dead people...so I'll have to resurrect you.
	GIVE L1
	GIVE H10000
	GIVE M10000
	GOTO @sell_items
END

;------------------------------------
; Wishing Well
;
SCENE 7 wish, SCENE, "Wishing Well",	0,	0
	THEME	0
	MUSIC	well.mid
	ACTOR	1,	"Wishing Well", wellwish, 1, 25, 90
	POSE	1,2,3
	SELECT	1
	IF I806, @player_has_canteen
; the well only resurrects at first...the player must give gold to affect the well
	N: Give the well money to heal your HP and MP.
	IF DEAD, @well_resurrect
END

@well_resurrect
	TAKE G1
	GIVE L1
END
 @eventActorGive1
	IF I806, @give_back_money
	COMPARE #<item.id>, "805"
	IF=, @fill_canteen
	COMPARE #<item.goldGiven>, "0"
	IF=, @not_gold
	ADD wishGold, #<item.goldGiven>
	COMPARE #<wishGold>, "1000"
	IF>, @wish_come_true
	IF=, @wish_come_true
	GOTO @wish_not_true
END

@wish_not_true
	GIVE M#<item.goldGiven>
	GIVE H#<item.goldGiven>
	1: Hey, you're a cool #<g.race>...thanks for passing through.
	1: Sorry, but your wish didn't come true.
END

@wish_come_true
	IF I805, @wish_not_true
; the player has made 1000 wishes, so he gets an empty canteen. 	1: Great news! You're wish came true!
	1: So, here's your empty canteen.
	GIVE I805
	GIVE T811
	H: An empty canteen?
	H: What am I supposed to do with that?
	1: No idea...you'll figure something out.
END 
@fill_canteen
	GIVE T812
	GIVE I806
	N: You filled up the canteen with magical well water.
END

@not_gold
	1: That isn't gold. You can't expect a wish to come true by giving me an item.
	1: Take your item back! Here!
	GIVE I#<item.id>
	1: Now give me MONEY...this ain't a charity, you crazy #<g.race>.
END

@player_has_canteen

	GIVE L1
	GIVE H100000
	GIVE M100000
	N: The well doesn't want your money.
END

@give_back_money
	GIVE G#<item.goldGiven>
	GIVE I#<item.id>
	1: I don't want your money or items...now I heal you free.
	1: Just use that canteen to warp here any time.
END

;-------------------------------------------------------
; Act 1
;	100,"Go to the cemetery to defeat the Apprentice."
;	101,"You have killed the Apprentice."
;	102,"You received one ability token."
;	103,"Enter the underground passageway to slay Reficul."
;	104,"You defeated Reficul."
;	105,"You got the SingeWick armor."
;	106,"Enter the WarpedShrine and kill Natas."
;	107,"You have slain Natas."
;	108,"Your reward is Klicktack's soldier."
;	109,"Defeat Elzon."
;	110,"You killed Elzon."
;	111,"You now have access to the port."
;
;------------------------------------------------
; Apprentice

SCENE 8 graveyard,	SCENE,	"Graveyard",	0,	0
	THEME	4
	MUSIC	graveyard.mid
	IF T100-T101, @kill_summoner
END

@kill_summoner
	ACTOR	1,	"Apprentice", summoner, 1, 25, 90
	POSE	1,
	SEL		1
	1: Ha ha ha...Good evening, %2!
	1: As you have no doubt suspected, I am the Apprentice!


	1: Be warned--don't you dare right click on me, as I am looking for vengeance!
	1: And then I will bite your head off!

	1: Ha ha ha ha...In your direction I do scoff!
END

@eventActorclick1
	1: Hah! You are nothing more than a lowly #<g.race>!
	1: What can you POSSIBLY do to ME?
	1: Skeletons, ATTACK!
	MOVE 1,-100,-100,1
	FIGHT 1, 1, 1, 1
	IF WIN, @killed_first_wave
	1: Hah! You can NEVER beat me! Hahahaha...
	GOTO LINK	0,	1
END


@killed_first_wave
	MUSIC graveyard.mid
	1: Those were lowly serfs!
	1: Let's see if you can truly show your worth.
	FIGHT 2, 2, 2, 2
	IF WIN, @killed_second_wave
	GOTO LINK	0,	1 	
@killed_second_wave
	MUSIC graveyard.mid
	1: Bah! Very well...
	1: Skeleton Lords, on my signal, unleash HELL!
	FIGHT 50, 50, 50, 50
	IF WIN, @killed_third_wave
	GOTO LINK	0,	1
	 @killed_third_wave
	MUSIC graveyard.mid
	1: What? You beat my skeletal horde?
	1: Very well. I shall fight you MYSELF! But be warned!
	1: I will tear at your very soul, and drive you insane!
	1: This is much more than just a game!
	MOVE 1,	0,	0,	1
	FIGHT2	100
	IF WIN, @killed_summoner
	1: You will NEVER win!
	1: Hahahahahahaha...A pox upon you and your kin!
	1: You are little more than a %3
	GOTO LINK	0,	1
END

@killed_summoner
	MUSIC graveyard.mid
	1: NO!
	1: It's not what you think!
	1: I'm NOT the kind of person you think I am!
	1: I'm not the anti-Christ or the Iron Man!
	GIVE T101
END
;-----------------------------------------------------------
SCENE	9 chambre, SCENE, "King's Chambre", 0, 0
	THEME	0
	MUSIC	king2.mid
	ACTOR	1, "King Theodosius",	king2,	1,	25,	90
	IF T105, @help_church_quest
	IF T104, @finish_reciful_quest
	IF T103, @on_reciful_quest
	GOTO @start_reciful_quest
END

@start_reciful_quest	
	GIVE L1
	GIVE M1000
	GIVE H1000
	1: Why hello. You must be %2!
	1: Yes, King Thengel told me all about your great deeds.
	1: You are here to help us; for which I give thanks.
	1: And it couldn't happen at a better time.
	1: There is a creature in the castle cellar named Reciful, and he's drinking our wine.
	1: Worse still, he's very hot-headed.
	1: For many a death is he credited.
	1: I have faith that you can defeat him...please continue.
	GIVE T103
	1: Come back to get healing if he buries his axe in you.
END

 @on_reciful_quest
	GIVE L1
	GIVE M1000
	GIVE H1000
	1: I see you are working hard to kill this creature.
	1: Should you beat Reciful, I shall recommend you to a preacher...
END


@finish_reciful_quest
	GIVE L1
	GIVE M1000
	GIVE H1000
	1: I can't believe it! It happened so fast!
	1: But now our supplies of bread and wine will last!
	1: I don't know how I can ever repay...
	1: But, take this armor, and be away.
	GIVE I801
	GIVE T105

@help_church_quest
	GIVE L1
	GIVE M1000
	GIVE H1000
	1: I know in the south a man needs aid.
	1: He is the priest of the Enruobso Church, but he isn't well-paid.
	1: He cannot afford help; he needs yours! Go to him!
	1: Believe me, I'm not just sending you out on a whim!
END

;---------------------------------------------------------
SCENE 10 underground, SCENE,	"Reciful's Lair",	0,	0
	THEME	0
	MUSIC	demon.mid
	IF T104, @finish_reciful_quest
	ACTOR	1, "Reciful",	demon,	1,	25,	90
	1: Ah, this is wonderful wine! Wonderful bread!
	1: What, ho! An intruder! An event that I truly dread!
	H: Hand over the bread and the wine!
	1: You pathetic swine!
	1: Do you realize who I am?
	1: For thou, the apocalypse is at hand!
	H: I knowest not of mine doom, only of mine life!
	1: Then thou knowest only of pain and strife!
	1: Leave me now, to my food and my drink.
	H: Should thou live? This I do not think!
	1: You will fight me, you %3 of a #<g.race>?
	H: I shall kill you, by my hand!
	MOVE 1, -10, -10,	1
	FIGHT2 101
	IF WIN, @killed_reciful
	H: I was not prepared, I shall return!
	1: Off with ye now, thou makest mine stomach churn!
END

@killed_reciful
	1: Strong art thou; death shall I know.
	H: I have proven my strength! What, ho!
	GIVE T104
END

@finish_reciful_quest
	N: Nobody is here, the demon is slain.
	N: Now leave at once; return to the game!
END

;---------------------------------------------------
SCENE	11 church, SCENE,	"Enruoboso Church", 0,0
	THEME	0
	MUSIC	church.mid
	ACTOR	1,	"Priest",	townsmen,	1,	25,	90
	POSE	1
	IF T108+I802, @finished_church_quest
	IF T108-I802, @finish_church_quest_2
	IF T107, @finish_church_quest
	IF T106, @on_church_quest
	1: You, young one, are you here to help?
	ASK 9999
	IF YES, @start_church_quest
	1: Then go on your way, you pagan Celt!
END

@start_church_quest
	1: Wonderful! It is just as I felt!	
	1: A creature called Natas has entered the shrine!
	1: He is a threat to myself and all of mankind!	
	1: The WarpedShrine you must enter, to kill this foul beast.
	1: When he is slain, we'll have a fine feast!
	GIVE T106
END

@on_church_quest
	OFFER 1, 2, 3, 4, 5, 6, 7, 8, 9
	1: What are you waiting for; be on your way!
	1: Hurry now; keep Natas at bay!


END

@finish_church_quest
	OFFER 1, 2, 3, 4, 5, 6, 7, 8, 9
	1: You've defeated the visitor from underground.
	1: Tales of your deeds have been going around!
	1: For this you deserve a reward most great.	
	1: I'll give it to you now, before you become irate.
	1: That you killed such a beast is still hard to believe.

	1: The "Klicktack's Soldier" is what you recieve.		
	1: Listen closely; it's quite a tale.
	GOTO SCENE 100
END

@finish_church_quest_2
	OFFER 1, 2, 3, 4, 5, 6, 7, 8, 9
	BKGND church.jpg
	1: Here is the figure I promised to thee.
	GIVE I802
	1: Take care of it for me.
END

@finished_church_quest
	OFFER 1, 2, 3, 4, 5, 6, 7, 8, 9
	1: Thanks for doing my quest. I'll see you later.
END

;------------------------------------------------------
SCENE 12 underground, SCENE, "Warped Shrine", 0, 0
	THEME	0
	MUSIC	demon.mid
	IF T107, @finish_church_quest
	ACTOR	1,	"Natas",	demon,	1,	25,	90
	POSE	1,2,3
	1: An intruder, indeed. Dare you defy my power?
	1: I grow stronger now with every hour!
	H: As do I, for it is you who I shall kill.
	1: You kill me? Hah! Do you REALLY think you will?
	1: En guarde! Touche!
	1: I shall give you an early grave!

	MOVE 1,	-100,-100,1
	FIGHT2	102
	MOVE 1,	25,90,1
	IF WIN, @killed_natas
	1: You shall never defeat a foe such as I.
	1: Hahahaha! I am too strong! Goodbye!
END

@killed_natas
	H: I've vanquished my enemy, now back to the priest.
	1: You may have killed me, but I won't be the LAST beast!
	GIVE T107
END

@finish_church_quest
	N: You've already killed the evil beast.
END

;----------------------------------------------------
SCENE 13 underground, SCENE, "Elzon's Cave", 0, 0
	THEME	0
	MUSIC	demon.mid
	IF T110, @finish_elzon_quest
	ACTOR	1, "Elzon", demon, 1, 25, 90
	POSE	1,2,3
	1: You think you can beat me?
	1: Have at you!
	MOVE 1, -100,-100,1
	FIGHT2 103
	IF WIN, @killed_elzon
	MOVE 1, 25, 90
	1: You are no match for me!
	1: Now go back to your shanty!
END

@killed_elzon
	1: You have defeated me, but my brothers are stronger indeed!
	GIVE T110
END


@finish_elzon_quest
	N: You've already killed the most evil demon.
END
;
;---------------------------------------------
; Act 2--Mientaka-Elmsea
;	200,"Destroy the pirates!"
;	201,"You defeated the first wave of pirates."
;	202,"You defeated the second wave of pirates."
;	203,"You defeated the third wave of pirates."
;	204,"Mientaka appears...kill him!"
;	205,"You killed Mientaka."
;	206,"You now have access to the next island."
;-------------------------------------------------------
SCENE 14 port, SCENE, "Port", 0, 0
	THEME 0
	MUSIC travel.mid
	IF T110, @sail_away
	N: We are closed right now, due to Daemon activity.
END

@sail_away
	ACTOR	1, "Salty Sailor", sailor, 1, 25, 90
	IF T205+T206, @goto_next_island
	IF T204, @fight_mientaka
	IF T203, @fight_mientaka
	IF T202, @fight_pirates_3
	IF T201, @fight_pirates_2
	IF T200, @fight_pirates
	1: Argh, be ye come t' sail me seas?
	1: Or be ye a landlubber; the water makes y' tremble at ye knees...
	1: Aye, I kin sail ye t' the next isle.

	1: I do 't fer free, aye.
	1: Because the Daemon was slew by ye.
	1: Are ye prepared fer the jouney ahead?
	ASK 9999
	IF NO, @do_not_sail
	1: Argh, then off we be.
	GIVE T200
	GOTO @fight_pirates
END

@do_not_sail
	1: Argh, come back when ye be ready.
END

@fight_pirates
	1: Argh, pirates be a' comin'!
	1: I be outta here...me fightin' ain't what it used t' be!
	MOVE 1, -100,-100,1
	FIGHT2 3, 3, 3, 3
	IF LOSE, @goto_exit
	GIVE T201
	GOTO @fight_pirates_2
END

@fight_pirates_2
	MUSIC	travel.mid
	FIGHT2 52, 52
	IF LOSE, @goto_exit
	GIVE T202
	GOTO @fight_pirates_3
END

@fight_pirates_3
	MUSIC	travel.mid
	FIGHT2	104
	IF LOSE, @goto_exit
	GIVE T203
	GOTO @fight_mientaka
END

@fight_mientaka
	GIVE T204
	MUSIC	travel.mid
	FIGHT2	105
	IF LOSE, @goto_exit
	GIVE T205
	GIVE T206
	GOTO @goto_next_island
END

@goto_next_island
	MOVE 1, 25, 90
	1: Argh...ye bested the pirates...and Mientaka, too...
	1: I be sailin' ya to the next island now, if ye want...
	1: How about it, can I sail ya?
	ASK 9999
	IF YES, @act_iii
	1: Argh, later then.
END

@act_iii
	1: Alright, then off we be.
	GOTO LINK 5, 0
END

@goto_exit
	GOTO EXIT
END
;
;---------------------------------------------------------
;
; Act 3--Onimus-Quendibar
;	300,"You must save Penelope."
;	301,"You rescued Penelope."
;	302,"You now have the IsenSword."
;	303,"Recover the statue of Mientaka."
;	304,"You recovered the statue."
;	305,"You were rewarded with two ability coins."
;	306,"Kill Onimus' gaurds."
;	307,"You have slain Onimus' gaurds."
;	308,"You have access to Onimus' lair."
;	309,"Defeat Onimus."
;	310,"Onimus has been killed."
;	311,"You now have access to Hell."
;------------------------------------------------------------
SCENE 15 port, "Port",	0,	0
	THEME	0
	MUSIC	travel.mid
	ACTOR	1, "Salty Sailor", sailor, 1, 25, 90
	1: Argh, well...here we be, across the Elm-Sea.
	1: Now ye can continue yer quest to become a mighty pirate!
	H: Um...that isn't my quest...I'm trying to kill the Daemons.
	1: Yessir, a mighty pirate ye be...
	1: Anyway; do ye want to be goin' to Menzix?
	ASK 9999
	IF YES, @go_to_menzix
	1: Arg...
END

@go_to_menzix
	1: Arg, then I be takin' ye.
	GOTO LINK	0,	9
END	

;-----------------------------------------------------
SCENE 16 castle, "King's Chambre",	0,	0
	THEME	0
	MUSIC	quendibar.mid
	ACTOR	1,	"King Hetfield",	king,	1,	25,	90
	IF T302, @start_statue_quest
	IF T301, @finish_penelope_quest

	IF T300, @on_penelope_quest
	1: You there!
	H: Me?
	1: Yes, you! You are the hero they speak of. I've heard of your deeds on Menzix.
	1: Perhaps you can help me.
	H: What troubles you, good King of Quendibar?
	1: My sweet daughter, Penelope, has been kidnapped.
	1: She was kidnapped by the Green Elf!
	1: Please...save her.
	1: Unfortunately, we don't know where the Green Elf's hideout is...
	1: He lives in the heart of the southern desert, in a deep catacomb.
	1: If you can find his lair and defeat him, I would reward you greatly.
	1: Of course, you'll need boots to get through the desert.
	1: Here...take my Sand Boots.
	GIVE T300
	GIVE I803
	1: Please rescue her...
END

@on_penelope_quest
	GIVE L1
	GIVE H10000
	GIVE M10000
	1: Please save my daughter....
END

@finish_penelope_quest
	GIVE L1
	GIVE M10000
	GIVE H10000
	ACTOR	2, "Penelope", townsmen, 5, 50, 90
	1: Welcome, %2!
	1: You've rescued my lovely daughter!
	1: So, you must have met the Green Elf.
	1: Bizarre little creature, isn't he?
	H: Indeed. But he's quite the little fighter.
	1: Well, you can't be THAT short and THAT green, and live to be THAT old...
	1: Unless you have the skills to back it up.
	H: I suppose so.
	1: Well, as I promised, I will reward you.
	1: With THIS! The IsenSword!
	GIVE T302
	GIVE I804
	1: It's quite a powerful sword, I think you'll find.
	1: Even if you don't know how to use a sword, it may yet come in handy later.
	1: Well, be on your way, %2! And thanks again!
END

@start_statue_quest
	GIVE L1
	GIVE M10000
	GIVE H10000
	ACTOR	2, "Penelope", townsmen, 5, 50, 90
	1: You know, I've heard about a certain art collector in the eastern desert.
	1: Why don't you see if he has some work for you?
END

;-----------------------------------------------------
SCENE 17 underground, "Green Elf's Cavern", 0, 0
	THEME	0
	MUSIC	green.mid
	IF T301, @killed_green_elf
	ACTOR	1,	"Green Elf?",	yoda,	1,	-100,	-100
	1: Hahahaha...close, you are...but not close enough!

END
 @killed_green_elf
	N: There's nobody here.
END

;-----------------------------------------------------
SCENE 18 underground,	"Green Elf's Cavern",	0,	0
	THEME	0
	MUSIC	green.mid
	IF T301, @killed_green_elf
	ACTOR	1,	"Yoda",		yoda,	1,	-100,	-100
	ACTOR	2,	"Penelope",		townsmen, 4, 50, 90
	ACTOR	3,	"Green Elf",	yoda,	1,	25,	90
	SELECT	2
	FACE 2, 0
	H: Green Elf! Let Penelope go, or I shall be forced to kill you!
	3: Green Elf am I not.
	MOVE 3, -100, -100, 1
	MOVE 1, 25, 90, 1
	1: Yoda, my name is.
	1: Teach you in the ways of the force, shall I?
	H: Wha--YODA???
	H: Well...release Penelope, just the same.
	1: Release? Captured, she is not.
	H: Then...why is she tied up...
	1: Use the force to untie herself, she must.
	H: ...I don't think I understand...
	1: Then die, you must! The dark side clouds you!
	H: What? Dark side? What are you talking about??
	MOVE 2, -100, -100, 1
	MOVE 1, -100, -100, 1
	FIGHT2	106
	IF WIN, @kill_green_elf
	MOVE 1, 25, 90, 1
	MOVE 2, 50, 90, 1
	1: Too strong for you, am I.
	1: Train, you must...in the ways...of the Jedi.
END

@kill_green_elf
	MOVE 1, 25, 90, 1
	MOVE 2, 50, 90, 1
	1: Senile, in my old age, have I got.
	1: Untie Penelope, I will.
	1: Use the force, she cannot.
	SELECT 2
	POSE 	5
	2: I'm free!
	MOVE 2, 150, 90
	GIVE T301
	1: Want Jedi training, do you, %2?
	H: No, that's quite alright...
	1: Very well.
	1: Remember, feel the force flowing through him, a Jedi can.
	1: Cloud everything, the dark side does. 
END 

@killed_green_elf
	N: There's nobody here.
END

;-----------------------------------------------------------------
SCENE	19 art, "Art Collector's", 0, 0
	THEME	0
	MUSIC	art.mid
	ACTOR	1, "Art Collector", townsmen, 2, 25, 90
	POSE 2, 3
	IF T305, @finished_statue_quest
	IF T304, @finish_statue_quest
	IF T303, @on_statue_quest
	1: Hey man, how's it going?
	1: I collect art, man. That's my groove. Can you dig it?
	1: I need a statue of that Mientaka cat, baby.
	1: I hear there's a monster somewhere that has one.
	1: Man, if you can get me the statue, I'll give you a groovy prize.
	1: Get down with the crazy dance vibes, man.
	1: I'll even come with you, dig?
	SET discoLevel, "31"
	SET discoExpNeed, "10000"
	SET discoExpNeed1, "10000"
	GIVE T303
END

@on_statue_quest
	1: Man, you're one crazy cat. We don't need to be here, dig?
	1: Let's just find my statue.
END

@finish_statue_quest
	1: Hey, you're one cool cat, baby.
	1: You got me my statue.
	1: I'll give you some hot tokens to raise your stats, man.
	1: It's far out and groovy, so dig it.
	GIVE I10
	GIVE I10
	GIVE T305
END
  @finished_statue_quest
	1: Hey, you got my statue, man.
	1: I don't need your help any more.
	1: But you can just chill around my pad if you want.
	1: Psychadelic, man.
END

;-------------------------------------------------------
SCENE 20 gate, "Onimus Lair",	4,	0
	THEME	7
	MUSIC	hell.mid
	ACTOR	1, "Onimus", demon, 1, 50, 80
	IF T309, @lair
	1: You! You are %2, the one who killed my brothers!
	1: You won't get quite as far with me!
	MOVE 1, -100, -100, 1
	H: He moved into the depths of his lair...
	H: I'll never find him now...
	H: Hey! Who's that?
	GIVE T306
	FIGHT2	7,7
	IF WIN, @won_onimus_guard
	IF LOSE, @lost_onimus_guard
END

@lost_onimus_guard
	H: I lost...shoot...I need to find some way to beat those guards...
END

@won_onimus_guard
	H: Now I can go into the murky depths of Onimus' Lair...I sure hope I can find him...
	GIVE T307
	GOTO SCENE 21
END

@lair
	GOTO SCENE 21
END

;--------------------------------------------------
SCENE	21	lair,	"Onimus Lair",	4,	0
	THEME	7
	MUSIC	hell.mid
	ACTOR	1, "Onimus", demon, 1, 50, 70
	SELECT	1
	IF T309, @caught_onimus
	IF T310+311, @killed_onimus
	GOTO @chase
END

@chase
	MOVE	1, 50, 70, 1
	IF T309, @caught_onimus
	COMPARE #<chaseDemonNumber>,	"15"
	IF=, @caught_onimus
	IF>, @caught_onimus
	SET chaseDirection, "%R3"
	COMPARE #<chaseDirection>, "2"
	IF=, @chase_forward
	IF<, @chase_left
	IF>, @chase_right
END

@chase_forward
	MOVE 1, 50, 20, 	1
	WAIT 1
	MOVE 1, -100, -100, 1
	ADD chaseDemonNumber, "1"
	SET demonDirection, "2"
	GOTO @select_direction
END

@chase_left
	MOVE	1, 20, 70, 1
	WAIT 1
	MOVE	1, -100, -100, 1
	ADD	chaseDemonNumber, "1"
	SET demonDirection, "1"
	GOTO @select_direction
END


@chase_right
	MOVE	1, 80, 70, 1
	WAIT 1
	MOVE	1, -100, -100, 1
	SET demonDirection, "3"
	ADD chaseDemonNumber, "1"
	GOTO @select_direction
END

@select_direction
	MENU "Go Left=@choose_left","Go Straight=@choose_forward","Go Right=@choose_right"
END

@choose_left
	COMPARE	#<demonDirection>, "1"
	IF=, @chase
	H: I lost him...I'll have to start over again...
	SET chaseNumber, "0"
	GOTO EXIT
END

@choose_right
	COMPARE #<demonDirection>, "3"
	IF=, @chase
	H: I lost him...I'll have to start over again...
	SET chaseNumber, "0"
	GOTO EXIT
END

@choose_forward
	COMPARE #<demonDirection>, "2"
	IF=, @chase
	H: I lost him...I'll have to start over again...
	SET chaseNumber, "0"
	GOTO EXIT
END

@caught_onimus
	GIVE T309
	MOVE	1, 30, 80, 1
	1: So you finally caught me.
	1: Have at you!
	MOVE	1, -100, -100, 1
	FIGHT2 107
	IF WIN, @killed_onimus
	IF LOSE, @lost_onimus
END

@killed_onimus
	GIVE T310
	GIVE T311
	GOTO LINK	7, 0
END

@lost_onimus
	1: Hah! You need to train harder if you want to kill ME!
	GOTO EXIT
END

;--------------------------------------------
; Act 4--Elzikso-Hell
;	400,"Kill Elzikso."
;	401,"You have defeated Elzikso!"
;	402,"You now have access to the Throne Room."
;----------------------------------------------
;
SCENE 22 lair, SCENE, "Elzikso", 0, 0
	THEME	0
	MUSIC	hell.mid
	ACTOR	1, "Elzikso", demon, 1, 25, 90
	IF T401+T402, @killed_elzikso_2

	1: You think you can win? Doubtful!
	GIVE T400
	MOVE 1, -100, -100, 1
	FIGHT2 108
	IF WIN, @killed_elzikso
	IF LOSE, @lost_elzikso
END

@killed_elzikso
	GIVE T401
	1: NO!
	GIVE T402
	GOTO LINK 8, 0
END

@killed_elzikso_2
	GOTO LINK 8, 0
END

@lost_elzikso
	1: You'll have to be stronger than that to kill me!
END

; Minigames
#include minigames.txt

; Hunting Grounds
#include Hunt.txt

; Bank
#include Bank.txt

;-------------------------------------
; Act 5--Gorgan-Shadowfaks
;	500,"Kill Gorgan."
;	501,"You have defeated Gorgan!"
;	502,"You have access to the Final Field."
;---------------------------------------
SCENE 28, shadowfaks,	"Gorgan",	0,	0
	THEME	0
	WEATHER	9
	ACTOR	1, "Gorgan",	demon,	1,	25,	90
	IF T502, @go_to_field
	IF T501, @gorgan_is_dead
	IF T500, @kill_gorgan
	1: You think you can defeat me?
	1: Even if you do destroy me, Olamu will surely kill you.
	H: Olamu?
	1: The GateKeeper, you fool!
	1: He has mastered the black arts, and is sure to triumph against you!
	H: I thought he was appointed to GUARD the gate! Why would he want to fight me?
	1: You FOOL! Olamu OPENED the Gate for us to pass into your world!
	1: He'll never fight you--I'll kill you before he gets the chance!
	MOVE 1, -100, -100, 1
	GIVE T500
	GOTO @kill_gorgan
END

@kill_gorgan
	FIGHT2 109
	IF WIN, @killed_gorgan
	1: You will never win!
	WAIT 1.0
	GOTO EXIT
END

@killed_gorgan
	1: NO!
	GIVE T501
	GOTO @gorgan_is_dead
END

@gorgan_is_dead
	N: Congratulations. You have fared well thus far.
	N: But...can you best the final Daemon?
	N: You now have access to the final field.
	N: You can visit any island you choose from within your camps from here on.
	N: You may continue...
	WAIT 2.0
	GOTO @go_to_field
END

@go_to_field
	GOTO LINK 9, 0
END
;---------------------------------------------------
; Act 6--Final Field
;	600,"Kill Olamu!"
;	601,"Olamu has breathed his last."
;	602,"Congratulations! You beat the main quest!"
;---------------------------------------------------
SCENE 29, field, "Field",	0,	0
	THEME	0
	MUSIC	Field.mid
	IF T601+T602, @goto_exit
	ACTOR	1,	"Olamu",	mirror,	1,	25,	90
	IF T600, @fight
	1: Welcome, %2, to my home. Welcome to Vendetta.
	H: The jig is up, Olamu. You're going down!
	1: I'm afraid not, %2. I cannot allow that to happen.
	1: You will either embrace my power, or you will be destroyed.
	H: I will never bow to you!
	1: Then I'm afraid I shall have to kill you.
	GIVE T600
	GOTO @fight
END

@fight
	MOVE 1, -100, -100, 1
	FIGHT2 110
	IF WIN, @killed_olamu
	1: You will never win.
END

@killed_olamu
	1: Haha! Fool! Death means nothing to me!
	1: My spirit will ALWAYS remain!
	GIVE T601
	GIVE T602
	GOTO 1, 0
END

@goto_exit
	GOTO EXIT
END
;--------------
; Cutscenes
#include Cutscenes.txt

-SCENES

; Note: You should add a comment to the end of the file, since otherwise an old bug might rise
; up and smite you!