Преглед изворни кода

[added/change] Chnaged the clinincs to work with the new options for bad teeth, and cahnge the valirabel names to the new usage.

bgkjdgbizgblzdgbr пре 2 година
родитељ
комит
b53f1360f7
4 измењених фајлова са 151 додато и 95 уклоњено
  1. 2 2
      locations/Gnpc2.qsrc
  2. 69 44
      locations/city_clinic.qsrc
  3. 10 3
      locations/obj_din.qsrc
  4. 70 46
      locations/pav_clinic.qsrc

+ 2 - 2
locations/Gnpc2.qsrc

@@ -118,7 +118,7 @@ $din_gboy_go_to_disco = {
 											'You push back the Gopnik with all your strength and he stumbles backwards, hitting his head on the floor. But the second Gopnik turns to you and swings his fist towards your face.'
 											if pcs_agil < 60:
 												pcs_mood -= 30
-												pcs_teeth += 1
+												pcs_missing_teeth += 1
 												gs 'pain', 8, 'mouth', 'hit'
 												gs 'stat'
 												*pl $looseTooth
@@ -135,7 +135,7 @@ $din_gboy_go_to_disco = {
 													cla
 													if pcs_agil >= 40:
 														pcs_mood -= 30
-														pcs_teeth += 1
+														pcs_missing_teeth += 1
 														gs 'pain', 8, 'mouth', 'hit'
 														gs 'pain', 6, 'face', 'hit'
 														gs 'pain', 6, 'nose', 'hit'

+ 69 - 44
locations/city_clinic.qsrc

@@ -201,59 +201,84 @@ if $ARGS[0] = 'start':
 
 	if katjob > 0:act 'Visit the chief doctor': gt 'city_clinic', 'glavdoc'
 
-	if pcs_teeth > -1:
+	if (pcs_teeth > -1 and dentistday + 90 < daystart) or (pcs_missing_teeth > 0  and pcs_brace = 0):
 		act 'Go to the dentist':
 			*clr & cla
 			menu_off = 1
-			zubpay = pcs_teeth * 30000
+			minut += 15
 			gs 'stat'
-			if pcs_teeth = 0:
-				zubpay = 30000
-				'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to straighten and polish your teeth.'
-			elseif pcs_teeth = 1:
-				'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to replace your tooth'
+			
+			if pcs_brace = 1:
+				pcs_brace = 0
+				pcs_teeth -= 1
+				dentistday = daystart
+				'The dentist spends 15 minutes to take of you brace and clean up. You look at the mirror afterward and you teeth are '+iif(pcs_teeth = 0, 'now straight', 'straighter, but can still use some more work.')
+				gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+				gs 'stat'
 			else
-				'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to fill the gaps'
-			end
+				if pcs_missing_teeth * 30000 = 1:
+					zubpay = = 3000
+					'The dentist examines you and says, it will cost you <<3000>> <b>₽</b> to replace your tooth'
+				elseif 
+					zubpay = pcs_missing_teeth * 30000
+					'The dentist examines you and says, it will cost you <<pcs_missing_teeth * 30000>> <b>₽</b> to fill the gaps'
+				elseif pcs_teeth = 0:
+					zubpay = = 3000
+					'The dentist examines you and says, it will cost you <<3000>> <b>₽</b> to brighten and polish your teeth.'
+				elseif pcs_teeth > 0:
+					zubpay = = 45000
+					'The dentist examinees you and says, it will cost you <<4500>><b>₽</b> to straighten your teeth and you will have to wear a brace for three months and he can''t promise they will be completely straight after one treatment.'
+				end
 
-			if money < zubpay and karta < zubpay:
-				*nl
-				'You do not have enough money to fix your teeth.'
-			else
-				if money >= zubpay:
-					act 'Sort out your teeth (cash)':
-						*clr & cla
-						money -= zubpay
-						minut += 60
-						gs 'AppearanceSystem', 'UpdateBaseAppearnce'
-						gs 'stat'
-						if pcs_teeth > 0:
-							pcs_teeth = 0
-							'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
-						else
-							pcs_teeth = -1
-							'You pay the dentist to straighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
-						end
+				if money < zubpay and karta < zubpay:
+					*nl
+					'You do not have enough money to fix your teeth.'
+				else
+					if money >= zubpay:
+						act 'Sort out your teeth (cash)':
+							*clr & cla
+							money -= zubpay
+							minut += 60
+							if pcs_missing_teeth > 0:
+								pcs_missing_teeth = 0
+								'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
+							elseif pcs_teeth > 0
+								dentistday = daystart
+								pcs_brace = 1
+								'You pay the dentist to straighten your teeth. After and hour of work he have attached a brace to teeth and tells you to comeback it three months to have it taken of.'
+							else
+								dentistday = daystart
+								pcs_teeth = -1
+								'You pay the dentist to brighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+							end
+							gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+							gs 'stat'
 
-						act 'Leave the clinic': minut += 5 & gt 'city_residential'
-					end
-				end
-				if karta >= zubpay:
-					act 'Sort out your teeth (card)':
-						*clr & cla
-						karta -= zubpay
-						minut += 60
-						gs 'AppearanceSystem', 'UpdateBaseAppearnce'
-						gs 'stat'
-						if pcs_teeth > 0:
-							pcs_teeth = 0
-							'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
-						else
-							pcs_teeth = -1
-							'You pay the dentist to straighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+							act 'Leave the clinic': minut += 5 & gt 'city_residential'
 						end
+					end
+					if karta >= zubpay:
+						act 'Sort out your teeth (card)':
+							*clr & cla
+							money -= zubpay
+							minut += 60
+							if pcs_missing_teeth > 0:
+								pcs_missing_teeth = 0
+								'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
+							elseif pcs_teeth > 0
+								dentistday = daystart
+								pcs_brace = 1
+								'You pay the dentist to straighten your teeth. After and hour of work he have attached a brace to teeth and tells you to comeback it three months to have it taken of.'
+							else
+								pcs_teeth = -1
+								dentistday = daystart
+								'You pay the dentist to brighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+							end
+							gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+							gs 'stat'
 
-						act 'Leave the clinic': minut += 5 & gt 'city_residential'
+							act 'Leave the clinic': minut += 5 & gt 'city_residential'
+						end
 					end
 				end
 			end

+ 10 - 3
locations/obj_din.qsrc

@@ -311,9 +311,16 @@ if $ARGS[0] = 'description':
 
 	if salo < 10 and strenbuf > 0 and dounspell = 0: '<b><font color="red">You are showing signs of malnourishment. You should probably eat more and more often.</font></b>'
 	if salo < 10 and strenbuf = 0 and dounspell = 0: '<b><font color="red">You are dangerously malnourished, which has led to a loss in muscle mass. You''re in a critical condition and likely to pass out!</font></b>'
-	if pcs_teeth = 1:$zuba = ' tooth'
-	if pcs_teeth >= 2:$zuba = ' teeth'
-	if pcs_teeth > 0: 'You have lost <<pcs_teeth>><<$zuba>>.'
+	if pcs_missing_teeth = 1:$zuba = ' tooth'
+	if pcs_missing_teeth >= 2:$zuba = ' teeth'
+	if pcs_missing_teeth > 0: 'You have lost <<pcs_missing_teeth>><<$zuba>>.'
+	if pcs_teeth = -1:
+		'You have a perfect white smile.'
+	elseif pcs_teeth > 0:
+		'Your teeth are not straight at all. It might be a good idea to see a dentist to straighten them.'
+	else
+		'Your teeth are miscoloured. It might be a good idea to see a dentist to get them cleaned up.'
+	end
 
 	!! 'pcs_apprnc <<pcs_apprnc>>'
 	!! 'curlykoef <<curlykoef>> a maximum of 1'

+ 70 - 46
locations/pav_clinic.qsrc

@@ -138,63 +138,87 @@ if $ARGS[0] = '':
 			end
 		end
 
-		if pcs_teeth > -1:
+		if (pcs_teeth > -1 and dentistday + 90 < daystart) or (pcs_missing_teeth > 0  and pcs_brace = 0):
 			act 'Go to the dentist':
 				*clr & cla
 				menu_off = 1
-				zubpay = pcs_teeth * 30000
+				minut += 15
 				gs 'stat'
-				if pcs_teeth = 0:
-					zubpay = 30000
-					'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to straighten and polish your teeth.'
-				elseif pcs_teeth = 1:
-					'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to replace your tooth'
+			
+				if pcs_brace = 1:
+					pcs_brace = 0
+					pcs_teeth -= 1
+					dentistday = daystart
+					'The dentist spends 15 minutes to take of you brace and clean up. You look at the mirror afterward and you teeth are '+iif(pcs_teeth = 0, 'now straight', 'straighter, but can still use some more work.')
+					gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+					gs 'stat'
 				else
-					'The dentist examines you and says, it will cost you <<zubpay>> <b>₽</b> to fill the gaps'
-				end
+					if pcs_missing_teeth * 30000 = 1:
+						zubpay = = 3000
+						'The dentist examines you and says, it will cost you <<3000>> <b>₽</b> to replace your tooth'
+					elseif 
+						zubpay = pcs_missing_teeth * 30000
+						'The dentist examines you and says, it will cost you <<pcs_missing_teeth * 30000>> <b>₽</b> to fill the gaps'
+					elseif pcs_teeth = 0:
+						zubpay = = 3000
+						'The dentist examines you and says, it will cost you <<3000>> <b>₽</b> to brighten and polish your teeth.'
+					elseif pcs_teeth > 0:
+						zubpay = = 45000
+						'The dentist examinees you and says, it will cost you <<4500>><b>₽</b> to straighten your teeth and you will have to wear a brace for three months and he can''t promise they will be completely straight after one treatment.'
+					end
 
-				if money < zubpay and karta < zubpay:
-					*nl
-					'You do not have enough money to fix your teeth.'
-				else
-					if money >= zubpay:
-						act 'Sort out your teeth (cash)':
-							*clr & cla
-							money -= zubpay
-							minut += 60
-							gs 'AppearanceSystem', 'UpdateBaseAppearnce'
-							gs 'stat'
-							if pcs_teeth > 0:
-								pcs_teeth = 0
-								'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
-							else
-								pcs_teeth = -1
-								'You pay the dentist to straighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
-							end
+					if money < zubpay and karta < zubpay:
+						*nl
+						'You do not have enough money to fix your teeth.'
+					else
+						if money >= zubpay:
+							act 'Sort out your teeth (cash)':
+								*clr & cla
+								money -= zubpay
+								minut += 60
+								if pcs_missing_teeth > 0:
+									pcs_missing_teeth = 0
+									'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
+								elseif pcs_teeth > 0
+									dentistday = daystart
+									pcs_brace = 1
+									'You pay the dentist to straighten your teeth. After and hour of work he have attached a brace to teeth and tells you to comeback it three months to have it taken of.'
+								else
+									dentistday = daystart
+									pcs_teeth = -1
+									'You pay the dentist to brighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+								end
+								gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+								gs 'stat'
 
-							act 'Leave the clinic': minut += 5 & gt 'pav_commercial'
-						end
-					end
-					if karta >= zubpay:
-						act 'Sort out your teeth (card)':
-							*clr & cla
-							karta -= zubpay
-							minut += 60
-							gs 'AppearanceSystem', 'UpdateBaseAppearnce'
-							gs 'stat'
-							if pcs_teeth > 0:
-								pcs_teeth = 0
-								'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
-							else
-								pcs_teeth = -1
-								'You pay the dentist to straighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+								act 'Leave the clinic': minut += 5 & gt 'pav_commercial'
 							end
+						end
+						if karta >= zubpay:
+							act 'Sort out your teeth (card)':
+								*clr & cla
+								money -= zubpay
+								minut += 60
+								if pcs_missing_teeth > 0:
+									pcs_missing_teeth = 0
+									'You pay the dentist to fix your teeth, within an hour he has restored your winning smile.'
+								elseif pcs_teeth > 0
+									dentistday = daystart
+									pcs_brace = 1
+									'You pay the dentist to straighten your teeth. After and hour of work he have attached a brace to teeth and tells you to comeback it three months to have it taken of.'
+								else
+									pcs_teeth = -1
+									dentistday = daystart
+									'You pay the dentist to brighten and polish your teeth, an hour later your smile is much brighter and more attractive.'
+								end
+								gs 'AppearanceSystem', 'UpdateBaseAppearnce'
+								gs 'stat'
 
-							act 'Leave the clinic': minut += 5 & gt 'pav_commercial'
+								act 'Leave the clinic': minut += 5 & gt 'pav_commercial'
+							end
 						end
 					end
-				end				
-					
+				end
 				act 'Leave the clinic': minut += 5 & gt 'pav_commercial'
 			end
 		end