Forráskód Böngészése

[added/changed] Implemented the new sms schedule system for the band tour and the nerd game night invites, which moved the schedule from `hourly_events` to `cikl` (and technically `stat`). Made some layout updates. Added a fourth option to the nerd game invite, allowing for the option to skip a week and quit entirely

anjuna krokus 1 hónapja
szülő
commit
ec286de0b1

+ 5 - 2
locations/band_tour_anushka_SMS.qsrc

@@ -76,8 +76,9 @@ if $ARGS[0] = 'start':
 
 	elseif anushkaQW['num_tour_SMS_send'] = 11:
 		gs 'band_tour_anushka_SMS', 'Week11', 'Add SMS'
-
+		gopnikbandQW['on_tour'] = 0
 	end
+	gs 'telefon', 'SetSMSSchedule', 'A144', "", "0", "", "0"
 end
 
 
@@ -109,7 +110,9 @@ if $ARGS[0] = 'Week1':
 	elseif $ARGS[1] = 'Choice_a':
 		!! Add Anushka to the contact list if she isn''t in it yet.
 		!! Is here to add it after reading the text.
-		if arrpos('$contact', 'A144') = -1: gs 'telefon', 'AddContact', 'A144', 'images/characters/shared/headshots_main/big144.jpg', 0
+		temp_pos = arrpos('$contact', 'A144')
+		if temp_pos = -1 or contactAnon[temp_pos] = 1: gs 'telefon', 'AddContact', 'A144', 'images/characters/shared/headshots_main/big144.jpg', 0
+		killvar 'temp_pos'
 
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['a1']

+ 70 - 37
locations/cikl.qsrc

@@ -124,7 +124,7 @@ end
 !! terminate tour gide job when its off season
 if emp_job_status[1] = 1 and month < 6 and month > 8:
 	if work = 1: work = 0
-	emp_job_status[1]  = 4
+	emp_job_status[1] = 4
 end
 
 dynamic $hypnoDaychange
@@ -234,7 +234,7 @@ if bimbo >= 40: bimbo = 40
 
 !!Bimbo levels. They use custom variables so they won''t permanently change character stats
 if bimbolevel = 0: supnatvnesh = 0 & bimbostupidity = 0
-if  CheatBimbo2 = 0:
+if CheatBimbo2 = 0:
 	if bimbolevel = 1: supnatvnesh = 2 & bimbostupidity = (pcs_intel / 6)
 	if bimbolevel = 2: supnatvnesh = 2 & bimbostupidity = (pcs_intel / 4)
 	if bimbolevel = 3: supnatvnesh = 4 & bimbostupidity = (pcs_intel / 3)
@@ -420,8 +420,8 @@ else
 	isprok_lastday = 0
 end
 
-if Enable_auto_tampons =  0 and isprok = 1: isprok = 0 & 'You threw away your used tampon.'
-if Enable_auto_tampons =  0 and isprokp = 1:isprokp = 0 & 'You threw away your used sanitary pad.'
+if Enable_auto_tampons = 0 and isprok = 1:  isprok  = 0 & 'You threw away your used tampon.'
+if Enable_auto_tampons = 0 and isprokp = 1: isprokp = 0 & 'You threw away your used sanitary pad.'
 
 if lactation['nipgrowth'] > 0:
 	tmp = rand(0,2)
@@ -632,7 +632,7 @@ if GspravkaT = 1:Gspravka -= 1
 if BurgerQW['IlyQW'] = 2 and BurgerQW['IlyQWPoliceDayCount'] > 0 and BurgerQW['IlyQWPoliceDayCount'] < 30: 
 	BurgerQW['IlyQWPoliceDayCount'] += 1
 elseif BurgerQW['IlyQW'] = 2 and BurgerQW['IlyQWPoliceDayCount'] = 30: 
-	BurgerQW['IlyQW']  = 3
+	BurgerQW['IlyQW'] = 3
 end
 
 !!Remove degradation for inhibition
@@ -798,7 +798,7 @@ if mid($start_type, 1, 2) = 'sg':
 			killvar 'first_time_outside_in_cold_weather'
 			killvar 'first_time_doing_basketball'
 			killvar 'first_time_spring_football_match'
-!! end inc  
+!! end inc
 		elseif month = 10 and day >= 29:
 			$holyday = '<b>Autumn Break starts in <<35-day>> days.</b>'
 		elseif month = 11:
