Selaa lähdekoodia

[changed/fixed] Change the churches to use a uniform function for reducing slut fame, that will also work if you have more than 400.

bgkjdgbizgblzdgbr 9 kuukautta sitten
vanhempi
säilyke
a5ad0e2227
4 muutettua tiedostoa jossa 28 lisäystä ja 67 poistoa
  1. 4 21
      locations/city_church.qsrc
  2. 14 2
      locations/fame.qsrc
  3. 5 22
      locations/gad_church.qsrc
  4. 5 22
      locations/pav_church.qsrc

+ 4 - 21
locations/city_church.qsrc

@@ -76,7 +76,7 @@ if $ARGS[0] = 'vigil':
 		pcs_horny -= 20
 		minut += 10
 		gs 'stat'
-		gs 'city_church', 'reducecityrep', 10, -2
+		gs 'fame', 'church_reduction', 'city', -2
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(9,10) +'.jpg"></center>'
 		'You decide to stay for the Rite of Mutual Forgiveness and feel much better afterwards.'
 		act 'Return to Narthex': gt 'city_church', 'Narthex'
@@ -92,6 +92,7 @@ if $ARGS[0] = 'liturgy':
 	pcs_mood += 20
 	church_moral += 1
 	gs 'themes', 'indoors'
+	gs 'fame', 'church_reduction', 'city', -1
 	PLAY 'sound/church/t' + rand(1,19) + '.mp3',30
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(1,8) +'.jpg"></center>'
 	'You join the congregation for the Divine Liturgy. You see mostly older people around, but there are some people around your age present as well. You participate in the singing, but that''s about it. Your presence seems to go largely unnoticed and you have the chance to rest. You feel a lot better.'
@@ -100,23 +101,6 @@ if $ARGS[0] = 'liturgy':
 	act 'Leave the church': gt 'city_church' , 'start'
 end
 
-if $ARGS[0] = 'reducecityrep':
-	citysextreshold = ARGS[1]
-	citysexreduction = ARGS[2]
-	if fame['city_sex'] > citysextreshold:
-		gs 'fame', 'city', 'sex', citysexreduction
-	else
-		gs 'fame', 'city', 'sex', -citysextreshold
-	end
-	if fame['city_prostitute'] > citysextreshold:
-		gs 'fame', 'city', 'prostitute', citysexreduction
-	else
-		gs 'fame', 'city', 'prostitute', -citysextreshold
-	end
-	killvar 'citysextreshold'
-	killvar 'citysexreduction'
-end
-
 if $ARGS[0] = 'Narthex':
 	CLOSE ALL
 	$menu_loc = 'city_church'
@@ -144,7 +128,7 @@ if $ARGS[0] = 'candle':
 	church_moral += 1
 	gs 'themes', 'indoors'
 	gs 'stat'
-	gs 'city_church', 'reducecityrep', 25, -1
+	gs 'fame', 'church_reduction', 'city', -1
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_candle.jpg"></center>'
 	if money >= 10 and owechurch = 0:
 		money -= 10
@@ -187,8 +171,7 @@ if $ARGS[0] = 'pray':
 		*clr & cla
 		menu_off = 1
 		minut += 10
-		if fame['city_sex'] > 10: gs 'fame', 'city', 'sex', -1
-		if fame['city_prostitute'] > 10: gs 'fame', 'city', 'prostitute', -1
+		gs 'fame', 'church_reduction', 'city', -1
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_praying.jpg"></center>'
 		if hour > 6 and hour < 20 and church_moral < 30:
 			pcs_horny -= 10

+ 14 - 2
locations/fame.qsrc

@@ -250,7 +250,7 @@ if $ARGS[0] = 'city' or $ARGS[0] = 'pav' or $ARGS[0] = 'pushkin' or $ARGS[0] = '
 			end
 		end
 		if dyneval('RESULT = fame[''<<$ARGS[0]>>_<<$ARGS[1]>>'']') < 0: dynamic 'fame[''<<$ARGS[0]>>_<<$ARGS[1]>>''] = 0'
