# themes

!night_mode 0: dynamic
!night_mode 1: black
!night_mode 2: grey
!night_mode 3: white
!night_mode 99: no theme (may break tables)

!outdoor theme 0 is dynamic, and changes colour with time of day.
if $ARGS[0] = 'outdoors':
    if night_mode = 0:
        if (DayStage = 1) or (DayStage = 6) :
            bcolor = rgb(210, 210, 255)
            ! fcolor
            lcolor = rgb(40, 40, 255)

            $bcolor = '"#D2D2FF"'
        elseif (DayStage = 3):
            bcolor = rgb(226, 169, 169)
            ! fcolor
            lcolor = rgb(56, 90, 205)

            $bcolor = '"#E2A9A9"'
        elseif (DayStage = 4) :
            bcolor = rgb(BColorBase, BColorBase-BColorBase/4, BColorBase-BColorBase/4)
            ! fcolor
            lcolor = rgb(110, 200, 200)

            $bcolor = func('shortgs', 'int_to_hex_str', BColorBase-BColorBase/4)
            $bcolor = '"#' + func('shortgs', 'int_to_hex_str', BColorBase) + $bcolor + $bcolor + '"'
        else
            bcolor = rgb(BColorBase, BColorBase, BColorBase)
            ! fcolor
            lcolor = rgb(106, 90, 205)

            $bcolor = func('shortgs', 'int_to_hex_str', BColorBase)
            $bcolor = '"#' + $bcolor + $bcolor + $bcolor + '"'
        end

		if BColorBase <= 160:
			fcolor = rgb(255, 255, 255)
		else
			fcolor = rgb(0, 0, 0)
		end
	elseif night_mode = 1:
		!! hornguy6''s new colors ----------------
		fcolor = rgb(255, 255, 255)
		bcolor = rgb(0, 0, 0)
		lcolor = rgb(90, 180, 200)
		!! hornguy6''s new colors ----------------
		
		
		!!{ original ----------------
			fcolor = rgb(255, 255, 255)
			bcolor = rgb(0, 0, 0)
			lcolor = rgb(106, 90, 205)
		!! original ----------------}

		$bcolor = '"#000000"'
	elseif night_mode = 2:
		!! hornguy6''s new colors ----------------
		fcolor = rgb(255, 255, 255)
		bcolor = rgb(20, 20, 20)
		lcolor = rgb(90, 180, 200)
		!! hornguy6''s new colors ----------------
		!!{ original ----------------
			fcolor = rgb(255, 255, 255)
			bcolor = rgb(20, 20, 20)
			lcolor = rgb(106, 90, 205)
		!! original ----------------}

		$bcolor = '"#141414"'
	elseif night_mode = 3:
		bcolor = rgb(255, 255, 255)
		lcolor = rgb(106, 90, 205)
		fcolor = rgb(0, 0, 0)

		$bcolor = '"#FFFFFF"'
	elseif night_mode = 99:
		killvar 'fcolor'
		killvar 'bcolor'
		killvar 'lcolor'

		killvar '$bcolor'
	end
end

!indoor themes are static.
if $ARGS[0] = 'indoors':
	if night_mode = 0:
		fcolor = rgb(0, 0, 0)
		bcolor = rgb(255, 255, 255)
		lcolor = rgb(106, 90, 205)

		$bcolor = '"#FFFFFF"'
	elseif night_mode = 1:
		fcolor = rgb(255, 255, 255)
		bcolor = rgb(0, 0, 0)
		!! hornguy6''s new colors ----------------
		lcolor = rgb(90, 180, 200)
		!! hornguy6''s new colors ----------------
		
		!!{ original ----------------
			lcolor = rgb(106, 90, 205)
		!! original ----------------}

		$bcolor = '"#000000"'
	elseif night_mode = 2:
		fcolor = rgb(255, 255, 255)
		bcolor = rgb(20, 20, 20)
		!! hornguy6''s new colors ----------------
		lcolor = rgb(90, 180, 200)
		!! hornguy6''s new colors ----------------
		
		!!{ original ----------------
			lcolor = rgb(106, 90, 205)
		!! original ----------------}
	
		$bcolor = '"#141414"'
	elseif night_mode = 99:
		killvar 'fcolor'
		killvar 'bcolor'
		killvar 'lcolor'

		killvar '$bcolor'
	end
	gs 'indoors'
end

!food_menu themes are only for menu table backgrounds.
if $ARGS[0] = 'food_menu':
	if night_mode = 0:
		$fcolor1 = '#000000'
		$bcolor1 = '#FFFFFF'
		$bcolor2 = '#e6f2ff'
		$bcolor3 = '#FFFFFF'
	elseif night_mode = 1:
		$fcolor1 = '#FFFFFF'
		$bcolor1 = '#202020'
		$bcolor2 = '#303030'
		$bcolor3 = '#000000'
	elseif night_mode = 2:
		$fcolor1 = '#FFFFFF'
		$bcolor1 = '#202020'
		$bcolor2 = '#303030'
		$bcolor3 = '#141414'
	elseif night_mode = 99:
		$fcolor1 = '#000000'
		$bcolor1 = '#bbbbbb'
		$bcolor2 = '#dddddd'
		$bcolor3 = '#FFFFFF'
	end
end

!clothing th themes are for table backgrounds. 1 is first colour, 2 is second colour.
!eg gs 'themes', 'clothing', 1
if $ARGS[0] = 'clothing':
	if ARGS[1] = 1:
		if night_mode = 0:
			$bgcolor = iif($bgcolor='#f3f4ee','#ffffff','#f3f4ee')
		elseif night_mode = 1:
			$bgcolor = iif($bgcolor='#0C0B11','#000000','#0C0B11')
		elseif night_mode = 2:
			$bgcolor = iif($bgcolor='#0C0B11','#141414','#0C0B11')
		elseif night_mode = 99:
			killvar 'bgcolor'
		end
	elseif ARGS[1] = 2:
		if night_mode = 0:
			$bgcolor = iif($bgcolor='#f3f4ee','#ffffff','#f3f4ee')
		elseif night_mode = 1:
			$bgcolor = iif($bgcolor='#0C0B11','#000000','#0C0B11')
		elseif night_mode = 2:
			$bgcolor = iif($bgcolor='#0C0B11','#202020','#0C0B11')
		elseif night_mode = 99:
			killvar '$bgcolor'
		end
	end
end


if $ARGS[0] = 'alt_color':
	if night_mode = 0:
		if $bcolor ! '"#FFFFFF"' and BColorBase <= 160:
			$result = iif($ARGS[1]='#202020','#000000','#202020')
		else
			$result = iif($ARGS[1]='#e6f2ff','#ffffff','#e6f2ff')
		end
	elseif night_mode = 1:
		$result = iif($ARGS[1]='#202020','#000000','#202020')
	elseif night_mode = 2:
		$result = iif($ARGS[1]='#303030','#141414','#303030')
	elseif night_mode = 3:
		$result = iif($ARGS[1]='#e6f2ff','#ffffff','#e6f2ff')
	end
end

--- themes ---------------------------------

