;

+CREDITS
Grim's Quest

by:Jared Gristina
Skins by:Serket
	
Programming by Synthetic Reality
Contact us on the web at:
http://www.synthetic-reality.com
-CREDITS



+STORY
:S 200
:C 255,255,0
|Grims Quest
:S 75
:C 255,255,255
|~~~
|by Jared Gristina
|Skins by Serket
|Programming by Van and Jared
|Classes by Serket
|Special thanks to our Server Sam AkA Ace
|and our beta testers,Moshe,Bluck,Pete,Dark wolf, ect...
|Dont complain if your not on here just tell me lol...
|~~~ 
:S 100
:C 204,153,0
Welcome to Grims Quest , a world of thieves brigands enchantments and everything cool, We are still in the beta stage,
 if you would like to help in the design process of this cool new world
message to the admin...:F Arial Italic
:C 255,0,0
Prepare yourself...
-STORY

;---------------------
; TERRAINS Section
; Up to 10 terrains (0-9) may be defined and then 'painted' onto maps.  Characters must
; possess the correct equipment to cross certain terrains.  Terrain 0 is always cross-able
; by all characters.
;
;	arg0	the terrain ID  0-9
;   	arg1	the name of the terrain (keep it short, it shows up on the terrain editor palette)
;	arg2	the damage inflicted on a character when walking on this terrain (negative heals)
;			NOTE: terrain damage not yet implemented.
;	arg3	(optional), a token number (0 not allowed) which allows travel over that terrain
;
+TERRAINS
;	arg0	arg1				arg2	arg3
;
	0,		"No Hindrance",		0,	0
	1,		"Lava",			10,	0
	2,		"Electricity",		10,	0
	3,		"",			0,	0
	4,		"Deep Water",		0,	0
	5,		"Clouds",		0,	0
	6,		"",			0,	0
	7,		"",			0,	0
	8,		"Healing",		-10,	0
	9,		"Impassable",		0,	0
-TERRAINS




+EQUIP
;	arg0	arg1
;	ID		Name

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




+THEMES

	20,		cavedrip,	campfire1,		10=drip1,10=bird1,10=splash1
;
-THEMES


	131072	0x00020000	// NO_PKREZ. PKers cannot use resurrection spells on others
+MAPS

#include maps.txt

-MAPS




+TOKENS

-TOKENS



+ELEMENTS
;	arg0	arg1				
;
	0,		"Life"		
	1,		"Water"			
	2,		"Nature"			
	3,		"Earth"			
	4,		"Death"		
	5,		"Fire"		
	6,		"Spirit"		
	7,		"Air"	

;
-ELEMENTS


+HANDS
;  
; arg0		arg1		arg2		arg3
;  ID		Name		Range		SoundFX
;
	0,		"Sword",	30,			"sword1.wav"
	1,		"Staff",	20,			"staff.wav"
	2,		"Bow",		100,		"sword8.wav"
	3,		"Music",	50,			"chirp4.wav"
	4,		"Fist",		20,			"fist.wav"
	5,		"Daggers",		80,			"dart.wav"
	6,		"Book",		70,			"chant6.wav"
	7,		"Spirit",	90,			"crow1.wav"
-HANDS


+ITEMS

; The actual item definitions, and documentation, are in this file:
#include items.txt

-ITEMS


+TROPHIES
; The actual trophy definitions, and documentation, are in this file:
#include trophies.txt
-TROPHIES


+SPELLS

; actual spell definitions, and documentation, are in this file:
#include spells.txt

-SPELLS


+MONSTERS

; actual monster definitions, and documentation, are in this file:
#include monsters.txt

-MONSTERS


+GROUPS

; actual groups, and documentation, are in this file
#include groups.txt

-GROUPS


+LEVELS

; actual character classes, levels, and documentation are in this file
#include levels.txt

-LEVELS




+SCENES
#include protection.txt

SCENE 0		town, town, "Grim's Quest", 2, 7

	THEME	1

	ACTOR	1,	"Hero", Hero, 32, 0, 60

	SEL		1


	POSE	32,32,32


	MOVE	1,	50, 60


	WAIT	1.0


	' Welcome to Grim's Quest.


	MOVE	1,	45, 60


	

	
	' If you are new then click on new to the bottom right.
	MOVE	1,	40, 75
	' create your character then click incarnate.
END

SCENE 1
	THEME
;	MUSIC   (no music in camp scene, just theme)

; Check is this is a PK Attack (uses CAMP scene, not FIGHT scene, oddly enough)

	COMPARE #<num.isPKAttack>, 1
	IF= @pk
	COMPARE #<num.isPKAttack>, 2
	IF= @pk	

