浏览代码

Merge branch 'master' of https://git.catrenelle.com/Kevin_Smarts/glife

julzor 5 年之前
父节点
当前提交
75a6e8793e
共有 3 个文件被更改,包括 523 次插入342 次删除
  1. 65 68
      locations/Snpc.qsrc
  2. 385 241
      locations/chessplay.qsrc
  3. 73 33
      locations/kruchess.qsrc

+ 65 - 68
locations/Snpc.qsrc

@@ -7,17 +7,17 @@ $static_num = $school_static_num[numnpc]
 '<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
 '<<$npc_notes[$static_num]>>'
 
-if grupTipe[numnpc] = 5:'<<$npc_firstname[$static_num]>> is an outcast in school, and often gets picked on at school.'
-if grupTipe[numnpc] = 6:''
-if grupTipe[numnpc] = 3:'<<$npc_firstname[$static_num]>> is a nerd, and is often found around the rest of the nerds doing homework or a their game night.'
-if grupTipe[numnpc] = 2:'<<$npc_firstname[$static_num]>> is part of the athletic clique in your school.'
-if grupTipe[numnpc] = 1:'<<$npc_firstname[$static_num]>> is popular, and spends time with the other popular kids usually.'
-if grupTipe[numnpc] = 4:'<<$npc_firstname[$static_num]>> is a Gopnik, and spends a lot of time doing what Gopniks usually do: be loud, and drink beer.'
-if npc_rel[$static_num] < 20:'They really don''t like you.'
-if npc_rel[$static_num] >= 20 and npc_rel[$static_num] < 40:'They are fairly indifferent to you.'
-if npc_rel[$static_num] >= 40 and npc_rel[$static_num] < 60:'The two of you get along together fairly well together, more of casual friends.'
-if npc_rel[$static_num] >= 60 and npc_rel[$static_num] < 80:'You get along great with them, they are one of your friends.'
-if npc_rel[$static_num] >= 80:'They are one of your best friends.'
+if npc_grupTipe['A<<numnpc>>'] = 5:'<<$npc_firstname[$static_num]>> is an outcast in school, and often gets picked on at school.'
+if npc_grupTipe['A<<numnpc>>'] = 6:''
+if npc_grupTipe['A<<numnpc>>'] = 3:'<<$npc_firstname[$static_num]>> is a nerd, and is often found around the rest of the nerds doing homework or a their game night.'
+if npc_grupTipe['A<<numnpc>>'] = 2:'<<$npc_firstname[$static_num]>> is part of the athletic clique in your school.'
+if npc_grupTipe['A<<numnpc>>'] = 1:'<<$npc_firstname[$static_num]>> is popular, and spends time with the other popular kids usually.'
+if npc_grupTipe['A<<numnpc>>'] = 4:'<<$npc_firstname[$static_num]>> is a Gopnik, and spends a lot of time doing what Gopniks usually do: be loud, and drink beer.'
+if npc_rel['A<<numnpc>>'] < 20:'They really don''t like you.'
+if npc_rel['A<<numnpc>>'] >= 20 and npc_rel['A<<numnpc>>'] < 40:'They are fairly indifferent to you.'
+if npc_rel['A<<numnpc>>'] >= 40 and npc_rel['A<<numnpc>>'] < 60:'The two of you get along together fairly well together, more of casual friends.'
+if npc_rel['A<<numnpc>>'] >= 60 and npc_rel['A<<numnpc>>'] < 80:'You get along great with them, they are one of your friends.'
+if npc_rel['A<<numnpc>>'] >= 80:'They are one of your best friends.'
 
 if numnpc = 14 and KatjaOTN > 0:
 	if KatjaHorny < 20:'Katja looks calm and stoic.'
@@ -41,41 +41,41 @@ if numnpc = 9:gs 'kotovtalker'
 !!!Niko Volkov!!!!
 !!!!!!!!!!!!!!!!!!
 
-	if numnpc = 61 and $loc ! 'gdkin' and NikoBreakup = 1:
+	if numnpc = 189 and $loc ! 'gdkin' and NikoBreakup = 1:
 		gt 'NikoEv', 'Lunch Breakup'
-	elseif numnpc = 61 and $loc = 'gdkin' and NikoBreakup = 1:
+	elseif numnpc = 189 and $loc = 'gdkin' and NikoBreakup = 1:
 		gt 'NikoEv', 'Disco Breakup'
-	elseif numnpc = 61 and $loc = 'gdkin' and NikoBreakupDay = daystart:
+	elseif numnpc = 189 and $loc = 'gdkin' and NikoBreakupDay = daystart:
 		gt 'NikoEv', 'Disco Breakup 2'
-	elseif numnpc = 61 and $loc ! 'gdkin' and NikoIntro = 0:
+	elseif numnpc = 189 and $loc ! 'gdkin' and NikoIntro = 0:
 		gt 'NikoEv', 'Lunch Intro'
-	elseif numnpc = 61 and $loc ! 'gdkin' and NikoIntro = 1:
+	elseif numnpc = 189 and $loc ! 'gdkin' and NikoIntro = 1:
 		gt 'NikoEv', 'Lunch Chat'
-	elseif numnpc = 61 and $loc = 'gdkin' and NikoIntro = 0:
+	elseif numnpc = 189 and $loc = 'gdkin' and NikoIntro = 0:
 		gt 'NikoEv', 'Disco Intro'
-	elseif numnpc = 61 and $loc = 'gdkin' and NikoIntro = 1:
+	elseif numnpc = 189 and $loc = 'gdkin' and NikoIntro = 1:
 		gt 'NikoEv', 'Disco Chat'
 	end
 
 !!!!!!!!!!!!!
 !!!gopniks!!!
 !!!!!!!!!!!!!
