Browse Source

[fixed] simplified some conditions in shulgabed to remove some duplication

Spackled Lanturn 3 years ago
parent
commit
815ec34c9a
1 changed files with 9 additions and 6 deletions
  1. 9 6
      locations/shulgabed.qsrc

+ 9 - 6
locations/shulgabed.qsrc

@@ -17,12 +17,15 @@ if $ARGS[0] = '' or $ARGS[0] = 'wakeup':
 	*nl
 	'Sergey''s bedroom looks just like any other bedroom. There''s a large bed, a television with a VCR connected to it, and a large cabinet to store clothes in. A random amount of junk is deposited on one of the nightstands.'
 
-	if hour < 7 or hour >= 23: 'When you come in, you see that<<$serg_obr>> <a href="exec: gt ''Serge_Shulgin'',''sleep''">Sergey</a> is currently on his bed, sound asleep.'
-
-	if week < 6 and ((hour >= 16 and hour < 18) or (hour >= 21 and hour < 23)): 'When you come in, you see that<<$serg_obr>> <a href="exec: gt ''Serge_Shulgin'',''tv''">Sergey</a> is relaxing on his bed, watching TV.'
-	if week >= 6 and ((hour >= 7 and hour < 18) or (hour >= 21 and hour < 23)): 'When you come in, you see that<<$serg_obr>> <a href="exec: gt ''Serge_Shulgin'',''tv''">Sergey</a> is relaxing on his bed, watching TV.'
-
-	if week < 6 and hour >= 7 and hour < 16: gs 'shulgabed', 'sleep'
+	if hour < 7 or hour >= 23:
+		'When you come in, you see that<<$serg_obr>> <a href="exec: gt ''Serge_Shulgin'',''sleep''">Sergey</a> is currently on his bed, sound asleep.'
+	elseif hour < 18 or hour >= 21:
+		if week < 6 and hour < 16:
+			gs 'shulgabed', 'sleep'
+		else
+			'When you come in, you see that<<$serg_obr>> <a href="exec: gt ''Serge_Shulgin'',''tv''">Sergey</a> is relaxing on his bed, watching TV.'
+		end
+	end
 
 	if RAND(0,100) <= 5 and soniaPS >= 1 and sexev_sonya_count > 0 and hour >= 15 and hour <= 23 and $ARGS[0] = '': gt 'shulgabed', 'sonya'
 	act 'Return to the hallway': gt 'shulgahall'