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

[changed] edited 'shop_tsar_bomba' to use the generalized display loops

f95Lok пре 1 месец
родитељ
комит
f60f3cf2bd
1 измењених фајлова са 10 додато и 140 уклоњено
  1. 10 140
      locations/shop_tsar_bomba.qsrc

+ 10 - 140
locations/shop_tsar_bomba.qsrc

@@ -32,46 +32,9 @@ if $ARGS[0] = 'dresses':
 	'<center><b><font color="maroon">Viewing Tsar Bomba dresses</font></b></center>'
 	*nl
 
-	if intro_custom_shop_return = 1:
-		act 'Return': gt 'intro_customization', 'modclo'
-		step = intro_custom_step
-	else
-		act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
-		step = 2
-	end
-
-	gs 'clothing_QV', 'shop_filter_header'
-	gs 'clothing', 'totals', 'bomba_dresses'
-	
-	!!To filter just this set
-	clo_i = 0
-	:loopbomba_dresses_filter
-		i = 1 + Clothingstock mod 2
-		:loopbomba_dresses
-			if bomba_dress[i] = 0:
-				gs 'clothing_attributes', 'bomba_dress', i
-				gs 'clothing_QV', 'shop_filter'
-
-				!!sort by filter
-				if (clothingfilter['quality'] = 0 and CloQuality = clo_i) or (clothingfilter['inhibition'] = 0 and CloInhibit = clo_i) or clothingfilter['number'] = 0:
-					if clothingfilter['inc'] = 1 and clothingfilter['only'] = 1: *p '<a href="exec: i = <<i>> & gt ''shop_tsar_bomba'', ''bomba_dresses''"><img src="images/pc/items/bomba/dress/<<i>>.jpg"	 height="250" /></a>'
-				end
-			end
-			i += step
-		if i <= total: jump 'loopbomba_dresses'
-		clo_i += 1
-	if clothingfilter['quality'] = 0 and clo_i <= 7 or clothingfilter['inhibition'] = 0 and clo_i <= 50:
-		jump 'loopbomba_dresses_filter'
-	end
-end
+	gt 'shop_utils', 'display_clothes', 'bomba_dress', 2, 'bomba/dress', 'shop', Clothingstock mod 2
 
-if $ARGS[0] = 'bomba_dresses':
-	if bomba_dress[i] ! 0:
-		msg 'You already own these clothes.'
-		gt 'shop_tsar_bomba', 'clothes'
-	end
-
-	gt 'clothing', 'view_clothing_item', 'bomba_dress', i, 3500, 'shop'
+	act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
 end
 
 if $ARGS[0] = 'clothes':
@@ -82,46 +45,9 @@ if $ARGS[0] = 'clothes':
 	'<center><b><font color="maroon">Viewing Tsar Bomba outfits</font></b></center>'
 	*nl
 
-	if intro_custom_shop_return = 1:
-		act 'Return': gt 'intro_customization', 'modclo'
-		step = intro_custom_step
-	else
-		act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
-		step = 2
-	end
-
-	gs 'clothing_QV', 'shop_filter_header'
-	gs 'clothing', 'totals', 'bomba_outfits'
+	gt 'shop_utils', 'display_clothes', 'bomba_outfits', 2, 'bomba/outfits', 'shop', (Clothingstock / 2) mod 2
 	
-	!!To filter just this set
-	clo_i = 0
-	:loopbomba_filter
-		i = 1 + (Clothingstock / 2) mod 2
-		:loopbomba
-			if bomba_outfits[i] = 0:
-				gs 'clothing_attributes', 'bomba_outfits', i
-				gs 'clothing_QV', 'shop_filter'
-
-				!!sort by filter
-				if (clothingfilter['quality'] = 0 and CloQuality = clo_i) or (clothingfilter['inhibition'] = 0 and CloInhibit = clo_i) or clothingfilter['number'] = 0:
-					if clothingfilter['inc'] = 1 and clothingfilter['only'] = 1: *p '<a href="exec: i = <<i>> & gt ''shop_tsar_bomba'', ''bomba_outfits''"><img src="images/pc/items/bomba/outfits/<<i>>.jpg"	 height="250" /></a>'
-				end
-			end
-			i += step
-		if i <= total: jump 'loopbomba'
-		clo_i += 1
-	if clothingfilter['quality'] = 0 and clo_i <= 7 or clothingfilter['inhibition'] = 0 and clo_i <= 50:
-		jump 'loopbomba_filter'
-	end
-end
-
-if $ARGS[0] = 'bomba_outfits':
-	if bomba_outfits[i] ! 0:
-		msg 'You already own these clothes.'
-		gt 'shop_tsar_bomba', 'clothes'
-	end
-
-	gt 'clothing', 'view_clothing_item', 'bomba_outfits', i, 3500, 'shop'
+	act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
 end
 
 if $ARGS[0] = 'purses':