-	
+
 		gs 'fame', 'calculateSlut'
 	!!main fame addition
 
@@ -775,4 +775,16 @@ if $ARGS[0] = 'calculateSlut':
 	end	
 end
 
---- fame ---------------------------------
+if $ARGS[0] = 'church_reduction':
+!! Special gs for reducing sex and prostitution fame by doing activities at the local church 
+	dynamic 'fame[''<<$ARGS[1]>>_sex''] += ARGS[2]'
+	dynamic 'fame[''<<$ARGS[1]>>_prostitute''] += ARGS[2]'
+
+	if dyneval('RESULT = fame[''<<$ARGS[1]>>_sex'']') < 0: dynamic 'fame[''<<$ARGS[1]>>_sex''] = 0'
+	if dyneval('RESULT = fame[''<<$ARGS[1]>>_prostitute'']') < 0: dynamic 'fame[''<<$ARGS[1]>>_prostitute''] = 0'
+
+	gs 'fame', 'calculateSlut'
+end
+
+--- fame ---------------------------------
+

+ 5 - 22
locations/gad_church.qsrc

@@ -76,7 +76,7 @@ if $ARGS[0] = 'vigil':
 		pcs_horny -= 20
 		minut += 10
 		gs 'stat'
-		gs 'gad_church', 'reducevillagerep', 10, -2
+		gs 'fame', 'church_reduction', 'village', -2
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(9,10) +'.jpg"></center>'
 		'You decide to stay for the Rite of Mutual Forgiveness and feel much better afterwards.'
 		act 'Return to Narthex': gt 'gad_church', 'Narthex'
@@ -92,6 +92,7 @@ if $ARGS[0] = 'liturgy':
 	pcs_mood += 20
 	church_moral += 1
 	gs 'themes', 'indoors'
+	gs 'fame', 'church_reduction', 'village', -1
 	PLAY 'sound/church/t' + rand(1,19) + '.mp3',30
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(1,8) +'.jpg"></center>'
 	'You join the congregation for the Divine Liturgy. You see mostly older people around, but some people around your age are also present. You participate in the singing, but that''s about it. Your presence seems to go largely unnoticed, and you have the chance to rest. You feel a lot better.'
@@ -100,23 +101,6 @@ if $ARGS[0] = 'liturgy':
 	act 'Leave the church': gt 'gad_church' , 'start'
 end
 
-if $ARGS[0] = 'reducevillagerep':
-	villagesextreshold = ARGS[1]
-	villagesexreduction = ARGS[2]
-	if fame['village_sex'] > villagesextreshold:
-		gs 'fame', 'village', 'sex', villagesexreduction
-	else
-		gs 'fame', 'village', 'sex', -villagesextreshold
-	end
-	if fame['village_prostitute'] > villagesextreshold:
-		gs 'fame', 'village', 'prostitute', villagesexreduction
-	else
-		gs 'fame', 'village', 'prostitute', -villagesextreshold
-	end
-	killvar 'villagesextreshold'
-	killvar 'villagesexreduction'
-end
-
 if $ARGS[0] = 'Narthex':
 	CLOSE ALL
 	$menu_loc = 'gad_church'
@@ -144,7 +128,7 @@ if $ARGS[0] = 'candle':
 	menu_off = 1
 	gs 'themes', 'indoors'
 	gs 'stat'
-	gs 'gad_church', 'reducevillagerep', 25, -1
+	gs 'fame', 'church_reduction', 'village', -1
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_candle.jpg"></center>'
 	'You approach the counter and take one of the candles, lighting it without giving a donation.'
 	act 'Return to Narthex': gt 'gad_church', 'Narthex'
@@ -158,7 +142,7 @@ if $ARGS[0] = 'candle1':
 	money -= 10
 	gs 'themes', 'indoors'
 	gs 'stat'
-	gs 'gad_church', 'reducevillagerep', 25, -1
+	gs 'fame', 'church_reduction', 'village', -1
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_candle.jpg"></center>'
 	'You approach the counter and put <b>₽</b>10 in the jar for a candle. Then, you take one of the candles and light it.'
 	act 'Return to Narthex': gt 'gad_church', 'Narthex'