-if grupTipe[numnpc] = 4:
+if npc_grupTipe['A<<numnpc>>'] = 4:
 	if $loc = 'gdkin':
 		if pav_slut < 125:
 			if numnpc ! 9:
-				if npcPol[numnpc] = 0:
+				if npc_gender['A<<numnpc>>'] = 0:
 					'<<$npc_firstname[$static_num]>> offers you a beer and says: "Hey <<$pcs_nickname>>! Let''s drink some beer and have some fun!"'
 				else
 					'<<$npc_firstname[$static_num]>> offers you a beer and says: "Hey <<$pcs_nickname>>! Let''s drink some beer and have some fun!"'
 				end
 
-				act 'Decline':npc_rel[$static_num] -= 5 & gt $loc, $metka
+				act 'Decline':npc_rel['A<<numnpc>>'] -= 5 & gt $loc, $metka
 				
 				act 'Drink the beer':
 					*clr & cla
 					minut += 5
-					npc_rel[$static_num] += 5
+					npc_rel['A<<numnpc>>'] += 5
 					alko += rand(1,2)
 					if pcs_hydra >= 100:
 						pcs_hydra += 5
@@ -92,26 +92,26 @@ if grupTipe[numnpc] = 4:
 				end
 			end
 		elseif pav_slut >= 125:
-			if npcPol[numnpc] = 0:
+			if npc_gender['A<<numnpc>>'] = 0:
 				'<<$npc_firstname[$static_num]>> looks at you wearily: "What do you want? Looking for a dick to suck on or something?"'
 			else
 				'<<$npc_firstname[$static_num]>> wrinkles her nose as she looks at you: "Hey cocksucker, get away from me! I don''t want to be seen talking to you."'
 			end
 
-			act 'Move away':npc_rel[$static_num] -= 5 & gt $loc, $metka
+			act 'Move away':npc_rel['A<<numnpc>>'] -= 5 & gt $loc, $metka
 		end
 
 		exit
 	end
 end
 
-if numnpc = 45:
+if numnpc = 144:
 !!I would like to change this so even if all the requirements are meet it only fires one in 5 times. 
-	if $loc ! 'gdkin' and npc_rel[$static_num] > 50 and (Anush_sex > 0 or hotcat >= 7) and rand(0,4) = 0:
+	if $loc ! 'gdkin' and npc_rel['A<<numnpc>>'] > 50 and (Anush_sex > 0 or hotcat >= 7) and rand(0,4) = 0:
 		act 'You''re looking flushed':
 			*clr & cla
 			if Anush_lunch = 0:
-				'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/45.jpg"></center>'
+				'<center><img <<$set_imgh>> src="images/pc/npc_headshots/144.jpg"></center>'
 				'"Hey Anush you feeling ok? You kinda look flush, is something wrong? Would you like to talk about it?"'
 				'She leans in close and tries to kiss you, while one hand reaches down and squeezes your butt. You turn your head and pull away. "What are you doing? I was only seeing if you was ok."'
 				'She crowds you a bit and leans in close. "You talk to much, I can think of better things you can do with that tongue of yours."'
@@ -238,11 +238,11 @@ act 'Chat':
 
 	gs 'stat'
 	'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-	'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+	'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 
-	if numnpc = 1 and npc_rel[$static_num] = 0:
+	if numnpc = 1 and npc_rel['A<<numnpc>>'] = 0:
 		cla
-		'Dimka does no efforts to hide his disdain for you: "Get away from me, you pimply pig."'
+		'Dimka doesn''t try to hide his disdain for you: "Get away from me, you pimply pig."'
 
 		if $loc ! 'gdkin':
 			act 'Leave': gt 'gschool_lessons', 'short_break'
@@ -289,14 +289,14 @@ if numnpc = 2:
 
 			if $loc = 'gdkin':minut += 5
 
-			npc_rel[$static_num] += 5
+			npc_rel['A<<numnpc>>'] += 5
 			sub += 1
 
 			if pav_slut < 125: artemLernQW = 1
 
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 
 			if pav_slut < 125:'You approach Artem and explain how you''re struggling in school and could really use his help studying. Artem is a bit surprised: "What... you want my help? Well, okay I guess. Come meet me at my place if you want to do homework together."'
 			if pav_slut >= 125:'You approach Artem and explain how you''re struggling in school and could really use his help studying. Artem is outraged: "Bah... the school whore needs my help? I don''t think so."'
@@ -336,18 +336,18 @@ end
 !!!JULIA milova!!!
 !!!!!!!!!!!!!!!!!!
 if numnpc = 12:
-	if (pcs_dom > 0 or grupTipe = 3) and JuliaMilLernQW = 0 and npc_rel[$static_num] >= 80:
+	if (pcs_dom > 0 or grupTipe = 3) and JuliaMilLernQW = 0 and npc_rel['A<<numnpc>>'] >= 80:
 		act '"Could you help me out a bit in school?"':
 			*clr & cla
 
 			if $loc = 'gdkin':minut += 5
 
-			npc_rel[$static_num] += 5
+			npc_rel['A<<numnpc>>'] += 5
 			sub += 1
 			JuliaMilLernQW = 1
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 
 			if pav_slut < 125:'You approach Julia and explain how you''re struggling in school and could really use his help studying. She thinks it over for a second, but happily agrees: "Sure <<$pcs_nickname>>, that could be fun!"'
 			if pav_slut >= 125:'You approach Julia and explain how you''re struggling in school and could really use his help studying. She makes some comments about your lousy reputation in school, but at the same time doesn''t seem to care too much about it and agrees to help you anyway. As long as you don''t tell anyone.'
@@ -372,11 +372,11 @@ if numnpc = 14:
 
 			if $loc = 'gdkin':minut += 5
 
