;scenes 32*, 33*, 34*, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50
;tokens 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30


SCENE 34, desert01, scene, "Border", 0, 0, 0
IF V30 @enter1
N: The howl of the desert winds keep weaklings from entering.
END
@enter1
IF E863 @enter2
N: Your feet cannot withstand the heat of the desert without special boots.
END
@enter2
EJECT "V30"
GOTO LINK 21, 0
END

SCENE 32, deserttown, scene, "Desert Shop", 0, 0, 0
ACTOR 1, "Shop Stall Owner", joshmiscellaneous, 28, 24, 82
SEL 1
OFFER 131, 211, 261, 311, 361, 411, 457, 511, 561, 611, 662, 663, 664, 715, 716, 717, 762, 812, 862, 911, 961
' Not sure what brings you here but we have some good gear.
' Tad bit expensive, but you won't find it anywhere else.
END

SCENE 33, deserttown, scene, "Desert Guard", 0, 0, 0
ACTOR 1, "Desert Guard", npcs, 12, 24, 82
SEL 1
IF T17 @back
IF T16 @kill
IF V30 @scorps
' Get away from me you weakling.
END
@scorps
' Finally an adventurer that isn't so pathetic.
' I need some help, I could get in trouble if my Elder found out.
' Can you help me?
ASK 9999
IF NO @ass
' Good.
' The desert is a harsh land as many people know.
' We try to keep the animals from escaping..
' A lot of Ground Crawlers have left the desert..
' If you could go and kill 50 of them I'm sure you could drive them back.
' This might not be easy, but I'm sure you could do it.
' Good luck %l.
GIVE T16
END
@ass
' Then I have no time for you.
END
@kill
COMPARE #<KM.35>, "50"
IF= @done
IF> @done
' You have only killed #<KM.35>.
' I need you to go kill more.
END
@done
' Good job, they are starting to move back into Gibdos.
' Take these boots, you can use them to enter the Desert.
' You seem worthy..
GIVE I863
GIVE T17
END
@back
' Greetings %1.
' Your welcome in Gibdo's whenever you want.
END

SCENE 35, deserttown, scene, "Desert Info", 0, 0, 0
ACTOR 1, "Civilian", joshmiscellaneous, 28, 24, 82
IF T29 @wow
' Hey heard about the Pionscor King?
' It's a legendary beast that lives somewhere out in the desert.
' No one is quite sure where..
' As we dug out the pathways in the desert we found the Pionscor Queen..
' The king was nowhere to be found..
END
@wow
' You have seen the Pionsorc King?!
' That's amazing!
' I envy you %1...
END

SCENE 36, deserttown, scene, "Desert Healer", 0, 0, 0
ACTOR 1, "Shaman", joshRoyalty, 23, 24, 82
OFFER 1, 2, 3, 4, 5, 6, 10, 11, 12, 13, 14, 15, 60, 61, 62, 63, 64, 65
IF DEAD @dd
GIVE H5000
GIVE M5000
' Your welcome back here to heal whenever you want..
END
@dd
' I sensed you coming..
' Allow me to revive you..
WAIT 2
GIVE L1
GIVE H5000
GIVE M5000
' Keep fighting strong..
' The desert shows no mercy..
END

SCENE 37, deserttown, scene, "Graverobber", 0, 0, 0
IF T20 @end
ACTOR 1, "Graverobber", joshmiscellaneous, 28, 24, 82
IF T19 @dug
IF T18 @digdamit
' Hey..
' Take this shovel..
HOST_GIVE I21
HOST_GIVE T18
' Goto the grave in the desert..
' You can find TREASURE!!
END
@digdamit
' You haven't done the job yet...
' Get outta here!!
WAIT 1
GOTO EXIT
END
@dug
' Have you done the job yet?
H: Yes.. Not sure why you told me to dig there..
' No reason at all...
' Did you find anything strange?
H: Yeah, a strange relic of some sort..
' Hand it over!
N: You hand him the Strange Relic.
' Mine!
' Hahaha!
MOVE 1, -50, 82
HOST_GIVE T20
HOST_TAKE I21
HOST_TAKE I22
END
@end
END