@@ -952,12 +952,45 @@ if natholi = 1:
 end
 
 
+
+
+	!!====================================================================!!
+	!!                                                                    !!
+	!!                      Setting story SMS times                       !!
+	!!                                                                    !!
+	!!====================================================================!!
+
+
+!{
 !! Anushka''s band is on tour from Thursday 01-06 until Saturday 19-08. Blame Nutluck
 if year = 2017 and ( month = 6 or month = 7 or (month = 8 and day < 19) ):
 	gopnikbandQW['on_tour'] = 1
 else
 	gopnikbandQW['on_tour'] = 0
 end
+}
+
+if nerd_game['invite_day'] < daystart and week = 1:
+	if nerd_game['first_SMS_received'] = 0: if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'icon_na', 1
+	gs 'telefon', 'SetSMSSchedule', 'A152', "", "0", "gs 'nerd_game_night', 'game_invite_sms_switch'", "totminut > <<totminut + (11 - hour) * 60 + rand(20, 280) - minut>>"
+end
+
+
+if year = 2017 and month = 6 and gopnikbandQW['on_tour'] = 0:
+	gopnikbandQW['on_tour'] = 1
+	if npc_rel['A144'] >= 50 and arrpos('$contact', 'A144') < 0: gs 'telefon', 'AddContact', 'A144', 'icon_na', 1
+elseif gopnikbandQW['on_tour'] = 1 and year = 2017 and month = 8 and day => 19:
+	gopnikbandQW['on_tour'] = 0
+end
+
+if gopnikbandQW['on_tour'] = 1 and npc_rel['A144'] >= 50 and anushkaQW['tour_SMS_send'] < daystart and anushkaQW['num_tour_SMS_send'] < 11:
+	if anushkaQW['num_tour_SMS_send'] <= 9 and week = 6:
+		gs 'telefon', 'SetSMSSchedule', 'A144', "", "0", "gs 'band_tour_anushka_SMS', 'start'", "totminut > <<totminut + (12 - hour) * 60 + rand(20, 100) - minut>>"
+
+	elseif anushkaQW['num_tour_SMS_send'] = 10 and week = 2:
+		gs 'telefon', 'SetSMSSchedule', 'A144', "", "0", "gs 'band_tour_anushka_SMS', 'start'", "totminut > <<totminut + (19 - hour) * 60 + rand(20, 100) - minut>>"
+	end
+end
 
 
 
@@ -1051,7 +1084,7 @@ end
 !!------------------------------------------------------------------------------------------------------------
 
 !!---------- School related schedule -------------------------------------------------------------------------
-starlets_on     = iif( ( (week = 5 and odd_week = 0) or (week = 1 or week = 3 or week >= 6) ) and natholi = 0,1,0)
+starlets_on		= iif( ( (week = 5 and odd_week = 0) or (week = 1 or week = 3 or week >= 6) ) and natholi = 0,1,0)
 cheerleaders_on = iif( ( (week = 5 and odd_week = 1) or (week = 2 or week = 4) ) and (natholi = 0 and (month >9 or month <6)) ,1,0)
 
 if starlets['late_message'] = 1: starlets['late_message'] = 0
@@ -1069,7 +1102,7 @@ end
 
 if month = 9 and day = 16 and AlbinaQW['ParkRally'] = 0: AlbinaQW['ParkRally'] = 1
 if month = 10 and day = 16 and AlbinaQW['ParkRally'] = 1: AlbinaQW['ParkRally'] = 2
-if month  = 11 and day = 19 and (AlbinaQW['StarletsJoined'] <= 0 or (AlbinaQW['StarletsJoined'] = 1 and npc_pregtalk['A23'] = 1)) and AlbinaQW['StarletsShutDown'] = 0: AlbinaQW['StarletsShutDown'] = 1
+if month = 11 and day = 19 and (AlbinaQW['StarletsJoined'] <= 0 or (AlbinaQW['StarletsJoined'] = 1 and npc_pregtalk['A23'] = 1)) and AlbinaQW['StarletsShutDown'] = 0: AlbinaQW['StarletsShutDown'] = 1
 
 !!------------------------------------------------------------------------------------------------------------
 
@@ -1098,9 +1131,9 @@ end
 if ml_onlinesongcount > 0:
 	i = 0
 	j = -1