-			npc_rel[$static_num] += 5
+			npc_rel['A<<numnpc>>'] += 5
 			meynoldQW = 2
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'You approach Katja and thank her for taking you home from the disco when you were drunk, the other night. Katja gives you a knowing smile and says: "Don''t mention it, <<$pcs_nickname>>! You really shouldn''t get that drunk at the disco though, that could end badly. Some of the guys there are real pigs..."'
 
 			if $loc ! 'gdkin':
@@ -390,14 +390,13 @@ if numnpc = 14:
 	if rand(1,2) = 1 and katschoolsex = 1 and pcs_horny > 40:
 		*clr
 		if $loc = 'gdkin':
-			minut += 1
-			gs'stat'
 			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/girl/katja/tanga_kiss1.jpg"></center>'
 		else
-			minut += 1
-			gs'stat'
 			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/girl/katja/tanga_kiss.jpg"></center>'
 		end
+		
+		minut += 1
+		gs'stat'
 
 		'Katja slowly leans in towards you, almost closing her eyes and slowly opening her mouth. Unable to resist, you lean in and meet her with a kiss.'
 		gs 'katjaEv', 'kiss_events'
@@ -412,7 +411,7 @@ if numnpc = 14:
 
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'Katja happily grins as she quickly straightens your hair: "What do you want? A light touch-up, some normal make-up or shall I just shovel it on?"'
 
 			act 'Light touch-up':
@@ -456,19 +455,17 @@ if numnpc = 14:
 		end
 	end
 
-	if (npc_rel[$static_num] > 60) and (KatjaOTN > 0) and (KatjaLust > 15) :
+	if (npc_rel['A<<numnpc>>'] > 60) and (KatjaOTN > 0) and (KatjaLust > 15) :
 		!!new Katja stuff not sure where you want to put it. It should be an option when you talk to her at school or the dance where it says Chat, but add this as an option.
 		act 'Kiss Katja':
 			*clr & cla
 			if $loc = 'gdkin':
-				minut += 1
-				gs'stat'
 				'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/girl/katja/tanga_kiss1.jpg"></center>'
 			elseif $loc ! 'gdkin':
-				minut += 1
-				gs'stat'
 				'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/girl/katja/tanga_kiss.jpg"></center>'
 			end
+			minut += 1
+			gs'stat'
 			'You lean in to kiss Katja'
 			if Katjahorny < 30:
 				'She pulls away from you as you try and kiss her, she looks around to see if anyone seen. "Not here and not now."'
@@ -481,7 +478,7 @@ if numnpc = 14:
 				*clr & cla
 				gs 'stat'
 				'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-				'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+				'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 				'You slowly lean in towards Katja to kiss her. Unable to resist, Katja almost closing her eyes, slowly opening her mouth, leans in and meets your kiss.'
 				gs 'katjaEv', 'kiss_events'
 			end
@@ -496,7 +493,7 @@ if numnpc = 14:
 			gs 'stat'
 
 			'<center><b><font color = maroon><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'You make sure no one else is paying attention, and tell Katja about what Artem and Peter are doing to you on Mondays. At first she doesn''t believe you. After a while, all of the nasty details you''re sharing convince her that there is no way you''re making this up. Katja is shocked!'
 			'You tell her that the only way you have thought of to get rid of their blackmailing, is to get blackmailing material of your own. Katja nods and says: "That makes sense, actually... if you could somehow make it look violent, I bet it would work even better! I don''t know where you would be able to find a tiny camera though... maybe Albina can help you?"'
 
@@ -528,18 +525,18 @@ end
 !!!!!!!!!!!!!!!!!!!!!!!!!
 
 if numnpc = 16:
-	if pcs_dom > 0 and NatBelLernQW = 0 and npc_rel[$static_num] >= 80:
+	if pcs_dom > 0 and NatBelLernQW = 0 and npc_rel['A<<numnpc>>'] >= 80:
 		act '"Could you help me out a bit in school?"':
 			*clr & cla
 
 			if $loc = 'gdkin':minut += 5
 
-			npc_rel[$static_num] += 5
+			npc_rel['A<<numnpc>>'] += 5
 			sub += 1
 			NatBelLernQW = 1
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/<<numnpc>>.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 
 			if pav_slut < 125:'You approach Natasha and explain how you''re struggling in school and could really use her help studying. She thinks it over for a second, but happily agrees: "Sure <<$pcs_nickname>>, that could be fun!"'
 			if pav_slut >= 125:'You approach Natasha and explain how you''re struggling in school and could really use her help studying. She makes some comments about your lousy reputation in school, but at the same time doesn''t seem to care too much about it and agrees to help you anyway. As long as you don''t tell anyone.'
@@ -596,7 +593,7 @@ if numnpc = 31:
 		*clr & cla
 		minut += 5
 		gs 'stat'
-		'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/31.jpg"></center>'
+		'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 		'"So Lizaveta hear any good gossip of late?"'
 		'As you ask that her face lights up and she leans in close like she has the best secret in the world to share with you. "Oh my god yes! I was... well it doesn''t matter what I was doing but I overheard some others talking and they said..."'
 		if rand(0,2) = 0:
@@ -616,15 +613,15 @@ end
 !!!!!Aleksandra Kirilenko!!!!!
 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 
-if numnpc = 62:
-	if npc_rel[$static_num] >= 100 and grupTipe = 3 and npc_QW[$static_num] = 0 and temper >= 15:
+if numnpc = 231:
+	if npc_rel['A<<numnpc>>'] >= 100 and grupTipe = 3 and npc_QW['A<<numnpc>>'] = 0 and temper >= 15:
 		act 'Ask to join at library after school':
 			*clr & cla
 			minut += 5