SCENE 38, desert02, scene, "Grave", 0, 0, 0
IF T24 @down
IF T23 @blow
IF T19 @dug
IF T18 @dig
N: A giant tombstone lays infront of you.
END
@dig
H: I'm guessing this is where he wanted me to dig..
WAIT 2
H: Whats this..
WAIT 2
N: You found 2 piles of Brass Coins!
HOST_GIVE I32.2
HOST_GIVE T19
HOST_GIVE I22
H: A little bit more, maybe I'll find more..
WAIT 2
N: You find a strangle relic?
H: What is this? Maybe this is what he wanted..
H: I don't think I should dig anymore..
END
@dug
N: A giant tombstone lays infront of you.
N: And a giant hole..
END
@blow
N: You set up some gunpowder, and make explosives.
N: 3...
WAIT 1
N: 2...
WAIT 1
N: 1...
WAIT 1
ACTOR 1, "", buttons, 3, 41, 46
WAIT .3
SEL 1
POSE 4
ACTOR 2, "", buttons, 3, 66, 66
WAIT .3
SEL 1
POSE 5
SEL 2
POSE 4
ACTOR 3, "", buttons, 3, 25, 73
ACTOR 1, "", , , ,
WAIT .3
SEL 2
POSE 5
SEL 3
POSE 4
ACTOR 2, "", , , ,
WAIT .3
SEL 3
POSE 5
WAIT .5
ACTOR 3, "", , , ,
GIVE T24
GOTO @down
END
@down
EJECT "T24"
COMPARE #<num.peopleInScene>, "1"
IF= @more
GOTO LINK 29, 0
END
@more
N: You cannot enter here alone.
END

SCENE 39, deserttown, scene, "Tamer", 0, 0, 0
ACTOR 1, "Tamer", joshmiscellaneous, 29, 24, 82
SEL 1
OFFER 3002, 3003, 3004, 3005, 3006
' Tamed monsters to keep as pets.
' I won't ensure your safety.
ASK 9999
IF Qfood @food
END
@food
' Pet food here.
OFFER 40, 41, 42, 43, 44
END

SCENE 40, deserttown, scene, "Crafter", 0, 0, 0
ACTOR 1, "Craftsmen", joshmiscellaneous, 28, 24, 82
SEL 1
MISSiON 103, 104, 105
IF T21 @powder
@back
' Special Bone armor crafting here.
' No refunds for someting you can't equip.
END
@powder
IF T22 @back
H: Do you happen to have gunpowder?
' Yes actually I do. Need some?
H: Yes!..Yes please.
' I would give you but some but its not cheap.
H: Perhaps a trade?
' I don't need money.. Hmm..
' I'm not very strong so maybe you could get me 50 tokens?
H: Ok..
COMPARE #<token>, "50"
IF< @powder123
GOTO @powder2
END
@powder123
' Return when you have them.
END
@powder2
' Wanna give me 50 of your tokens?
ASK 9999
IF YES @powder3
' Then why did you come back with them?
END
@powder3
SUB token, "50"
HOST_GIVE T22
' I'm in a good mood so I can also increase your trophy bag size while your here.
H: Thanks.
ADD num.TrophyBagHeight, "1"
END

SCENE 41, deserttown, scene, "Warner", 0, 0, 0
ACTOR 1, "Civilian", joshmiscellaneous, 28, 24, 82
SEL 1
' Becareful around these parts, the Pionsorc Queen lives around here.
' She only shows up after you kill many of her guardians.
' If you fight her be very careful, but if you deafeat her, the gear you find is wonderful.
END