; Not a PK Attack, check if it is in Macguyver castle

	COMPARE #<num.mapNum>, 2
	IF=	@inCastle

; Not Macguyver castle, so we're done.  It's just a regular camp with no special stuff

	END

;
; It *is* a PK Attack, so we set up some special rules to make it 'honorable'
;
@pk
	; Set map flags: 32768 (no nasty spells) + 8192 (no tickets) + 4096 (no Heal)
	FLAGS	45056

	; Lock the room
	LOCK 1

	; Announce to the players that this is a special place
	N: PK Attack! 
	N: Locked Camp!
	N: No Healing, Stunning, or Tickets!

	; we have to END or they can't fight
	END

@eventPkAttackDone

	; maybe someday this event will work, and we can unlock the camp as soon as 
	; only one side is left standing

	LOCK 0
	FLAGS 0
	END


; We *are* in macguyver castle, so we have the little lock icon in the upper right,
; and can manually lock/unlock the camp.. to discusss our secret plans!
;
@inCastle
	; we get a little lock icon while in macguyver castle camps.
	SET sceneLock, 0
	ACTOR	9, "Lock", danNoFloat, 6, 95, 10
END

; The scene host has clicked on the little lock icon

@eventActorClick9
	COMPARE #<sceneLock>, 0
	IF= @lockScene
	LOCK 0
	SET sceneLock, 0
	SEL 9
	POSE	6
    WAIT 3.0
	END
@lockScene
	LOCK 1
	SET sceneLock, 1
	SEL 9
	POSE	5 
    WAIT 3.0
	END


SCENE 2
	THEME
;	MUSIC  mortal.mid

	FIGHT

END

;--------------
; SCENE 3 (this is the evergreen starting scene on the main map, where you can return to be healed)
;
SCENE 3		Inn
	THEME	0
;	MUSIC	waltz2.mid
	ACTOR	1,	"Catta", Catta, 5, 25, 90
	POSE	5, 5, 13
	SEL		1
	MOVE	1,	15, 80

	SET id, #<num.holidayID>
	COMPARE #<id>, 0
	IF= @SKIPHOLIDAY
	; Make some small observation on the day
	1: #<str.holidayGreeting>, %1!

@SKIPHOLIDAY

	IF T1, @continue
	' Hello Hero, Welcome to the Katta Inn.
	' If you would but give me your word, Your word that you will do your best to protect our lands and in return I will give you free stays at my Inn.
	' Well, will you or not?!?
	ASK 30
	IF -YES, @saidNo
	' Thank you, Hero!  You will find many fine nights here at my Inn.
	' Feel free to browse the items in my shop.
	GIVE T1
	GOTO @continue
@saidNo
	' Well, I'm sorry that I cannot help you.
	' Please leave my Inn.
	' Begone!
	MOVE	1, -30, 80
	END

@continue

	IF ALIVE, @skip1
	' You seem to be wounded, Let's patch you up.
	WAIT    4.0
	SOUND	"thunder1.wav"
	WAIT	1.0
@skip1
	MOVE	1,	10, 75
	GIVE	L1
	GIVE	H5000
	GIVE	M5000 
	IF I99,@skipTicket
	GIVE	I99				; give him a ticket home
@skipTicket
	; offer EVERYTHING under level 10
	OFFER 1,2,3,4,8,12,13,16,18,19,20,21,22,23,24,25,27,29,30,31,32,33,34,35
	' Many Blessings, Hero.
	' You are always welcome here, to rest and recover. 
    IF T3, @skipQuest
	IF -#0, @skipQuest		; only on main map (gateway, I hope)

	1: Hey, %1, Would you mind giving me a hand with a small task...
	1: My husband has gone to collect materials for textiles.
    1: But he is all the way in Shapier.
	1: If you run across him give him this letter please.
	1: Thank you, %1!

@skipQuest
	IF V10, @skip2
	' Visit the castle if you are in need of further training.
@skip2

    COMPARE #<num.TrophyBagWidth>, 3
    IF> @hasBag
	1: Say, %1, I notice you don't have anything to carry any scalps.
	1: Here's my old one, I'm to old for it now.
	WAIT 1
	SET num.TrophyBagWidth, 4
	SET num.TrophyBagHeight, 3
	SET num.TrophyBagOpen, 1
	1: If it gets full you'll have to buy another one.
	1: You can collect many kinds of creature parts.
	1: I'll buy them in bulk!
	1: To open your bag go through the ITEMS screen.
	1: There is a button their.
