Browse Source

set $home_town variable

lazycodemonkey 6 năm trước cách đây
mục cha
commit
03056dccc8
7 tập tin đã thay đổi với 73 bổ sung18 xóa
  1. 1 0
      glife-notepad++
  2. 1 0
      glife.qproj
  3. 3 0
      locations/Cheatmenu_din
  4. 13 13
      locations/obj_din
  5. 3 5
      locations/preSYS
  6. 6 0
      locations/saveupdater
  7. 46 0
      locations/set_home

+ 1 - 0
glife-notepad++

@@ -648,6 +648,7 @@
 			<File name="locations\Serge_Shulgin" />
 			<File name="locations\SergeiHanter" />
 			<File name="locations\serpent" />
+			<File name="locations\set_home" />
 			<File name="locations\sex" />
 			<File name="locations\sexcontraprio" />
 			<File name="locations\sexdvanadva" />

+ 1 - 0
glife.qproj

@@ -94,6 +94,7 @@
       <Location name="pattest"/>
       <Location name="subkid"/>
       <Location name="_statcheck"/>
+      <Location name="set_home"/>
     </Folder>
     <Folder name="Stimulus">
       <Location name="boyStat"/>

+ 3 - 0
locations/Cheatmenu_din

@@ -1898,6 +1898,9 @@ $cheatmenu['vartracker'] = {
 	pl'$locM: <<$locM>>'
 	pl'<font color = red>$CURLOC: <<$CURLOC>></font>'
 	pl'$location_type: <<$location_type>>'
+	pl'home_cur: <<home_cur>>'
+	pl'$home_town: <<$home_town>>'
+	pl'$home_name: <<$home_name>>'
 	pl'daystart: <<daystart>>'
 	pl'daystart_start: <<daystart_start>>'
 	pl'month: <<month>>'

+ 13 - 13
locations/obj_din

@@ -133,19 +133,19 @@ if $ARGS[0] = 'cur_home':
 	pl' <a href="exec:gs ''obj_din'', ''descrip''">Return to main description</a>'
 	nl
 !!This is correct it just looks wrong
-	if home_owned[1] > 0:pl 'Set current home as <a href="exec:home_cur = 1 & $home_name = ''City residential apartment'' & gs ''obj_din'', ''cur_home''">City residential apartment</a>'
-	if home_owned[2] = 1:pl 'Set current home as <a href="exec:home_cur = 2 & $home_name = ''Parent''''s home in Pavlovsk'' & gs ''obj_din'', ''cur_home''">Parent''s home in Pavlovsk</a>'
-	if home_owned[3] > 0:pl 'Set current home as <a href="exec:home_cur = 3 & $home_name = ''My cottage in the cooperative farm'' & gs ''obj_din'', ''cur_home''">My cottage in the cooperative farm</a>'
-	if home_owned[4] = 1:pl 'Set current home as <a href="exec:home_cur = 4 & $home_name = ''Old town apartment'' & gs ''obj_din'', ''cur_home''">Old town apartment</a>'
-	if home_owned[5] > 2:pl 'Set current home as <a href="exec:home_cur = 5 & $home_name = ''My mansion'' & gs ''obj_din'', ''cur_home''">My mansion</a>'
-	if home_owned[6] = 1:pl 'Set current home as <a href="exec:home_cur = 6 & $home_name = ''My hotel room in Pavlovsk'' & gs ''obj_din'', ''cur_home''">My hotel room in Pavlovsk</a>'
-	if home_owned[7] = 1:pl 'Set current home as <a href="exec:home_cur = 7 & $home_name = ''Tanya''''s house'' & gs ''obj_din'', ''cur_home''">Tanya''s house</a>'
-	if home_owned[8] = 1:pl 'Set current home as <a href="exec:home_cur = 8 & $home_name = ''Niko''''s apartment'' & gs ''obj_din'', ''cur_home''">Niko''s apartment</a>'
-	if home_owned[9] = 1:pl 'Set current home as <a href="exec:home_cur = 9 & $home_name = ''Uncle Sergi''''s apartment'' & gs ''obj_din'', ''cur_home''">Uncle Sergi''s apartment</a>'
-	if home_owned[10] = 1:pl 'Set current home as <a href="exec:home_cur = 10 & $home_name = ''Lyceum school'' & gs ''obj_din'', ''cur_home''">Lyceum school</a>'
-	if home_owned[11] = 1:pl 'Set current home as <a href="exec:home_cur = 11 & $home_name = ''University halls'' & gs ''obj_din'', ''cur_home''">University halls</a>'
-	if home_owned[12] = 1:pl 'Set current home as <a href="exec:home_cur = 12 & $home_name = ''Hunter''''s lodge in Gadukino'' & gs ''obj_din'', ''cur_home''">Hunter''s lodge in Gadukino</a>'
-	if home_owned[13] = 1:pl 'Set current home as <a href="exec:home_cur = 13 & $home_name = ''Shared apartment in Pavlovsk'' & gs ''obj_din'', ''cur_home''">Shared apartment in Pavlovsk</a>'
+	if home_owned[1] > 0:pl 'Set current home as <a href="exec:gs ''set_home'', 1 & gs ''obj_din'', ''cur_home''">City residential apartment</a>'
+	if home_owned[2] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 2 & gs ''obj_din'', ''cur_home''">Parent''s home in Pavlovsk</a>'
+	if home_owned[3] > 0:pl 'Set current home as <a href="exec:gs ''set_home'', 3 & gs ''obj_din'', ''cur_home''">My cottage in the cooperative farm</a>'
+	if home_owned[4] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 4 & gs ''obj_din'', ''cur_home''">Old town apartment</a>'
+	if home_owned[5] > 2:pl 'Set current home as <a href="exec:gs ''set_home'', 5 & gs ''obj_din'', ''cur_home''">My mansion</a>'
+	if home_owned[6] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 6 & gs ''obj_din'', ''cur_home''">My hotel room in Pavlovsk</a>'
+	if home_owned[7] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 7 & gs ''obj_din'', ''cur_home''">Tanya''s house</a>'
+	if home_owned[8] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 8 & gs ''obj_din'', ''cur_home''">Niko''s apartment</a>'
+	if home_owned[9] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 9 & gs ''obj_din'', ''cur_home''">Uncle Sergey''s apartment</a>'
+	if home_owned[10] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 10 & gs ''obj_din'', ''cur_home''">Lyceum school</a>'
+	if home_owned[11] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 11 & gs ''obj_din'', ''cur_home''">University halls</a>'
+	if home_owned[12] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 12 & gs ''obj_din'', ''cur_home''">Hunter''s lodge in Gadukino</a>'
+	if home_owned[13] = 1:pl 'Set current home as <a href="exec:gs ''set_home'', 13 & gs ''obj_din'', ''cur_home''">Shared apartment in Pavlovsk</a>'
 !!Apostrophe colour correction - KS ''''
 end	
 

+ 3 - 5
locations/preSYS

@@ -23,8 +23,7 @@ if $ARGS[0] = 'TGStart':
 	$pcs_dna = func('dna','create')
 
 	home_owned[1] = 1
-	home_cur = 1
-	$home_name = 'City residential apartment'
+	gs 'set_home', 1
 
 	if MagikDostup = 1:
 		gt 'preCUST', 'NTStart'
@@ -119,9 +118,8 @@ if $ARGS[0] = 'SGStart':
 	gs 'npcstatic5'
 
 	home_owned[2] = 1
-	home_cur = 2
-	$home_name = 'Parent''s home in Pavlovsk'
-	
+	gs 'set_home', 2
+
 	'<center><img <<$set_imgh>> src="images/pre/sys/altstart.jpg"></center>'
 	'Your name is <<$pcs_firstname>> <<$pcs_lastname>>, Friends and family sometimes call you <<$pcs_nickname>>. Your mother''s name is <<$npc_firstname[''A29'']>>, and your biological father left before you were born. Your mother married your stepfather, <<$npc_firstname[''A28'']>>, shortly afterwards. <<$npc_firstname[''A33'']>> is your older sister. She is two years older than you and is still living at home while working at the local grocery story. She chose not to attend college and instead spends most of her free time drinking with her friends or going to parties, much to your mother''s dismay. You also have a younger half-brother, <<$npc_firstname[''A34'']>>, who is really into sports, especially football, and is shaping up to be a fine athlete. He is a year younger than you are, and his father is your stepfather.'
 	*nl

+ 6 - 0
locations/saveupdater

@@ -326,5 +326,11 @@ if billiardnav > 0: pool_exp += billiardnav & killvar 'billiardnav' & killvar 'p
 	end
 end
 }