-    
-	:looponlinesongs        
-!!      this so every song counts only every 7 days and only for a limited number of weeks 
+
+	:looponlinesongs
+!!		this so every song counts only every 7 days and only for a limited number of weeks 
 		if ml_onlinesong_freshness[i] > 0:		
 			j += 1
 			ml_tempsong_freshness[j] = ml_onlinesong_freshness[i]
@@ -1186,7 +1219,7 @@ if $lib_book_loaned ! '': lib_debt += 50
 !!------------- Preliminary npc_uni_eduTipe  ------------------------------------------
 !! 
 !!npc_uni_eduType = '', 'professor', 'teaching_studies', 'business_studies', 'science_studies', 'fashion_studies'
-!!                  'nursing_studies', 'psychology_studies', 'programming_studies', 'other_studies'
+!!				'nursing_studies', 'psychology_studies', 'programming_studies', 'other_studies'
 !!
 !!Will eventually need to be moved to the npcstatic and npcstaticdefault files for eternal uni npcs
 !!To specific event checks for pav_uni npcs
@@ -1253,31 +1286,31 @@ if will_counter >= 20: will_counter -= 20 & willpowermax += 1
 
 !!-----------------webcam follower loss due to inactivity ------------------------------------------
 if camwhore = 1:
-    if cam_daystart < daystart:
-        engagementFactor = 1 + (CamBonus / 100)
-        popularityFactor = webpopular / 1000
-
-        if regviewReset < 3:
-            if regview >= 500:
-                FollowersLost = rand(regview / (100 * engagementFactor), regview / (50 * engagementFactor)) + popularityFactor
-            else
-                FollowersLost = rand(1, 3) + popularityFactor
-            end
-            cam_daystart = daystart + max(1, 3 - (CamBonus / 50))
-        else
-            if regview >= 300:
-                FollowersLost = rand(regview / (80 * engagementFactor), regview / (40 * engagementFactor)) + popularityFactor
-            else
-                FollowersLost = rand(2, 6) + popularityFactor
-            end
-            cam_daystart = daystart + max(1, 2 - (CamBonus / 50))
-        end
-        regviewReset += 1
-        FollowersLost = func('shortgs', 'clamp', FollowersLost, 0, regview)
-        totFollowersLost += FollowersLost
-        regview -= FollowersLost
-        killvar 'FollowersLost'
-    end
+	if cam_daystart < daystart:
+		engagementFactor = 1 + (CamBonus / 100)
+		popularityFactor = webpopular / 1000
+
+		if regviewReset < 3:
+			if regview >= 500:
+				FollowersLost = rand(regview / (100 * engagementFactor), regview / (50 * engagementFactor)) + popularityFactor
+			else
+				FollowersLost = rand(1, 3) + popularityFactor
+			end
+			cam_daystart = daystart + max(1, 3 - (CamBonus / 50))
+		else
+			if regview >= 300:
+				FollowersLost = rand(regview / (80 * engagementFactor), regview / (40 * engagementFactor)) + popularityFactor
+			else
+				FollowersLost = rand(2, 6) + popularityFactor
+			end
+			cam_daystart = daystart + max(1, 2 - (CamBonus / 50))
+		end
+		regviewReset += 1
+		FollowersLost = func('shortgs', 'clamp', FollowersLost, 0, regview)
+		totFollowersLost += FollowersLost
+		regview -= FollowersLost
+		killvar 'FollowersLost'
+	end
 end
 
 

+ 0 - 45
locations/hourly_events.qsrc

@@ -321,49 +321,4 @@ gs 'katja_procedural', 'hourly'
 
 if (hour mod 2) = 0: gs 'outdoors', 'weather'
 