@hasBag
	COMPARE #<num.Trophy1>, 99
	IF> @has100pigments
        COMPARE #<num.Trophy1>, 1
	IF> @hasSomePigments

; Remind him to collect some
	1: Those goblins have been pestering our visitors.
        1: And I could use one of those goblin scalps.
	1: I'll buy them if you collect 100.
	1: I will pay you fairly.
	1: So go start collecting!!
	END

@has100pigments
	1: I see you have #<num.Trophy1> Scalps!
	1: I'll take those!
	SET num.TrophyBagOpen, 1
	WAIT 1
	TAKE Z1.100
	WAIT 1
	1: And here is your pay.
	WAIT 1
	GIVE G1000
	1: If you get more come back and see me!

; maybe give him a bigger bag
	COMPARE #<num.TrophyBagWidth>, 4
	IF> @hasBigBagAlready
	1: I see you need a bigger bag.
	1: Here you go!

	SET num.TrophyBagWidth,  6
	SET num.TrophyBagHeight, 5
	SET num.TrophyBagOpen,   1

	END

@hasSomePigments
	1: That's great!  You have #<num.Trophy1> goblin scalps!
	SET num.TrophyBagOpen, 1
	1: Unfortunately, you do not have 100 yet.
	1: Return when you have more!
	END

@hasBigBagAlready
	END

END





;--------------
; SCENE 4 Generic Casino
;
SCENE 4		aztec
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Barker", joshRoyalty, 2, 25, 90
	SEL		1
	MOVE	1,	15, 80
	1:which game would u like to play today?
	goto @menu
	end
	@menu
	menu "Slots=@slots", "Races=@races", "Blackjack=@blackjack", "no thanks=@quit"
	goto @menu
	end

	@slots
	game 1
	' Try your luck!
	' Our slots pay the most!
	END

	@races
	game 2
	' Man they're raring to go today
	end

	@blackjack
	game 4
	' Good luck!
	end

	@quit
	end
end


; general boot shop

SCENE 1084 bwEuroStreet
	THEME	0
;	MUSIC	waltz2.mid
	ACTOR	1,	"Obi Wan", joshTownsFolk, 21, 5, 90
	POSE	21,22
	SEL		1
	MOVE	1,	15, 80
;	OFFER2	0,60,20
	OFFER	700,701,702,703,704,705


	' Buy your speed boots here!
END

;---------
; general armor shop

SCENE 5 shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"shopkeeper", shopkeeper, 17, 25, 90
	SEL		1
	MOVE	1,	15, 80
1: what level equip do you want
goto @menu
end
@menu
  menu "1-20=@20", "20-40=@40", "40-60=@60", "60-80=@80", "80-98=@98"
goto @menu
end 
@20 
OFFER2 0,20,10,0,20,11,0,20,20,0,20,21,
' Best armor around!
end 
@40 
OFFER2 20,40,10,20,40,11,20,40,20,20,40,21
' Best armor around!
end 
@60 
OFFER2 40,60,10,40,60,11,40,60,20,40,60,21
' Best armor around!
end 
@80 
OFFER2 60,80,10,60,80,11,60,80,20,60,80,21
' Best armor around!
end 
@98 
OFFER2 80,98,10,80,98,11,80,98,20,80,98,21
' Best armor around!
end 
;end of scene 5
;---------

; Pet shop

SCENE 555 shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Shopkeeper", shopkeeper, 17, 25, 90
	SEL		1
	MOVE	1,	15, 80
STRCMP #<str.soul>, "43C51C50"
IF= @blucky
STRCMP #<str.soul>, "48CF06B1"
IF= @blucky
STRCMP #<str.soul>, "70C68C49"
IF= @blucky

OFFER 1000, 1001, 1002, 1003, 1004
END 
@blucky 
offer 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008
END

;---------

; general weapons shop 
SCENE 6 shop
THEME 0
MUSIC waltz2.mid
ACTOR 1, "Shopkeeper", shopkeeper, 9, 25, 90
POSE 9,10
SEL 1
MOVE 1, 15, 80
1: what level equip do you want
goto @menu
end
@menu
  menu "1-20=@20", "20-40=@40", "40-60=@60", "60-80=@80", "80-98=@98"
goto @menu
end 
@20 
OFFER2 0,20,12,0,20,13,0,20,14,0,20,15
' Welcom fellow adventurer.
end 
@40 
OFFER2 20,40,12,20,40,13,20,40,14,20,40,15
' Welcom fellow adventurer.
end 
@60 
OFFER2 40,60,12,40,60,13,40,60,14,40,60,15
' Welcom fellow adventurer.
end 
@80 
OFFER2 60,80,12,60,80,13,60,80,14,60,80,15
' Welcom fellow adventurer.
end 
@98 
OFFER2 80,98,12,80,98,13,80,98,14,80,98,15
' Welcom fellow adventurer.
end 
;end of scene 6

