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

There were some situations where not every restriction cleared. Fixed.

netuttki пре 1 година
родитељ
комит
ac3c49f594
4 измењених фајлова са 13 додато и 1 уклоњено
  1. 2 0
      locations/bedrPar.qsrc
  2. 7 1
      locations/music_actions.qsrc
  3. 2 0
      locations/sitr.qsrc
  4. 2 0
      locations/sitr2x.qsrc

+ 2 - 0
locations/bedrPar.qsrc

@@ -274,6 +274,8 @@ if $ARGS[0] = '' or $ARGS[0] = 'start':
 			access['nocamshow'] = 1
 			$access['noporn-message'] = 'You shouldn''t watch porn with your sister in the room, she would notice for sure!'
 			$access['nocamshow-message'] ='You can''t do any webcam activities with your sister in the room!'
+		else
+			gs 'music_actions', 'clear_restrictions'
 		end
 
 		if locat['Anya_inroom'] = 0 and breastpump = 1 and bp_unbox <= 0:

+ 7 - 1
locations/music_actions.qsrc

@@ -31,7 +31,7 @@ if $ARGS[0] = 'start':
         killvar 'access'
     end
     
-    if ml_not_alone = 0: gs 'music_actions', 'willpower_cost'
+    if ml_not_alone ! 0: gs 'music_actions', 'willpower_cost'
     if $access = '': gs 'internet_mobile', 'get_access'
 
     !! $location_type = ''private'' = these are usually homes. ''indoors'' usually an office, shop or an NPC''s home. Same for ''public_indoors'' For those locations
@@ -323,6 +323,12 @@ if $ARGS[0] = 'willpower_cost':
     end
 end
 
+if $ARGS[0] = 'clear_restrictions':
+    killvar 'ml_willcost'
+    killvar 'ml_not_alone'
+    killvar 'ml_no_music'
+end
+
 if $ARGS[0] = 'finish':
     killvar 'ml_willcost'
     killvar 'ml_not_alone'

+ 2 - 0
locations/sitr.qsrc

@@ -67,6 +67,8 @@ if husband > 0 and husbandrink ! 10 and husbandrinkday ! daystart:
 	if (week >= 6 and hour > 7 and hour < 17) or (hour > 17 and hour <= 22):
 		'<a href="exec:gt ''husb'', ''start''">Your husband sits on the couch and watches television.</a>'
 		gs 'music_actions', 'not_alone'
+	else
+		gs 'music_actions', 'clear_restrictions'
 	end
 end
 

+ 2 - 0
locations/sitr2x.qsrc

@@ -57,6 +57,8 @@ if husband > 0 and husbandrink ! 10 and husbandrinkday ! daystart:
 	if (week >= 6 and hour > 7 and hour < 17) or (hour > 17 and hour <= 22):
 		'<a href="exec: gt''husb'',''start'' ">Your husband is sitting on the couch watching TV.</a>'
 		gs 'music_actions', 'not_alone'
+	else
+		gs 'music_actions', 'clear_restrictions'
 	end
 end