-
-
-
-
-!!===========================================================================!!
-!!                                                                           !!
-!!                             ?Story triggers?                              !!
-!!                                                                           !!
-!!===========================================================================!!
-
-
-!! I do not think that this should be here, but I put it here temporaly - rachels
-!! generate SMS for nerd games
-if nerd_game['invite_day'] < daystart and week = 1 and hour >= 11 and hour <= 15:
-	if yearstart = 1 and (grupTipe = 3 or nerd_game['stage'] > 0 or rand(80,npc_rel['A152']) > 95):
-		!! hour = 15 forces SMS if it hasn''t triggered yet.
-		if rand(0, 2) = 0 or hour = 15:
-			gs 'nerd_game_night', 'summer_invite_sms', 'Add SMS'
-		end
-
-	elseif yearstart > 1 and nerd_game['fixed_uni_day'] = 0 and (nerd_game['stage'] > 0 or rand(80,npc_rel['A152']) > 95):
-		!! hour = 15 forces SMS if it hasn''t triggered yet.
-		if rand(0, 2) = 0 or hour = 15:
-			gs 'nerd_game_night', 'summer2_invite_sms', 'Add SMS'
-		end
-	end
-end
-
-
-!! Generate SMS for anushka''s band tour. Blame Nutluck
-if gopnikbandQW['on_tour'] = 1 and npc_rel['A144'] >= 50 and anushkaQW['tour_SMS_send'] < daystart and anushkaQW['num_tour_SMS_send'] < 11:
-	if anushkaQW['num_tour_SMS_send'] <= 9 and week = 6 and (hour = 12 or hour = 13):
-		if rand(0, 1) = 0 or hour = 13:
-			gs 'band_tour_anushka_SMS', 'start'
-		end
-
-	elseif anushkaQW['num_tour_SMS_send'] = 10 and week = 2 and (hour = 19 or hour = 20):
-		if rand(0, 1) = 0 or hour = 20:
-			gopnikbandQW['on_tour'] = 0
-			gs 'band_tour_anushka_SMS', 'start'
-		end
-	end
-end
-
 --- hourly_events ---------------------------------
-

+ 117 - 87
locations/nerd_game_night.qsrc

@@ -1467,8 +1467,24 @@ if $ARGS[0] = 'zinaida':
 end
 
 
-if $ARGS[0] = 'summer_invite_sms':
+if $ARGS[0] = 'game_invite_sms_switch':
+	if $start_type['loc'] = 'sg' and (grupTipe = 3 or nerd_game['stage'] > 0 or rand(80, npc_rel['A152']) > 95):
+		gs 'nerd_game_night', 'summer_invite_sms', 'Add SMS'
+	elseif ($start_type['loc'] = 'uni' or $start_type['loc'] = 'city') and nerd_game['fixed_uni_day'] = 0 and (nerd_game['stage'] > 0 or rand(80, npc_rel['A152']) > 95):
+		gs 'nerd_game_night', 'summer2_invite_sms', 'Add SMS'
+	end
+	gs 'telefon', 'SetSMSSchedule', 'A152', "", "0", "", "0"
+end
+
+if $ARGS[0] = 'first_text':
+	temp_pos = arrpos('$contact', 'A152')
+	if temp_pos = -1 or contactAnon[temp_pos] = 1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
+	killvar 'temp_pos'
+	nerd_game['first_SMS_received'] = 1
+end
 
+
+if $ARGS[0] = 'summer_invite_sms':
 	if $ARGS[1] = 'Add SMS':
 		nerd_game['lot'] = func('shortgs', 'rand_pick', '', 12, 13, 14, 23, 24, 34)
 	end
@@ -1480,17 +1496,22 @@ if $ARGS[0] = 'summer_invite_sms':
 		$SMSTree[ '0'] = 'Hey <<$pcs_nickname>>, would you like to join us for our weekly game night? We have a few nights free this week and were wondering which one works best for you. We can do it either on <<$week[val(mid(nerd_game[''lot''],1,1))]>> or <<$week[val(mid(nerd_game[''lot''],2,1))]>>.'
 	end
 
-		$SMSTree['ca1'] = 'Not interested'
-			$SMSTree['a1'] = 'Sorry, but I''m just not interested in stuff like that. Thanks for the invite though.'
-				$SMSTree['a2'] = ':-( Oh... okay yeah I get it. Guess we''ll see you around.'
+		$SMSTree['ca1'] = '<<$week[val(mid(nerd_game[''lot''],1,1))]>>'
+			$SMSTree['a1'] = 'Sure, I can make it on <<$week[val(mid(nerd_game[''lot''],1,1))]>>.'
+				$SMSTree['a2'] = ':-) Great! I''ll see you on <<$week[val(mid(nerd_game[''lot''],1,1))]>> at 20:00 in the library then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
+
+		$SMSTree['cb1'] = '<<$week[val(mid(nerd_game[''lot''],2,1))]>>'
+			$SMSTree['b1'] = 'Sure, I can make it on <<$week[val(mid(nerd_game[''lot''],2,1))]>>.'
+				$SMSTree['b2'] = ':-) Great! I''ll see you on <<$week[val(mid(nerd_game[''lot''],2,1))]>> at 20:00 in the library then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
 