SCENE 42, deserttown, scene, "Center", 0, 0, 0
ACTOR 1, "Commander", joshmiscellaneous, 28, 24, 82
SEL 1
' Greetings %1.
' If you need anything just right click me.
END
@eventactorclick1
MENU "Claim Rewards=@cl", "Revive=@re", "Info=@info", "Balance=@bal", "Exchange=@ex"
END
@bal
' You have #<token> tokens.
END
@info
' Lately undead have been coming from the South.
' Trying to claim the rest of the desert as a giant graveyard.
' This, of course we do not want to happen.
' We don't have an army so right now we are enlisting the help of strangers.
' You will find remains and depending on the monsters strength you can trade those for tokens.
END
@re
' A revive on the frontline will cost 5 tokens.
ASK 9999
IF yes @conti1
END
@conti1
COMPARE #<token>, "5"
IF< @broke
SUB token, "5"
GIVE L1
GIVE H5000
GIVE H5000
' There you go %1.
END
@cl
MENU "Raider Helmet=@cl1", "Marauder Armor=@cl2", "Storm Boots=@cl3", "Wind Gloves=@cl4", "Silver Raider Helm=@cl5", "Silver Marauder Armor=@cl6", "Silver Storm Boots=@cl7", "Silver Wind Gloves=@cl8", "Gold Raider Helm=@cl10", "Gold Marauder Armor=@cl11", "Gold Storm Boots=@cl12", "Gold Wind Gloves=@cl13", "Teleport to Gibdo's Spell=@cl9"
END
@cl1
SET item, "4100"
SET tokneed, "100"
SET weight, "Medium"
GOTO @claim
@cl2
SET item, "4102" 
SET tokneed, "100"
SET weight, "Heavy"
GOTO @claim
@cl3
SET item, "4104"
SET tokneed, "100"
SET weight, "Light"
GOTO @claim
@cl4
SET item, "4106"
SET tokneed, "100"
SET weight, "Light"
GOTO @claim
@cl5
SET item, "4101"
SET tokneed, "1000"
SET weight, "Medium"
GOTO @claim
@cl6
SET item, "4103"
SET tokneed, "1000"
SET weight, "Heavy"
GOTO @claim
@cl7
SET item, "4105"
SET tokneed, "1000"
SET weight, "Light"
GOTO @claim
@cl8
SET item, "4107"
SET tokneed, "1000"
SET weight, "Light"
GOTO @claim
@cl10
SET item, "4108"
SET tokneed, "10000"
SET weight, "Medium"
GOTO @claim
@cl11
SET item, "4109"
SET tokneed, "10000"
SET weight, "Heavy"

GOTO @claim
@cl12
SET item, "4110"
SET tokneed, "10000"
SET weight, "Light"
GOTO @claim
@cl13
SET item, "4111"
SET tokneed, "10000"
SET weight, "Light"
GOTO @claim
@cl9
IF S261 @cl
COMPARE #<token>, "25"
IF< @broke
' This costs 25 tokens, are you sure you want to buy %s261, spell?
ASK 9999
IF YES @conti11
END
@conti11
SUB token, "25"
HOST_GIVE S261
END
@claim
' You have chosen:
' %i#<item>, it costs #<tokneed>, and is #<weight>.
' Are you sure you wish to buy it?
ASK 9999
IF YES @conti2
' Very well.
END
@conti2
COMPARE #<token>, #<tokneed>
IF< @broke
SUB token, #<tokneed>
HOST_GIVE I#<item>
' There you go, one %i#<item>.
END
@broke
' You don't have enough tokens.
END
@ex
SET tearn, "0"
SET troex, "0"
IF z21 @aa
IF z22 @ab
IF z23 @ac
IF z24 @ad
IF z25 @ae
IF z26 @af
IF z27 @ag
IF z28 @ah
IF Z29 @ai
@do
END
@aa
ADD troex, "1"
ADD tearn, "1"
ADD token, "1"
TAKE Z21
IF Z21 @aa
N: You trade #<troex> %z21's for #<tearn> tokens.
GOTO @ex
@ab
ADD troex, "1"
ADD tearn, "2"
ADD token, "2"
TAKE Z22
IF Z22 @ab
N: You trade #<troex> %z22's for #<tearn> tokens.
GOTO @ex
@ac
ADD troex, "1"
ADD tearn, "3"
ADD token, "3"
TAKE Z23
IF Z23 @ac
N: You trade #<troex> %z23's for #<tearn> tokens.
GOTO @ex
@ad
ADD troex, "1"
ADD tearn, "5"
ADD token, "5"
TAKE Z24
IF Z24 @ad
N: You trade #<troex> %z24's for #<tearn> tokens.
GOTO @ex
@ae
ADD troex, "1"
ADD tearn, "7"
ADD token, "7"
TAKE Z25
IF Z25 @ae
N: You trade #<troex> %z25's for #<tearn> tokens.
GOTO @ex
@af
ADD troex, "1"
ADD tearn, "9"
ADD token, "9"
TAKE Z26
IF Z26 @af
N: You trade #<troex> %z26's for #<tearn> tokens.
GOTO @ex
@ag
ADD troex, "1"
ADD tearn, "12"
ADD token, "12"
TAKE Z27
IF Z27 @ag
N: You trade #<troex> %z27's for #<tearn> tokens.
GOTO @ex
@ah
ADD troex, "1"
ADD tearn, "15"
ADD token, "15"
TAKE Z28
IF Z28 @ah
N: You trade #<troex> %z28's for #<tearn> tokens.
GOTO @ex
@ai
ADD troex, "1"
ADD tearn, "18"
ADD token, "18"
TAKE Z29
IF Z29 @ai
N: You trade #<troex> %z29's for #<tearn> tokens.
GOTO @ex