-			npc_QW[$static_num] = 1
+			npc_QW['A<<numnpc>>'] = 1
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/62.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'"Hi <<$npc_nickname[''<<$static_num>>'']>>! I just finished my last book at home and I''m not sure what I should read next. Can I join you at the library this afternoon so that you can help me find another good one to read?"'
 			'<<$npc_firstname[''<<$static_num>>'']>>''s face quickly shifts from a smile to confusion. You can tell she''s not sure how to respond and there is a long pause as a result.  Finally after about 30 seconds of thought she responds "Sure, that should be alright.  Do you mind going home with me first so that I can change out of our uniform?"'
 			'"That is no problem at all" you reply. "I''ll meet you outside of school after our last period, and then we can head to your house together."'
@@ -635,14 +632,14 @@ if numnpc = 62:
 				act 'Move away': gt $loc, $metka
 			end
 		end
-	elseif npc_rel[$static_num] >= 100 and grupTipe = 3 and npc_QW[$static_num] = 2 and schoolprogul > 0:
+	elseif npc_rel['A<<numnpc>>'] >= 100 and grupTipe = 3 and npc_QW['A<<numnpc>>'] = 2 and schoolprogul > 0:
 		act 'Ask to study at her house after school':
 			*clr & cla
 			minut += 5
-			npc_QW[$static_num] = 3
+			npc_QW['A<<numnpc>>'] = 3
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/62.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'"Hi <<$npc_nickname[''<<$static_num>>'']>>! I ended up missing school the other day because I was sick. Would it be alright with you if we went to your house after school so that you can help me catch up?"'
 			'<<$npc_firstname[''<<$static_num>>'']>> replies "Sure <<$pcs_nickname>>, just as long as you aren''t sick anymore.  I don''t want to get sick with whatever you had and miss school as well."'
 			'You giggle a little bit and reply "Nah, I got over my sickness so you should be fine. I''ll meet you outside of school after our last period, and then we can head to your house together."'
@@ -653,14 +650,14 @@ if numnpc = 62:
 				act 'Move away': gt $loc, $metka
 			end
 		end
-	elseif npc_rel[$static_num] >= 100 and npc_QW[$static_num] = 4 and pcs_dom >= 20:
+	elseif npc_rel['A<<numnpc>>'] >= 100 and npc_QW['A<<numnpc>>'] = 4 and pcs_dom >= 20:
 		act 'Serious talk':
 			*clr & cla
 			minut += 5
 			gs 'stat'
 			npc_QW['A231'] = 5
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/62.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'As you walk to up <<$npc_firstname[''<<$static_num>>'']>>, you feel your stomach drop to the floor due to how awkward the situation is. However you''re not about to let what happened end your friendship without at least clearing the air.'
 			'After about a minute or so of eye contact, you finally develop enough courage to speak first.'
 			'"Hi <<$npc_nickname[''<<$static_num>>'']>>...." You say in a nervous and defeated voice.'
@@ -675,13 +672,13 @@ if numnpc = 62:
 				act 'Move away': gt $loc, $metka
 			end
 		end	
-	elseif npc_rel[$static_num] >= 100 and npc_QW[$static_num] = 4 and pcs_dom < 20:
+	elseif npc_rel['A<<numnpc>>'] >= 100 and npc_QW['A<<numnpc>>'] = 4 and pcs_dom < 20:
 		act 'Chicken Out':
 			*clr & cla
 			minut += 5
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'
-			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/62.jpg"></center>'
+			'<center><img <<$set_imgh>> src="images/pc/npc_headshots/<<numnpc>>.jpg"></center>'
 			'As you see <<$npc_firstname[''<<$static_num>>'']>>, you feel your stomach drop to the floor due to how awkward the situation is. You don''t have enough courage to bring up what happened the last time you were at <<$npc_firstname[''<<$static_num>>'']>>''s house, so you pretend to not see her and carry on your way.'
 			if $loc ! 'gdkin':
 				xgt 'gschool_lessons', 'short_break', 'nopict'
@@ -689,14 +686,14 @@ if numnpc = 62:
 				act 'Move away': gt $loc, $metka
 			end
 		end
-	elseif npc_QW[$static_num] > 5:
+	elseif npc_QW['A<<numnpc>>'] > 5:
 		'Ever since you asked <<$npc_nickname[''<<$static_num>>'']>> to be your girlfriend, she has come out of her shell a bit more. She even kisses you while at school!'
 		act 'Kiss her':
 			*clr & cla
 			minut += 5
-			npc_rel[$static_num] += 10
-			npc_love[$static_num] += 5
-			npc_horny[$static_num] += 15
+			npc_rel['A<<numnpc>>'] += 10
+			npc_love['A<<numnpc>>'] += 5
+			npc_horny['A<<numnpc>>'] += 15
 			gs 'arousal', 'kiss', '5', 'futa'
 			gs 'stat'
 			'<center><b><font color="maroon"><<$npc_firstname[$static_num]>> <<$npc_lastname[$static_num]>></font></b></center>'

+ 385 - 241
locations/chessplay.qsrc

@@ -3,69 +3,158 @@
 menu_off = 1
 
 if $ARGS[0] = '':
-	if $chess_name='':$chess_name='girl'
+	if $chess_name='':$chess_name='Boy'
 	gs'stat'
 	chess_GG = 20
 	chess_com = 20
-	
-	chess_ind = (chessV - pcs_chess) / 100
-	chess_exp += rand(pcs_intel/20,pcs_intel/10)
-	intel_exp += 1
-	minut += 60
 