-		$SMSTree['cb1'] = '<<$week[val(mid(nerd_game[''lot''],1,1))]>>'
-			$SMSTree['b1'] = 'Sure, I can make it on <<$week[val(mid(nerd_game[''lot''],1,1))]>>.'
-				$SMSTree['b2'] = ':-) Great! I''ll see you on <<$week[val(mid(nerd_game[''lot''],1,1))]>> at 20:00 in the library then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
+		$SMSTree['cc1'] = 'Not this week'
+			$SMSTree['c1'] = 'Sorry I don''t have time this week, but next week I should be able too.'
+				$SMSTree['c2'] = ':-( Oh... okay yeah I get it. Guess we''ll see you next week.'
 
-		$SMSTree['cc1'] = '<<$week[val(mid(nerd_game[''lot''],2,1))]>>'
-			$SMSTree['c1'] = 'Sure, I can make it on <<$week[val(mid(nerd_game[''lot''],2,1))]>>.'
-				$SMSTree['c2'] = ':-) Great! I''ll see you on <<$week[val(mid(nerd_game[''lot''],2,1))]>> at 20:00 in the library then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
+		$SMSTree['cd1'] = 'Not interested'
+			$SMSTree['cd2'] = '<font color="red">This ends the D&D Campaign - Forever</font>'
+				$SMSTree['d2'] = 'Sorry, but I''m just not interested in stuff like that. Thanks for the invite though.'
+					$SMSTree['d3'] = ':-( Oh... okay yeah I get it. Guess we''ll see you around.'
 
 
 	if $ARGS[1] = 'Add SMS':
