# initg

if $ARGS[0] = '':
	$initext = $USER_TEXT
	CMDCLEAR
	SHOWINPUT 0
	*clr
	:initg_loop
	$t = MID($initext,0,STRPOS($initext, '\n')-1)
	$inittext[] = $t
	$t
	dynamic $t
	$initext = MID($initext,STRPOS($initext, '\n')+1, len($initext))
	if STRPOS($initext, '\n') < 4 : $initext = MID($initext,STRPOS($initext, '\n')+1, len($initext))
	if STRPOS($initext, '\r') < 4 : $initext = MID($initext,STRPOS($initext, '\r')+1, len($initext))
	if STRPOS($initext, '\n') > 0 : jump 'initg_loop'
	$t = $initext
	$inittext[] = $t
	$t
	dynamic $t
	killvar '$t'
	gs 'stat'
	dynamic $cheatmenu['setting']
end

if $ARGS[0] = 'get_game_set':
	*clr & cla
	'As there is no other way to preserve your favorite settings, you have to do it in the following way:'
	*nl 'All the game environment variable will be written on the main window in the next step, and you have to copy paste them via the clipboard into a text file, so you could restore it in your next game.'
	act 'Continue' :
		*clr & cla
		'Enable_nogameover = <<Enable_nogameover>>'
		'music_on = <<music_on>>'
		'music_loop = <<music_loop>>'
		'disable_autosave = <<disable_autosave>>'
		'autohairbrush = <<autohairbrush>>'
		'enfullmorrout = <<enfullmorrout>>'
		'cyccustom = <<cyccustom>>'
		'cheatKlisma = <<cheatKlisma>>'
		'editpornname = <<editpornname>>'
		'difficulty = <<difficulty>>'

		'usePopUps = <<usePopUps>>'
		'set_imgw = <<set_imgw>>'
		'set_imgh = <<set_imgh>>'
		'$set_imgh = "<<$set_imgh>>"'
		'Enable_tablemap = <<Enable_tablemap>>'
		'Enable_faceturn = <<Enable_faceturn>>'
		'Enable_Android = <<Enable_Android>>'

		'disable_LoadSave = <<disable_LoadSave>>'
		'TempUnit = <<TempUnit>>'
		'default_wbanner = <<default_wbanner>>'
		'set_weatherht = <<set_weatherht>>'
		'default_menu_icons = <<default_menu_icons>>'
		'set_miconht = <<set_miconht>>'
		'cheatStatusIcons = <<cheatStatusIcons>>'
		'disable_show_icons = <<disable_show_icons>>'
		'set_siconht = <<set_siconht>>'
		'ETOmenu = <<ETOmenu>>'
		'Enable_scalepic = <<Enable_scalepic>>'
		'Enable_scalewidth = <<Enable_scalewidth>>'
		'Enable_scaleheight = <<Enable_scaleheight>>'
		'Enable_statfsize = <<Enable_statfsize>>'
		'Enable_showattr = <<Enable_showattr>>'
		'Enable_showskill = <<Enable_showskill>>'
		'Enable_showrelation = <<Enable_showrelation>>'
		'Enable_showstatimg = <<Enable_showstatimg>>'
		'Enable_statimg_loc = <<Enable_statimg_loc>>'
		'set_statimgh = <<set_statimgh>>'
		'set_statimgw = <<set_statimgw>>'

		act 'Finish': dynamic $cheatmenu['setting']
	end
end

if $ARGS[0] = 'set_game_set':
	*clr & cla
	'In the next step, it will be opened the input window where you can copy your saved state of the game environment variables. Both Windows (cr lf) and Unix (lf) end of line is supported, although the second one will not be properly formatted on the screen.'

	act 'Continue' :
		cla
		$USERCOM = 'initg'
		SHOWINPUT 1
		*nl 'Now you can input your data and press <b>Enter</b>'
	end
end

--- initg ---------------------------------