+	! chess_ind is used to show the integer difference between Sveta and her opponent
+	! if it is 0 then Sveta is equally skilled as her opponent
+	! the opponent will play more neutrally if the skill gap is within 5 points
+	! if it is > 0 then Sveta is less skilled then her opponent
+	! the opponent will play more aggressively if Sveta is less skilled by at least 5 points
+	! if it is < 0 then Sveta is more skilled then her opponent
+	! the opponent will play more conservatively if Sveta is more skilled by at least 5 points
+	chess_ind = chessV - pcs_chess
+	! chess_diff is used to show how that difference affects the swing in momentum with each move
+	if chess_ind < 0:
+		chess_diff = (chess_ind/2)*-1
+	else
+		chess_diff = (chess_ind/2)
+	end
+	! move_limit and time_limit keeps games from going forever
+	chess_move_limit = 60
+	chess_time_limit = 120
+	! chess_move and total_chess_time keep track of total moves and time until it hits the limits
+	chess_move = 0
+	total_chess_time = 0
 	gt 'chessplay', 'game'
 end
 
 if $ARGS[0] = 'game':
+	chess_exp += rand(0,1)
+	intel_exp += rand(0,1)
+	chess_move += 1
+	chess_time = rand(1,3)
+	minut += chess_time
+	total_chess_time += chess_time
+	gs 'stat'
 
-	if chess_GG <= 0:
-		gt 'chessplay', 'lose'
+	if chess_move = 1:
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/board' + rand(1,1) + '.jpg"></center>'
+		*nl
+		if chess_ind > 5:
+			'You are less skilled at chess than '+$chess_name+'. They will play more aggressively to try and defeat you.'
+			'You might want to play more conservatively and wear down their attacks.'
+		elseif chess_ind < -5:
+			'You are more skilled at chess than '+$chess_name+'. They will play more conservatively to try and defeat you.'
+			'You might want to play more aggressively and wear down their defenses.'
+		else
+			'You are about equally skilled at chess as '+$chess_name+'. They will use a wide range of moves to try and defeat you.'
+			'You might want to try different types of moves to keep your opponent off balance.'
+		end
+	end
+
+	if chess_GG <= 0 and chess_com <= 0:
+		*clr & cla
+
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/stalemate' + rand(1,1) + '.jpg"></center>'
+		*nl
+		'Stalemate! You have drawn the match against '+$chess_name+'!'
+		'You and '+$chess_name+' could not find a way to win the match.'
+		
+		act 'Return': gt 'kruchess'
+	elseif chess_GG <= 0:
+		*clr & cla
+
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/lose' + rand(1,1) + '.jpg"></center>'
+		*nl
+		'Checkmate! You have lost the match against '+$chess_name+'!'
+		
+		act 'Return': gt 'kruchess'
 	elseif chess_com <= 0:
-		gt 'chessplay', 'win'
+		*clr & cla
+
+		chess_win += 1
+
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/win' + rand(1,1) + '.jpg"></center>'
+		*nl
+		'Checkmate! You have won the match against '+$chess_name+'!'
+
+		act 'Return': gt 'kruchess'
+	elseif chess_moves >= chess_move_limit:
+		*clr & cla
+
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/stalemate' + rand(1,1) + '.jpg"></center>'
+		*nl
+		'Draw! You agree to end the match with '+$chess_name+'.'
+		'You and '+$chess_name+' have both used too many moves and neither could find a way to win the match.'
+
+		act 'Return': gt 'kruchess'
+	elseif total_chess_time >= chess_time_limit:
+		*clr & cla
+
+		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/stalemate' + rand(1,1) + '.jpg"></center>'
+		*nl
+		'Draw! You agree to end the match with '+$chess_name+'.'
+		'You and '+$chess_name+' have both used too much time and neither could find a way to win the match.'
+
+		act 'Return': gt 'kruchess'
 	else
 		gs 'chessplay', 'moves'
 	end
 end
 
 if $ARGS[0] = 'moves':
-	cla
-	act 'Go defensive':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent tries to trap you, but you avoid it and gain some advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes offensive much to their advantage.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes aggressive you absorb some of it, but still lose some advantage.'
-			if chess_ind < -2:
-			chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent tries to manoeuvre the game pieces, but your defensive actions expose all their efforts, much to your advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes defensive and neither of you gain any advantage.'
+	if chess_ind > 5:
+		chessM = rand(4,11)
+	elseif chess_ind < -5:
+		chessM = rand(0,7)
+	else
+		chessM = rand(2,9)
+	end
+
+	act 'Play conservatively':
+		! this works as the opposite of aggressive play
+		! conservative wins against offense and trap
+		! conservative loses to defense and tactical
+		! conservative ties with conservative and aggressive
+		*clr & cla
+
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also plays conservatively.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays defensively and is now in a better position than you.'
+			gs 'chessplay', 'advantage', 'conservative', 'bad'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays tactically and is able to deftly pick apart your conservative defenses.'
+			gs 'chessplay', 'advantage', 'conservative', 'bad'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' tries to trap you, but you encircle it with your defenses.'
+			gs 'chessplay', 'advantage', 'conservative', 'good'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays offensively, but your defense repulses his attacks.'
+			gs 'chessplay', 'advantage', 'conservative', 'good'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays aggressively, but your defense manages to hold them off.'
+			'Neither of you gain an advantage from this move.'
 		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
 
 		chess_GG -= 1
 		chess_com -= 1
@@ -73,87 +162,95 @@ if $ARGS[0] = 'moves':
 		gs 'chessplay', 'game'
 	end
 