@@ -176,8 +160,7 @@ if $ARGS[0] = 'pray':
 		*clr & cla
 		menu_off = 1
 		minut += 10
-		if fame['village_sex'] > 10: gs 'fame', 'village', 'sex', -1
-		if fame['village_prostitute'] > 10: gs 'fame', 'village', 'prostitute', -1
+		gs 'fame', 'church_reduction', 'village', -1
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_praying.jpg"></center>'
 		if hour > 6 and hour < 20 and church_moral < 30:
 			pcs_horny -= 10

+ 5 - 22
locations/pav_church.qsrc

@@ -112,6 +112,7 @@ if $ARGS[0] = 'Sermon':
 	cla & *clr
 	minut += 20
 	VK = rand(1,5)
+	gs 'fame', 'church_reduction', 'pav', -2
 	gs'stat'
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(1,5) +'.jpg"></center>'
 	if VK >= 0:
@@ -230,7 +231,7 @@ if $ARGS[0] = 'vigil':
 		Churchbad -= 1
 		minut += 10
 		gs 'stat'
-		gs 'pav_church', 'reducepavrep', 10, -2
+		gs 'fame', 'church_reduction', 'pav', -2
 
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/church'+ rand(9,10) +'.jpg"></center>'
 		'You decide to stay for the Rite of Mutual Forgiveness and feel much better afterwards.'
@@ -264,7 +265,7 @@ if $ARGS[0] = 'liturgy':
 		pcs_sleep += 5
 		'You participate fully in the Divine Liturgy, listening to the preaching and singing along. When going to communion and receiving the ceremonial bread, you lock eyes with Father Kirill. He seems happy to see you participating in the service.'
 	else
-		gs 'pav_church', 'reducepavrep', 25, -2
+		gs 'fame', 'church_reduction', 'pav', -2
 
 		Kirill += 1
 		pcs_mood +=20
@@ -281,23 +282,6 @@ if $ARGS[0] = 'liturgy':
 	act 'Leave the church': gt 'pav_church' , 'start'
 end
 
-if $ARGS[0] = 'reducepavrep':
-	pavsextreshold = ARGS[1]
-	pavsexreduction = ARGS[2]
-	if fame['pav_sex'] > pavsextreshold:
-		gs 'fame', 'pav', 'sex', pavsexreduction
-	else
-		gs 'fame', 'pav', 'sex', -pavsextreshold
-	end
-	if fame['pav_prostitute'] > pavsextreshold:
-		gs 'fame', 'pav', 'prostitute', pavsexreduction
-	else
-		gs 'fame', 'pav', 'prostitute', -pavsextreshold
-	end
-	killvar 'pavsextreshold'
-	killvar 'pavsexreduction'
-end
-
 if $ARGS[0] = 'Narthex':
 	CLOSE ALL
 	$menu_loc = 'pav_church'
@@ -418,7 +402,7 @@ if $ARGS[0] = 'candle':
 	Churchbad -= 1
 	gs 'themes', 'indoors'
 	gs 'stat'
-	gs 'pav_church', 'reducepavrep', 25, -1
+	gs 'fame', 'church_reduction', 'pav', -1
 	'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_candle.jpg"></center>'
 	if money >= 10 and owechurch = 0:
 		money -= 10
@@ -467,8 +451,7 @@ if $ARGS[0] = 'pray':
 		menu_off = 1
 		minut += 10
 		Churchbad -= 1
-		if fame['pav_sex'] > 10: gs 'fame', 'pav', 'sex', -1
-		if fame['pav_prostitute'] > 10: gs 'fame', 'pav', 'prostitute', -1
+		gs 'fame', 'church_reduction', 'pav', -1
 		'<center><img <<$set_imgh>> src="images/locations/pavlovsk/church/ch_praying.jpg"></center>'
 		if hour > 6 and hour < 20 and church_moral < 30:
 			pcs_horny -= 10