ソースを参照

[changed] Min, Max, and Set links for attributes in the cheat menu

nyanobot 6 年 前
コミット
30e45e8c75
1 ファイル変更35 行追加9 行削除
  1. 35 9
      locations/Cheatmenu_din.qsrc

+ 35 - 9
locations/Cheatmenu_din.qsrc

@@ -643,6 +643,31 @@ $cheatmenu['tatoo'] = {
 	if tathand >= 1:pl'<a href="exec:tattCount-=1 & tathand = 0 & dynamic $cheatmenu[''tatoo'']">Remove your hand tattoo</a>'
 }
 
+$cheatmenu['setStat'] = {
+	temp_input = input("How much <<$ARGS[1]>> do you want to have?")
+	dynamic "
+		<<$ARGS[0]>>_lvl = temp_input
+		<<$ARGS[0]>>_lvlst = temp_input
+	"
+	killvar 'temp_input'
+	dynamic $cheatmenu['stats']
+}
+
+$cheatmenu['setAttrs'] = {
+	loop_index = 0
+	:set_attrs_loop
+		dynamic "
+			<<$att_name[loop_index]>>_lvl = <<ARGS[0]>>
+			<<$att_name[loop_index]>>_lvlst = <<ARGS[0]>>
+		"
+		loop_index += 1
+		! Magic is the last attribute, so if it's a non-magic game we'll end the loop one iteration early
+		if MagikDostup = 0 and loop_index < arrsize('$att_name'): jump 'set_attrs_loop'
+		elseif loop_index < arrsize('$att_name') - 1: jump 'set_attrs_loop'
+		end
+	dynamic $cheatmenu['stats']
+}
+
 $cheatmenu['stats'] = {
 	gs 'stat'
 	clr
@@ -673,15 +698,16 @@ $cheatmenu['stats'] = {
 
 	pl'<center><a href="exec:dynamic $cheatmenu"><b>Cheat menu</b></a></center>'
 	nl
-	pl 'Strength (<<stren_lvl>>): <a href="exec:stren_lvl += 1 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:stren_lvl += 5 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:stren_lvl += 10 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:stren_lvl -= 1 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:stren_lvl -= 5 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:stren_lvl -= 10 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Agility (<<agil_lvl>>): <a href="exec:agil_lvl += 1 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:agil_lvl += 5 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:agil_lvl += 10 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:agil_lvl -= 1 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:agil_lvl -= 5 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:agil_lvl -= 10 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Endurance (<<vital_lvl>>): <a href="exec:vital_lvl += 1 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:vital_lvl += 5 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:vital_lvl += 10 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:vital_lvl -= 1 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:vital_lvl -= 5 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:vital_lvl -= 10 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Intelligence (<<intel_lvl>>): <a href="exec:intel_lvl += 1 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:intel_lvl += 5 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:intel_lvl += 10 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:intel_lvl -= 1 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:intel_lvl -= 5 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:intel_lvl -= 10 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Mental Agility (<<react_lvl>>): <a href="exec:react_lvl += 1 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:react_lvl += 5 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:react_lvl += 10 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:react_lvl -= 1 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:react_lvl -= 5 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:react_lvl -= 10 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Sprit (<<sprt_lvl>>): <a href="exec:sprt_lvl += 1 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:sprt_lvl += 5 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:sprt_lvl += 10 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:sprt_lvl -= 1 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:sprt_lvl -= 5 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:sprt_lvl -= 10 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Charisma (<<chrsm_lvl>>): <a href="exec:chrsm_lvl += 1 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:chrsm_lvl += 5 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:chrsm_lvl += 10 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:chrsm_lvl -= 1 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:chrsm_lvl -= 5 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:chrsm_lvl -= 10 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	pl 'Perception (<<prcptn_lvl>>): <a href="exec:prcptn_lvl += 1 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:prcptn_lvl += 5 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:prcptn_lvl += 10 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:prcptn_lvl -= 1 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:prcptn_lvl -= 5 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:prcptn_lvl -= 10 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
-	if MagikDostup = 0: pl 'Magic (<<magik_lvl>>): <a href="exec:magik_lvl += 1 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:magik_lvl += 5 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:magik_lvl += 10 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:magik_lvl -= 1 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:magik_lvl -= 5 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:magik_lvl -= 10 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'
+	pl '<a href="exec:dynamic $cheatmenu[''setAttrs''], 0" >Min Stats</a>    <a href="exec:dynamic $cheatmenu[''setAttrs''], 100" >Max Stats</a>'
+	pl 'Strength (<<stren_lvl>>): <a href="exec:stren_lvl = 0 & stren_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:stren_lvl += 1 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:stren_lvl += 10 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:stren_lvl -= 1 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:stren_lvl -= 10 & stren_lvlst = stren_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:stren_lvl = 100 & stren_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''stren'', ''Strength''" >Set</a>'
+	pl 'Agility (<<agil_lvl>>): <a href="exec:agil_lvl = 0 & agil_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:agil_lvl += 1 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:agil_lvl += 10 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:agil_lvl -= 1 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:agil_lvl -= 10 & agil_lvlst = agil_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:agil_lvl = 100 & agil_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''agil'', ''Agility''" >Set</a>'
+	pl 'Endurance (<<vital_lvl>>): <a href="exec:vital_lvl = 0 & vital_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:vital_lvl += 1 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:vital_lvl += 10 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:vital_lvl -= 1 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:vital_lvl -= 10 & vital_lvlst = vital_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:vital_lvl = 100 & vital_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''vital'', ''Endurance''" >Set</a>'
+	pl 'Intelligence (<<intel_lvl>>): <a href="exec:intel_lvl = 0 & intel_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:intel_lvl += 1 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:intel_lvl += 10 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:intel_lvl -= 1 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:intel_lvl -= 10 & intel_lvlst = intel_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:intel_lvl = 100 & intel_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''intel'', ''Intelligence''" >Set</a>'
+	pl 'Mental Agility (<<react_lvl>>): <a href="exec:react_lvl = 0 & react_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:react_lvl += 1 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:react_lvl += 10 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:react_lvl -= 1 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:react_lvl -= 10 & react_lvlst = react_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:react_lvl = 100 & react_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''react'', ''Mental Agility''" >Set</a>'
+	pl 'Spirit (<<sprt_lvl>>): <a href="exec:sprt_lvl = 0 & sprt_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:sprt_lvl += 1 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:sprt_lvl += 10 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:sprt_lvl -= 1 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:sprt_lvl -= 10 & sprt_lvlst = sprt_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:sprt_lvl = 100 & sprt_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''sprt'', ''Spirit''" >Set</a>'
+	pl 'Charisma (<<chrsm_lvl>>): <a href="exec:chrsm_lvl = 0 & chrsm_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:chrsm_lvl += 1 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:chrsm_lvl += 10 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:chrsm_lvl -= 1 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:chrsm_lvl -= 10 & chrsm_lvlst = chrsm_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:chrsm_lvl = 100 & chrsm_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''chrsm'', ''Charisma''" >Set</a>'
+	pl 'Perception (<<prcptn_lvl>>): <a href="exec:prcptn_lvl = 0 & prcptn_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:prcptn_lvl += 1 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:prcptn_lvl += 10 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:prcptn_lvl -= 1 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:prcptn_lvl -= 10 & prcptn_lvlst = prcptn_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:prcptn_lvl = 100 & prcptn_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''prcptn'', ''Perception''" >Set</a>'
+	if MagikDostup = 0: pl 'Magic (<<magik_lvl>>): <a href="exec:magik_lvl = 0 & magik_lvlst = 0 & dynamic $cheatmenu[''stats'']" >Min</a>  <a href="exec:magik_lvl += 1 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:magik_lvl += 10 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:magik_lvl -= 1 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:magik_lvl -= 10 & magik_lvlst = magik_lvl & dynamic $cheatmenu[''stats'']" >-10</a>  <a href="exec:magik_lvl = 100 & magik_lvlst = 100 &dynamic $cheatmenu[''stats'']" >Max</a>  <a href="exec:dynamic $cheatmenu[''setStat''], ''magik'', ''Magic''" >Set/a>'
 	nl
 	pl'<b>Sexual:</b>'
 	pl 'Inhibition level (<<100 - pcs_inhib>>): <a href="exec:inhib_lvl -= 1 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >+1</a> <a href="exec:inhib_lvl -= 5 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >+5</a> <a href="exec:inhib_lvl -= 10 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >+10</a> <a href="exec:inhib_lvl += 1 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >-1</a> <a href="exec:inhib_lvl += 5 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >-5</a> <a href="exec:inhib_lvl += 10 & inhib_lvlst = inhib_lvl & dynamic $cheatmenu[''stats'']" >-10</a>'