-	act 'Heavy defense':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent tries to trap you, but you easily avoid it and gain a good advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes offensive you absorb some of it, but still lose some advantage.'
-			if chess_ind < -2:
-			chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes aggressive much to their advantage.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent tries to manoeuvre the game pieces, but your defensive actions expose some of their efforts, to your advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes defensive and neither of you gain any advantage.'
-		end
+	act 'Play defensively':
+		! this works as the opposite of offensive play
+		! defense wins against trap and conservative
+		! defense loses to aggressive and tactical
+		! defense ties with offense and defense
+		*clr & cla
 
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays very conservatively and does not threaten your defenses at all.'
+			gs 'chessplay', 'advantage', 'defense', 'good'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also plays defensively.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays tactically and is able to deftly pick apart your defenses.'
+			gs 'chessplay', 'advantage', 'defense', 'bad'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' tries to trap you, but you avoid it with your defenses.'
+			gs 'chessplay', 'advantage', 'defense', 'good'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays offensively, but your defense absorbs his attacks.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays aggressively and overwhelms your defenses.'
+			gs 'chessplay', 'advantage', 'defense', 'bad'
+		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
+		
 		chess_GG -= 1
 		chess_com -= 1
 
 		gs 'chessplay', 'game'
 	end
 
-	act 'Go offensive':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent tries to trap you, gaining some advantage.'
-			if chess_ind < -2:
-			chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes offensive much to your advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes aggressive you easily absorb it, and gain some advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent tries to manoeuvre the game pieces, your offensive actions leave you exposed, and they take advantage.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes on the attack and neither of you gain any advantage.'
+	act 'Play tactically':
+		! this works as the opposite of trap play
+		! tactical wins against defense and conservative
+		! tactical loses to aggressive and offense
+		! tactical ties with tactical and trap
+		*clr & cla
+
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays very conservatively and your tactical moves leave you in a better position.'
+			gs 'chessplay', 'advantage', 'tactical', 'good'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays defensively allowing you to pick apart their defenses.'
+			gs 'chessplay', 'advantage', 'tactical', 'good'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also plays tactically.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' tries to trap you, but you avoid it with your tactical movements.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays offensively, and some of your pieces are caught out of position.'
+			gs 'chessplay', 'advantage', 'tactical', 'bad'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays aggressively and rushes past your unprepared defenses.'
+			gs 'chessplay', 'advantage', 'tactical', 'bad'
 		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
 
 		chess_GG -= 1
 		chess_com -= 1
@@ -161,43 +258,47 @@ if $ARGS[0] = 'moves':
 		gs 'chessplay', 'game'
 	end
 
-	act 'Be aggressive':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent tries to trap you, and you are playing right into their hands.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes defensive to your advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes heavily defensive very much to your advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent tries to manoeuvre the game pieces, gaining some advantage.'
-			if chess_ind < -2:
-			chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes on the attack and neither of you gain any advantage.'
+	act 'Bait a trap for your opponent':
+		! this works as the opposite of tactical play
+		! trap wins against offense and aggressive
+		! trap loses to conservative and defense
+		! trap ties with tactical and trap
+		*clr & cla
+
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays very conservatively and their defenses are now very well prepared.'
+			gs 'chessplay', 'advantage', 'trap', 'bad'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays defensively and your bait is now out of position.'
+			gs 'chessplay', 'advantage', 'trap', 'bad'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays tactically and avoids your trap.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also tries to trap you.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays offensively, and a couple of their pieces are caught out of position.'
+			gs 'chessplay', 'advantage', 'trap', 'good'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays aggressively and many of their pieces fall into your trap.'
+			gs 'chessplay', 'advantage', 'trap', 'good'
 		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
 
 		chess_GG -= 1
 		chess_com -= 1
@@ -205,43 +306,47 @@ if $ARGS[0] = 'moves':
 		gs 'chessplay', 'game'
 	end
 
-	act 'Bait trap':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent goes offensive to your advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes defensive to their advantage.'
-			if chess_ind < -2:
-				chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes heavily defensive exposing your tactics much to their advantage.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent goes aggressive much to your advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes tactical and neither of you gain any advantage.'
+	act 'Play offensively':
+		! this works as the opposite of defensive play
+		! offense wins against tactical and aggressive
+		! offense loses to conservative and trap
+		! offense ties with offense and defense
+		*clr & cla
+
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays very conservatively and repulses all your attacks.'
+			gs 'chessplay', 'advantage', 'offense', 'bad'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays defensively and manages to absorb all your attacks.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays tactically, but your offense is able to outmaneuver them.'
+			gs 'chessplay', 'advantage', 'offense', 'good'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' traps some of your pieces. You should think more carefully next time.'
+			gs 'chessplay', 'advantage', 'offense', 'bad'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also plays offensively.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays aggressively and overextends themselves.'
+			gs 'chessplay', 'advantage', 'offense', 'good'
 		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
 
 		chess_GG -= 1
 		chess_com -= 1
@@ -249,43 +354,47 @@ if $ARGS[0] = 'moves':
 		gs 'chessplay', 'game'
 	end
 
-	act 'Manoeuvre the game pieces':
-		chessM = rand (0,5)
-		if chessM = 0:
-			'Your opponent goes offensive, much to your advantage.'
-			if chess_ind > 4:
-				chess_GG += 4 - chess_ind
-				chess_com -= 4 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		elseif chessM = 1:
-			'Your opponent goes defensive much to their advantage.'
-			if chess_ind < -4:
-				chess_GG -= 4 + chess_ind
-				chess_com += 4 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 2:
-			'Your opponent goes heavily defensive exposing your tactics to their advantage.'
-			if chess_ind < -2:
-			chess_GG -= 2 + chess_ind
-				chess_com += 2 - chess_ind
-			else
-				'However your superior skill negates that advantage.'
-			end
-		elseif chessM = 3:
-			'Your opponent goes aggressive to your advantage.'
-			if chess_ind > 2:
-				chess_GG += 2 - chess_ind
-				chess_com -= 2 + chess_ind
-			else
-				'However their superior skill negates that advantage.'
-			end
-		else
-			'Your opponent also goes tactical and neither of you gain any advantage.'
+	act 'Play aggressively':
+		! this works as the opposite of conservative play
+		! aggressive wins against defense and tactical
+		! aggressive loses to offense and trap
+		! aggressive ties with conservative and aggressive
+		*clr & cla
+
+		if chessM <= 1:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/conservative' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays conservatively and their defenses manage to hold you off.'
+			'Neither of you gain an advantage from this move.'
+		elseif chessM <= 3:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/defensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays defensively and you overwhelm a few of their pieces.'
+			gs 'chessplay', 'advantage', 'aggressive', 'good'
+		elseif chessM <= 5:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/tactical' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays tactically and cannot cope with your aggressive moves.'
+			gs 'chessplay', 'advantage', 'aggressive', 'good'
+		elseif chessM <= 7:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/trap' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' tries to trap you, but some of your pieces fall for it.'
+			gs 'chessplay', 'advantage', 'aggressive', 'bad'
+		elseif chessM <= 9:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/offensive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' plays offensively, leaving some of your pieces exposed.'
+			gs 'chessplay', 'advantage', 'aggressive', 'bad'
+		elseif chessM <= 11:
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/aggressive' + rand(1,1) + '.jpg"></center>'
+			*nl
+			$chess_name+' also plays aggressively.'
+			'Neither of you gain an advantage from this move.'
 		end