+
+!! set $home_town variable
+if $home_town = '':
+	gs 'set_home', home_cur
+end
+
 --- saveupdater ---------------------------------
 

+ 46 - 0
locations/set_home

@@ -0,0 +1,46 @@
+# set_home
+
+home_cur = ARGS[0]
+if home_cur = 1:
+	$home_name = 'City residential apartment'
+	$home_town = 'city'
+elseif home_cur = 2:
+	$home_name = 'Parent''s home in Pavlovsk'
+	$home_town = 'pavlovsk'
+elseif home_cur = 3:
+	$home_name = 'My cottage in the cooperative farm'
+	$home_town = 'city'
+elseif home_cur = 4:
+	$home_name = 'Old town apartment'
+	$home_town = 'city'
+elseif home_cur = 5:
+	$home_name = 'My mansion'
+	$home_town = 'city'
+elseif home_cur = 6:
+	$home_name = 'My hotel room in Pavlovsk'
+	$home_town = 'pavlovsk'
+elseif home_cur = 7:
+	$home_name = 'Tanya''s house'
+	$home_town = 'city'
+elseif home_cur = 8:
+	$home_name = 'Niko''s apartment'
+	$home_town = 'pavlovsk'
+elseif home_cur = 9:
+	$home_name = 'Uncle Sergey''s apartment'
+	$home_town = 'pavlovsk'
+elseif home_cur = 10:
+	$home_name = 'Lyceum school'
+	$home_town = 'pavlovsk'
+elseif home_cur = 11:
+	$home_name = 'University halls'
+	$home_town = 'city'
+elseif home_cur = 12:
+	$home_name = 'Hunter''s lodge in Gadukino'
+	$home_town = 'gadukino'
+elseif home_cur = 13:
+	$home_name = 'Shared apartment in Pavlovsk'
+	$home_town = 'pavlovsk'
+end
+
+--- set_home ---------------------------------
+