SCENE 43, desert01, scene, "Top Path", 0, 0, 0
SET repeat, "0"
@re2
#include aura.txt
IF R30 @f1
IF R45 @f2
FIGHT 53
IF lose @end
N: You found %z21.
GIVE Z21
GOTO @re
END
@f1
FIGHT 54
IF lose @end
N: You found %z22.
GIVE Z22
GOTO @re
END
@f2
FIGHT 55
IF lose @end
N: You found %z23.
GIVE Z23
GOTO @re
@end
END
@re
#include zerkerstyles.txt
COMPARE #<repeat>, "1"
IF= @re2
N: Repeat?
N: Type Auto if you want to auto repeat.
ASK 9999
IF Qauto @re3
IF YES @re2
END
@re3
SET repeat, "1"
GOTO @re2
END

SCENE 44, desert01, scene, "Center Path", 0, 0, 0
SET repeat, "0"
@re2
#include aura.txt
IF R30 @f1
IF R45 @f2
FIGHT 56
IF lose @end
N: You found %z24.
GIVE Z24
GOTO @re
END
@f1
FIGHT 57
IF lose @end
N: You found %z25.
GIVE Z25
GOTO @re
END
@f2
FIGHT 58
IF lose @end
N: You found %z26.
GIVE Z26
GOTO @re
@end
END
@re
#include zerkerstyles.txt
COMPARE #<repeat>, "1"
IF= @re2
N: Repeat?
N: Type Auto if you want to auto repeat.
ASK 9999
IF Qauto @re3
IF YES @re2
END
@re3
SET repeat, "1"
GOTO @re2
END

SCENE 45, desert01, scene, "Bottom Path", 0, 0, 0
SET repeat, "0"
@re2
#include aura.txt
IF R30 @f1
IF R45 @f2
FIGHT 59

IF lose @end
N: You found %z27.
GIVE Z27
GOTO @re
END
@f1
FIGHT 60
IF lose @end
N: You found %z28.
GIVE Z28
GOTO @re
END
@f2
FIGHT 61
IF lose @end
N: You found %z29.
GIVE Z29
GOTO @re
@end
END
@re
#include zerkerstyles.txt
COMPARE #<repeat>, "1"
IF= @re2
N: Repeat?
N: Type auto if you want to auto repeat.
ASK 9999
IF Qauto @re3
IF YES @re2
END
@re3
SET repeat, "1"
GOTO @re2
END

SCENE 46, black, cut, "Teleporting", 0, 0, 0
EJECT "V30"
EJECT "S261"
GOTO LINK 27, 0
END