+		*nl
+		'You are on move '+str(chess_move)+' out of '+str(chess_move_limit)
+		'You are on minute '+str(total_chess_time)+' out of '+str(chess_time_limit)
 
 		chess_GG -= 1
 		chess_com -= 1
@@ -294,22 +403,57 @@ if $ARGS[0] = 'moves':
 	end
 end
 
+! $ARGS[1] = move chosen by player - used to set base skill difference and advantage change
+! $ARGS[2] = whether this move was a good choice - whether Sveta should gain or lose advantage
+if $ARGS[0] = 'advantage':
+	! conservative and aggressive are the most extreme and therefore have the biggest reward and risk
+	! but also requires the greatest difference in skill to pull off successfully or prevent your opponent from using successfully
+	if $ARGS[1] = 'conservative' or $ARGS[1] = 'aggressive':
+		chess_pos = 4
+		chess_neg = -4
+		chess_adv = 4
+	! defense and offense are a middle ground and have medium reward and risk
+	! requires a medium skill gap to pull off successfully or prevent your opponent from using successfully
+	elseif $ARGS[1] = 'defense' or $ARGS[1] = 'offense':
+		chess_pos = 2
+		chess_neg = -2
+		chess_adv = 2
+	! tactical and trap are the least extreme and therefore have the least reward and risk
+	! they require the least difference in skill to pull off successfully or prevent your opponent from using successfully
+	elseif $ARGS[1] = 'tactical' or $ARGS[1] = 'trap':
+		chess_pos = 1
+		chess_neg = -1
+		chess_adv = 1	
+	end
 
-if $ARGS[0] = 'win':
-	*clr & cla
-	gs 'stat'
-	chess_win += 1
-	'You have won this game.'
-	act 'Return': gt $loc
-end
-
-if $ARGS[0] = 'lose':
-	*clr & cla
-	gs 'stat'
-	'You have lost this game.'
-	act 'Return': gt $loc
+	if $ARGS[2] = 'good':
+		if chess_ind > chess_pos:
+			'You are less skilled than your opponent and cannot capitalize on your advantage.'
+			'Try to gain more skill at chess to use this move successfully against this opponent.'
+		elseif chess_ind < chess_neg:
+			'You are more skilled than your opponent and gain a major advantage.'
+			chess_GG = chess_GG + chess_adv + chess_diff
+			chess_com = chess_com - chess_adv - chess_diff
+		else
+			'You are about equally skilled as your opponent and gain some advantage.'
+			chess_GG = chess_GG + chess_adv/2 + chess_diff/2
+			chess_com = chess_com - chess_adv/2 - chess_diff/2
+		end
+	elseif $ARGS[2] = 'bad':
+		if chess_ind > chess_pos:
+			'You are less skilled than your opponent and you lose a major advantage.'
+			'Try to gain more skill at chess to prevent your opponent from using this move successfully.'
+			chess_GG = chess_GG - chess_adv - chess_diff
+			chess_com = chess_com + chess_adv + chess_diff
+		elseif chess_ind < chess_neg:
+			'You are more skilled than your opponent and prevent them from capitalizing on their advantage.'			
+		else
+			'You are about equally skilled as your opponent and you lose some advantage.'
+			chess_GG = chess_GG - chess_adv/2 - chess_diff/2
+			chess_com = chess_com + chess_adv/2 + chess_diff/2
+		end
+	end
 end
 
-
 --- chessplay ---------------------------------
 

+ 73 - 33
locations/kruchess.qsrc

@@ -11,90 +11,130 @@ gs 'themes', 'indoors'
 
 '<center><b><font color = maroon>Chess Club</font></b></center>'
 '<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/kruchess.jpg"></center>'
+*nl
 
 if hour > 20:
 	'Chess club is closed. The coach and some players are tidying away the boards and pieces.'
+
 	act 'Leave':gt'gdkkru'
 else
 	if week ! 6:
-		'The kids are sitting around playing practice games, while being watched over and helped by coach Genrikh.'
+		'The kids are sitting around playing practice games, while being watched over and helped by Coach Genrikh.'
+
 		act 'Spend an hour practicing with assistance from the coach':
-			cla
-			*nl
-			chess_exp += rand(pcs_intel/20,pcs_intel/10)
-			intel_exp += 1
+			*clr & cla
+			chess_exp += rand(0,1)
+			intel_exp += rand(0,1)
 			minut += 60
+			gs 'stat'
+
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
+			*nl
 			'You spend the next hour practicing against the other players with the coach walking around and stopping to help out or point things out. You learn a little every time. You also discuss the various chess openings and which ones are the best, which can often get lively.'