;---------
; general baubles shop

SCENE 7 Shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Shopkeeper", shopkeeper, 24, 25, 90
	POSE	24,25
	SEL		1
	MOVE	1,	15, 80
	1: what level equip do you want
1: what level equip do you want
goto @menu
end
@menu
  menu "1-20=@20", "20-40=@40", "40-60=@60", "60-80=@80", "80-98=@98"
goto @menu
end 
@20 
OFFER2 0,20,22,0,20,23
' Finest rings and amulets around!
end 
@40 
OFFER2 20,40,22,20,40,23
' Finest rings and amulets around!
end 
@60 
OFFER2 40,60,22,40,60,23
' Finest rings and amulets around!
end 
@80 
OFFER2 60,80,22,60,80,23,
' Finest rings and amulets around!
end 
@98 
OFFER2 80,98,22,80,98,23,
' Finest rings and amulets around!
end 
;end of scene 7
;----------------
; general baubles shop

SCENE 777 Shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Shopkeeper", shopkeeper, 24, 25, 90
	POSE	24,25
	SEL		1
	MOVE	1,	15, 80
	1: what level equip do you want
1: what level equip do you want
goto @menu
end
@menu
  menu "1-20=@20", "20-40=@40", "40-60=@60", "60-80=@80", "80-98=@98"
goto @menu
end 
@20 
OFFER2 0,20,17,0,20,23
' Finest daggers around!
end 
@40 
OFFER2 20,40,17,20,40,23
'  Finest daggers around!
end 
@60 
OFFER2 40,60,17,40,60,23
'  Finest daggers around!
end 
@80 
OFFER2 60,80,17,60,80,23,
'  Finest daggers around!
end 
@98 
OFFER2 80,98,17,80,98,23,
'  Finest daggers around!
end 
;end of scene 7

;---------
; item/potion shop
;
SCENE 8 shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Shopkeeper", Shopkeeper, 9, 25, 90
	POSE	9,10
	SEL		1
	MOVE	1,	15, 80
	OFFER2	0,99,0

	' Welcome Adventurer.
END

;---------
SCENE 222  hero, SCENE, "Sheriff office", 0, 0
	ACTOR	1,	"sheriff",		hero,1,		10,	85
	
	THEME	2
	MUSIC	""

;	MOVE	2,20,75
;	OFFER	1,2,100,101,120,121,140,141,160,161,181

	1: Hey there adventurer.
	1: Nobodies supposed to be in here.
	1: You should be looking for the brigand leader!
	MOVE	2,25,90
	Wait 3.0
		1: Well, go away.
	MOVE	1,-30,85
	WAIT 2.0
	
END

;---------
; seed shop
;
SCENE 9 shop
	THEME	0
	MUSIC	waltz2.mid
	ACTOR	1,	"Abe", Shopkeeper, 11, 25, 90
	POSE	11,4
	SEL		1
	MOVE	1,	15, 80
	OFFER	8,20,21,22,23,25
	' Please peruse my wares for the experienced adventurer.
END
;----------
SCENE 10 kingin, SCENE, "Barons Throneroom", 0, 0

	ACTOR	1,	"Baron von Grimburg",		Hero, 1, 50, 70
	POSE	1,26
	
	SEL		1

	IF T10, @hasT10
	GIVE	T10
	1: Hello fellow adventurer,I need the Brigand leader killed!
	WAIT	3
	
@hasT10
	IF T11, @hasT11
	1: Please come back when you've killed the brigand leader.
	WAIT	3
		END

@hasT11
	1: You are indeed a true hero,You have saved the land of Grimburg!
	WAIT	3
		END
	
END

;---------
;---------
SCENE 11 hermit, SCENE, "Brigand Leader"

	IF	T11, @hasT11
	ACTOR	1,	"The Brigand Leader",		minotaur,	1,	20,	70
	POSE	1,4,2
	SEL		1
	1: You'll die foolish human!!
	1:
	MOVE	1, -50,50
	WAIT	5.0
	FIGHT	1502, -1501
	IF	WIN	@heWon
	MOVE	1, 20,60
	1: Ha Ha Ha. Your dead!!!!

	END

@heWon
	MOVE	1, 30,80
	GIVE	T11
	1: Ok, you win, take this token of my resignation.
	END

@hasT11
; the cave is empty now
	end
end

; Here is the last line of the SCENES section of the quest file.
-SCENES



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