@@ -129,25 +55,11 @@ if $ARGS[0] = 'purses':
 	menu_off = 0
 	gs 'stat'
 
-	if intro_custom_shop_return = 1:
-		act 'Return': gt 'intro_customization', 'modclo'
-		step = intro_custom_step
-	else
-		act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
-		step = 1
-	end
+	gt 'shop_utils', 'display_purses', 'bomba', 1, 'bomba/purses', 'shop'
 
-	gs 'purses', 'totals', 'bomba_purses'
-	
-	i = 1
-	:loopbomba_purses
-		if bomba_purses[i] = 0: *p '<a href="exec: i = <<i>> & gt ''shop_tsar_bomba'', ''purses2''"><img src="images/pc/items/bomba/purses/<<i>>.jpg"	 height="250" /></a> '
-		i += step
-	if i <= total: jump 'loopbomba_purses'
+	act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
 end
 
-if $ARGS[0] = 'purses2': gt 'purses', 'view_purse_item', 'shop', 'bomba', i, 2000
-
 if $ARGS[0] = 'shoes':
 	gs 'shortgs', 'setloc', 'shop_tsar_bomba', 'shoes'
 	menu_off = 0
@@ -156,62 +68,20 @@ if $ARGS[0] = 'shoes':
 	'<center><b><font color="maroon">Viewing G&M shoes</font></b></center>'
 	*nl
 
-	if intro_custom_shop_return = 1:
-		act 'Return': gt 'intro_customization', 'modclo'
-		step = intro_custom_step
-	else
-		act 'Return': minut += 5 & gt 'shop_tsar_bomba', 'start'
-		step = 1
-	end
+	gt 'shop_utils', 'display_shoes', 'bomba', 1, 'bomba/shoes', 'shop'
 
-	gs 'shoes', 'shop_filter_header'
-	gs 'shoes', 'totals', 'bomba_shoes'
-	
-	!!To filter just this set
-	clo_i = 0
-	:loopshoequality_filter
-		i = 1
-		:loopbomba_shoes
-			if bomba_shoe[i] = 0:
-				gs 'shoe_attributes', 'bomba', i
-				gs 'shoes', 'shoe_filter'
-				if (Shofilter['quality'] = 0 and ShoQuality = clo_i) or Shofilter['number'] = 0:
-					if Shofilter['inc'] = 1 and Shofilter['only'] = 1: *p '<a href="exec: i = <<i>> & gt ''shop_tsar_bomba'', ''bomba_shoes''"><img src="images/pc/items/bomba/shoes/<<i>>.jpg" height="250" /></a>'
-				end
-			end
-			i += step
-		if i <= total: jump 'loopbomba_shoes'
-		clo_i += 1
-	if Shofilter['quality'] = 0 and clo_i <= 7:
-		jump 'loopshoequality_filter'
-	end
+	act 'Return': minut += 5 & gt 'shop_tsar_bomba', 'start'
 end
 
-if $ARGS[0] = 'bomba_shoes': gt 'shoes', 'view_shoe_item', 'shop', 'bomba', i, 2000
-
 if $ARGS[0] = 'coats':
 	gs 'shortgs', 'setloc', 'shop_tsar_bomba', 'coats'
 	menu_off = 0
 	gs 'stat'
 
-	if intro_custom_shop_return = 1:
-		act 'Return': gt 'intro_customization', 'modclo'
-		step = intro_custom_step
-	else
-		act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
-		step = 1
-	end
+	gt 'shop_utils', 'display_coats', 'bomba', 1, 'bomba/coats', 'shop'
 
-	gs 'coats', 'totals', 'bomba_coats'
-	
-	i = 1
-	:loopbomba_coats
-		if bomba_coats[i] = 0: *p '<a href="exec: i = <<i>> & gt ''shop_tsar_bomba'', ''coats2''"><img src="images/pc/items/bomba/coats/<<i>>.jpg"	 height="250" /></a> '
-		i += step
-	if i <= total: jump 'loopbomba_coats'
+	act 'Return': minut += 1 & gt 'shop_tsar_bomba', 'start'
 end
 
-if $ARGS[0] = 'coats2': gt 'coats', 'view_coat_item', 'shop', 'bomba', i, 2000
-
 --- shop_tsar_bomba ---------------------------------