+
 			act 'Return': gt 'kruchess'
 		end
 		act 'Talk to the other players':
 			*clr & cla
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/talk.jpg"></center>'
 			minut += 30
-			pcs_mood +=5
+			pcs_mood += 5
+			gs 'stat'
+
+			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/talk.jpg"></center>'
+			*nl
 			'You take a break from playing and talk to a couple of your fellow chess enthusiasts. After first focusing on chess for a while, the conversation drifts off to other topics. You have a good time chatting and relaxing.'
+
 			act 'Return': gt 'kruchess'
 		end
 		act 'Talk to Evgeny Kuznetsov':
 			*clr & cla
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/talk.jpg"></center>'
 			minut += 30
 			chess_exp += 2
 			npc_rel['A151'] += 5
+			gs 'stat'
+
+			'<center><img <<$set_imgh>> src="images/characters/pavlovsk/school/head/35.jpg"></center>'
+			*nl
 			'You sit down next to Evgeny to talk. At first you try to catch his interest with ordinary things; he barely even responds to you, preoccupied playing against himself. Then you bring up a recent opening you have been trying and he perks up. Soon the two of you are talking about various openings and he shares with you some of his favorite ones and how he moves them to the mid game. You learn a bit about chess and feel like you are better friends with Evgeny.'
+
 			act 'Return': gt 'kruchess'
 		end
 	else
 		'On Saturdays, after a week''s training, club members spend the whole day playing against each other.'
+		*nl
+		if chess_win < 5:
+			'You have beaten Vitalik '+str(chess_win)+' times.'
+		elseif chess_win >= 5 and chess_win < 10:
+			'You have beaten Vitalik 5 times. You cannot play against him anymore.'
+			'You have beaten Kostya '+str(chess_win-5)+' times.'
+		elseif chess_win >= 10 and chess_win < 15:
+			'You have beaten Vitalik 5 times. You cannot play against him anymore.'
+			'You have beaten Kostya 5 times. You cannot play against him anymore.'
+			'You have beaten Sergei '+str(chess_win-10)+' times.'
+		elseif chess_win >= 15 and chess_win < 20:
+			'You have beaten Vitalik 5 times. You cannot play against him anymore.'
+			'You have beaten Kostya 5 times. You cannot play against him anymore.'
+			'You have beaten Sergei 5 times. You cannot play against him anymore.'
+			'You have beaten Coach Genrikh '+str(chess_win-15)+' times.'
+		elseif chess_win >= 20:
+			'You have beaten Vitalik 5 times. You cannot play against him anymore.'
+			'You have beaten Kostya 5 times. You cannot play against him anymore.'
+			'You have beaten Sergei 5 times. You cannot play against him anymore.'
+			'You have beaten Coach Genrikh 5 times. You cannot play against him anymore.'
+			'You have beaten Evgeny Kuznetsov '+str(chess_win-20)+' times. He is the only opponent left you can challenge.'
+		end
+		'You have won a total of '+str(chess_win)+' chess matches.'
+		*nl
+
 		if chess_win < 5:
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
 			'You are paired against Vitalik, the youngest boy in the club. Despite his age he has already achieved rank 4, the lowest official chess rank corresponding to an ELO rating of 1000+.'
-			act'Play':
+
+			act 'Play chess with Vitalik':
 				*clr & cla
 				$chess_name='Vitalik'
-				chessV=40
-				gt'chessplay'
+				chessV=10
+				gt 'chessplay'
 			end
 		elseif chess_win < 10:
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
 			'You get to play against Kostya, who recently advanced to rank 3 after passing 1400 ELO points.'
-			act'Play':
+
+			act 'Play chess with Kostya':
 				*clr & cla
 				$chess_name='Kostya'
-				chessV=100
-				gt'chessplay'
+				chessV=30
+				gt 'chessplay'
 			end
 		elseif chess_win < 15:
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
 			'You sit down to play Sergei. You recall that he is a rank 2 player with an ELO rating of more than 1600.'
-			act'Play':
+
+			act 'Play chess with Sergei':
 				*clr & cla
 				$chess_name='Sergei'
-				chessV=300
-				gt'chessplay'
+				chessV=50
+				gt 'chessplay'
 			end
 		elseif chess_win < 20:
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
-			'You are facing the chess coach. At his peak he achieved an ELO ranking of just over 2000, and despite his skills declining with age he still plays at the level of a rank 1 player.'
-			act'Play':
+			'You are facing Coach Genrikh. At his peak he achieved an ELO ranking of just over 2000, and despite his skills declining with age he still plays at the level of a rank 1 player.'
+
+			act 'Play chess with Coach Genrikh':
 				*clr & cla
-				$chess_name='Coach Genrikh G.'
-				chessV=800
-				gt'chessplay'
+				$chess_name='Coach Genrikh'
+				chessV=70
+				gt 'chessplay'
 			end
-		else
-			'<center><img <<$set_imgh>> src="images/locations/pavlovsk/community/chess/play' + rand(1,2) + '.jpg"></center>'
-			'You are facing Evgeny Kuznetsov. He has already won the regional championship twice and placed well at the nationals each year he has attended. He is already rated above a 2200 in the ELO rankings.'
-			act'Play':
+		elseif chess_win >= 20:
+			'You are challenging Evgeny Kuznetsov. He has already won the regional championship twice and placed well at the nationals each year he has attended. He is already rated above a 2200 in the ELO rankings.'
+
+			act 'Play chess with Evgeny':
 				*clr & cla
 				$chess_name='Evgeny'
-				chessV=900
-				gt'chessplay'
+				chessV=90
+				gt 'chessplay'
 			end
 		end
 	end
 
-	act 'Leave':gt'gdkkru'
+	act 'Leave':gt 'gdkkru'
 end
 
 --- kruchess ---------------------------------