SCENE 47, deserttown, scene, "Elder", 0, 0, 0
ACTOR 1, "Elder", npcs, 13, 24, 82
IF T29 @back4
IF T28 @donefinally
IF T27 @27notdone
IF T26 @shards
IF T25 @relicgot
IF T22 @hasp
IF T21 @getp
IF T20 @p2
' Greetings, you made it here alive so your worthy of the desert.
' My people unfortunately are barely surviving here.
END
@p2
' So it was you who dug up the Ancient Relic?
H: Yes, I did dig up something strange.
' Then it is you who will correct this.
' Did you give the relic to a strange person who lived in this town?
H: Yes, he ran off after I gave it to him.
' He most likely ran off to the grave where you got it.
H: Why?
' That relic was a key, I have kept it a secret.
' What it does, I'm not sure.
' He must have found out what it does, you must get to him and stop him.
' Go find some gunpowder and blow a way through the grave.
GIVE T21
H: Understood.
END
@getp
' Return when you get the gunpowder.
END
@hasp
' Great, now take the powder to the grave.
' What you will find under the grave, I'm not sure of, so bring a friend.
GIVE T23
END
@relicgot
' Amazing you found the Relic!
' I had my doubts for awhile.
' Did you find out what it was for by any chance?
H: No, he wouldn't tell me, then he attacked me.
' Well it does SOMETHING, but one thing he missed.
' In its current state its useless.
' We need to recharge it using crystal shards.
H: How many would you need?
' Oh, only about 20.
' For this job I can increase your trophy bag size.
H: Sweet.
ADD num.TrophyBagWidth, "1"
GIVE T26
' I will wait here until you get the shards.
END
@shards
IF Z20.20 @sharddone
' You still need to find me more shards.
END
@sharddone
' Good job now I will attempt to recharge the Relic.
TAKE Z20.20
TAKE I22
GIVE I24
' Suppose the journey was tough on you last time, take this new sleeping bag perhaps it will help.
GIVE I23
GIVE T27
' You should go back and try to use the relic where the graverobber was.
H: Alright.
' Just remember to bring a friend.
END
@27notdone
' Why are you waiting?
' That relic might be dangerous, who knows who else wants it.
END
@donefinally
' So you returned the relic?
H: Yes, it didn't seem to do much.
' Nothing happened? What a shame.
H: Well, a giant creature walked by... That's all.
' A giant creature?
H: Yea, a giant Pionsorc I think..
' A GIANT PIONSORC?!
' Could this be the legendary Pionsorc King?!
H: I didn't even think of that.. Wow..
' Leave it alone for now, allow me to think of a way to tame it.
' This could very well be the key taming the desert.
GIVE T29
' Take this 1000 gold as a token of my appreciation.
GIVE G1000
' It may not be much but we are poor..
END
@back4
' Greetings %1.
' We still haven't come up with a plan to tame the beast..
END

SCENE 48, dungeon05, scene, "Relic", 0, 0, 0
IF T28 @blank
IF T27 @relicplace
IF T25 @blank
ACTOR 1, "Graverobber", npcmonster1, 4, 24, 82
' Why did you come here?
H: That relic, whats it do?
' Nothing you need to know.
H: Any case I need it back!
' Not going to happen.
' /a whistles.
MUSIC "Battle.mid"
FIGHT2 36, 37, 38, 39
IF LOSE @end
POSE 2
' Fine I'll deal with you myself..
MOVE 1, -24, 82
WAIT 1
FIGHT2 502
IF LOSE @end
N: You grab the relic and run.
GIVE I22
GIVE T25
WAIT 1
GOTO EXIT
END
@end
MOVE 1, 24, 82
' Ha your pathetic.
END
@blank
END
@relicplace
N: You place the relic on the pedestal.
WAIT 2
N: Nothing seems to happen..
WAIT 1
SOUND "growl2.wav"
ACTOR 1, "", pion05, 1, 0, 82
SEL 1
MOVE 1, 200, 82
WAIT 1
H: What is this?!
WAIT 1
H: Might be best if I leave it alone...
TAKE I24
GIVE T28
END

;blank line