@@ -1502,103 +1523,102 @@ if $ARGS[0] = 'summer_invite_sms':
 			gs 'SMStext_builder', 'add_reply', $SMSTree['ca1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_a'
 			gs 'SMStext_builder', 'add_reply', $SMSTree['cb1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_b'
 			gs 'SMStext_builder', 'add_reply', $SMSTree['cc1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_c'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cd1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_d'
 
 			gs 'SMStext_builder', 'add_sms', 'A152'
 		gs 'SMStext_builder', 'end'
-	
-	elseif $ARGS[1] = 'Choice_a':
+	else
 		!! Add Feofan to the contact list if he isn''t in it yet.
 		!! Is here to add it after reading the text.
 		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
+			gs 'nerd_game_night', 'first_text'
 		end
+	end
 
+	if $ARGS[1] = 'Choice_a':
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['a1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+			nerd_game['game_day'] = daystart - week + val(mid(nerd_game['lot'], 1, 1))
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['a2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
-!!		nerd_game['invite_day'] = 2147483647 & ! block the event
-	
-	elseif $ARGS[1] = 'Choice_b':
-		!! Add Feofan to the contact list if he isn''t in it yet.
-		!! Is here to add it after reading the text.
-		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
-		end
-
-		nerd_game['game_day'] = daystart - week + val(mid(nerd_game['lot'],1,1))
 
+	elseif $ARGS[1] = 'Choice_b':
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['b1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+			nerd_game['game_day'] = daystart - week + val(mid(nerd_game['lot'], 2, 1))
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['b2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
 
 	elseif $ARGS[1] = 'Choice_c':
-		!! Add Feofan to the contact list if he isn''t in it yet.
-		!! Is here to add it after reading the text.
-		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
-		end
-
-		nerd_game['game_day'] = daystart - week + val(mid(nerd_game['lot'],2,1))
-
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['c1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['c2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
-	end
 
-	killvar '$SMSTree'
-end
+	elseif $ARGS[1] = 'Choice_d':
+		gs 'SMStext_builder', 'start'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['ca1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_a'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cb1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_b'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cc1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_c'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cd2'], 'nerd_game_night', 'summer_invite_sms', 'Choice_d1'
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+		gs 'SMStext_builder', 'end'
 
-if $ARGS[0] = 'summer2_invite_sms':
-	$SMS_open_receiving = '<table width=80%><tr><td collspan=2 bgcolor="#D4CEF9"><font color=black>'
-	$SMS_close_receiving = '</font></td><td width=10%></td></tr></table>'
+	elseif $ARGS[1] = 'Choice_d1':
+		gs 'SMStext_builder', 'start'
+			gs 'SMStext_builder', 'send', $SMSTree['d2']
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+			nerd_game['invite_day'] += 7305		& ! Next campaign in 20 years.
 
-	!! Open and close sending text
-	$SMS_open_sending = '<table width=80%><tr><td width=10%></td><td collspan=2 bgcolor=pink><font color=black>'
-	$SMS_close_sending = '</font></td></tr></table>'
+			wait 100
 
-	!! Start reply
-	$SMS_open_replies = '<table><tr><th> Reply</th></tr><tr><td>'
-	$SMS_next_reply = '</td></tr><tr><td>'
-	$SMS_close_replies = '</td></tr></table>'
-	
-	$temp_SMStext = ''
+			gs 'SMStext_builder', 'receive', $SMSTree['d3']
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+		gs 'SMStext_builder', 'end'
+	end
 
+	killvar '$SMSTree'
+end
 
+if $ARGS[0] = 'summer2_invite_sms':
 	if nerd_game['first_SMS_received'] = 0:
 		$SMSTree[ '0'] = 'Hey <<$pcs_nickname>> this is Feofan. We are doing our weekly game night at the Coffee Hole, coffee shop now. We will mostly be playing Dungeons and Dragons and board games. I was talking to the others and we were wondering if you was going to keep playing with us? We have a few nights free this week and were wondering which night works best for you. We can do it either on Tuesday or Thursday.'
 	else
 		$SMSTree[ '0'] = 'Hey <<$pcs_nickname>>, would you like to join us for our weekly game night at the Coffee Hole? We have a few nights free this week and were wondering which night works best for you. We can do it either on Tuesday or Thursday.'
 	end
 
-		$SMSTree['ca1'] = 'Not interested'
-			$SMSTree['a1']  = 'Sorry, but I''m just not interested in stuff like that anymore. Thanks for the invite though.'
-				$SMSTree['a2'] = ':-( Oh... Okay, yeah I get it. Guess we''ll see you around.'
+		$SMSTree['ca1'] = 'Tuesday'
+			$SMSTree['a1'] = 'Sure, I can make it on Tuesday.'
+				$SMSTree['a2'] = ':-) Great! I''ll see you on Tuesday at 18:00 at the Coffee Hole then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
+
+		$SMSTree['cb1'] = 'Thursday'
+			$SMSTree['b1'] = 'Sure, I can make it on Thursday.'
+				$SMSTree['b2'] = ':-) Great! I''ll see you on Thursday at 18:00 at the Coffee Hole then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
 
-		$SMSTree['cb1'] = 'Tuesday'
-			$SMSTree['b1'] = 'Sure, I can make it on Tuesday.'
-				$SMSTree['b2'] = ':-) Great! I''ll see you on Tuesday at 18:00 at the Coffee Hole then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
+		$SMSTree['cc1'] = 'Not this week'
+			$SMSTree['c1']  = 'Sorry I don''t have time this week, but next week I should be able too.'
+				$SMSTree['c2'] = ':-( Oh... Okay, yeah I get it. Guess we''ll see you next week.'
+
+		$SMSTree['cd1'] = 'Not interested'
+			$SMSTree['cd2'] = '<font color="red">This ends the D&D Campaign - Forever</font>'
+				$SMSTree['d2'] = 'Sorry, but I''m just not interested in stuff like that. Thanks for the invite though.'
+					$SMSTree['d3'] = ':-( Oh... okay yeah I get it. Guess we''ll see you around.'
 
-		$SMSTree['cc1'] = 'Thursday'
-			$SMSTree['c1'] = 'Sure, I can make it on Thursday.'
-				$SMSTree['c2'] = ':-) Great! I''ll see you on Thursday at 18:00 at the Coffee Hole then! Be ready to get your nerd on, because we''re going to rock it so hard! We also meet for board games on Saturday and Sunday if you want to show up for those.'
 
 	if $ARGS[1] = 'Add SMS':
 		nerd_game['invite_day'] = daystart
@@ -1609,67 +1629,77 @@ if $ARGS[0] = 'summer2_invite_sms':
 			gs 'SMStext_builder', 'add_reply', $SMSTree['ca1'], 'nerd_game_night', 'summer2_invite_sms', 'Choice_a'
 			gs 'SMStext_builder', 'add_reply', $SMSTree['cb1'], 'nerd_game_night', 'summer2_invite_sms', 'Choice_b'
 			gs 'SMStext_builder', 'add_reply', $SMSTree['cc1'], 'nerd_game_night', 'summer2_invite_sms', 'Choice_c'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cd1'], 'nerd_game_night', 'summer2_invite_sms', 'Choice_d'
 
 			gs 'SMStext_builder', 'add_sms', 'A152'
 		gs 'SMStext_builder', 'end'
-
-	elseif $ARGS[1] = 'Choice_a':
+	else
 		!! Add Feofan to the contact list if he isn''t in it yet.
 		!! Is here to add it after reading the text.
 		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
+			gs 'nerd_game_night', 'first_text'
 		end
+	end
+
 
+	if $ARGS[1] = 'Choice_a':
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['a1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+			nerd_game['fixed_uni_day'] = 2
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['a2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
-!!		nerd_game['invite_day'] = 2147483647 & ! block the event
 
 	elseif $ARGS[1] = 'Choice_b':
-		!! Add Feofan to the contact list if he isn''t in it yet.
-		!! Is here to add it after reading the text.
-		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
-		end
-
-		nerd_game['fixed_uni_day'] = 2
-		
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['b1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+			nerd_game['fixed_uni_day'] = 4
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['b2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
 
 	elseif $ARGS[1] = 'Choice_c':
-		!! Add Feofan to the contact list if he isn''t in it yet.
-		!! Is here to add it after reading the text.
-		if nerd_game['first_SMS_received'] = 0:
-			if arrpos('$contact', 'A152') = -1: gs 'telefon', 'AddContact', 'A152', 'images/characters/shared/headshots_main/big152.jpg', 0
-			nerd_game['first_SMS_received'] = 1
-		end
-
-		nerd_game['fixed_uni_day'] = 4
-		
 		gs 'SMStext_builder', 'start'
 			gs 'SMStext_builder', 'send', $SMSTree['c1']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
-			wait 1000
+
+			wait 100
 
 			gs 'SMStext_builder', 'receive', $SMSTree['c2']
 			gs 'SMStext_builder', 'show_sms', ARGS[2]
 		gs 'SMStext_builder', 'end'
+
+		elseif $ARGS[1] = 'Choice_d':
+		gs 'SMStext_builder', 'start'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['ca1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_a'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cb1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_b'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cc1'], 'nerd_game_night', 'summer_invite_sms', 'Choice_c'
+			gs 'SMStext_builder', 'add_reply', $SMSTree['cd2'], 'nerd_game_night', 'summer_invite_sms', 'Choice_d1'
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+		gs 'SMStext_builder', 'end'
+
+	elseif $ARGS[1] = 'Choice_d1':
+		gs 'SMStext_builder', 'start'
+			gs 'SMStext_builder', 'send', $SMSTree['d2']
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+			nerd_game['invite_day'] += 7305		& ! Next campaign in 20 years.
+
+			wait 100
+
+			gs 'SMStext_builder', 'receive', $SMSTree['d3']
+			gs 'SMStext_builder', 'show_sms', ARGS[2]
+		gs 'SMStext_builder', 'end'
 	end
 
+
 	killvar '$SMSTree'
 end
 

+ 4 - 4
locations/stat.qsrc

@@ -263,10 +263,6 @@ end
 ! Execute time based spells
 gs 'spellTimer', prevtotmin, totminut
 
-! Determine Incoming Telephone Calls and SMS
-gs 'telefon', 'IncomingCheck', prevtotmin, totminut
-gs 'telefon', 'IncomingSMSCheck'
-
 !! deodorant
 if deodorant_on = 1 and totminut > deodorant_time: gs 'sweat', 'remove_deo'
 
@@ -435,6 +431,10 @@ end
 
 if hour >= 24: gs 'cikl'
 
+! Determine Incoming Telephone Calls and SMS
+gs 'telefon', 'IncomingCheck', prevtotmin, totminut
+gs 'telefon', 'IncomingSMSCheck'
+
 if minut < 10:
 	$nilmin = '0'
 else