

// !important: SetFogDensity() in ACS doesn't seem to work without the fogdensity line here!
// P.S. SetFogDensity() in Zandronum works exactly once per map and also ignores the sector tag passed to it. I.e. it sets fog density for the map globally.

// Note on map names: as I began creating the Russian localization, I realized that constructs like 'lookup "Nuclear Power Plant"', used by Mark-sensei in advance, were invalid. The string ID cannot contain spaces and you cannot use arbitrary strings as keys for ease of use. You have to create a solid ID for EVERY string and move it to the LANGUAGE lump for it to be translateable.

//***Che This file overwrite s FBD's 
// when composing the chebskies-EDAY-2.pk3 from source layers

// NOTE #1: ALL MUSIC TRACKS are described in the LANGUAGE lump of Chebskies2Music.wad
//  because music handling was automated and track names virtualized
//  for greater moddability!

// NOTE #2: "next" and "secretnext" are left for reference only
//  because *map transition is controlled through map scripts*, 
//  with the next map hardcoded there.
// Reason: to override Zandronum server's map rotation list and make the map progression work in coop

clearepisodes // because the Hordes skills would not work with Hell on Earth!


episode EDAY01
{
	//optional
	name = "$CHE_EDAY_NAME" //"Extermination Day"
	key = m
}

/*
episode EDAY01
{
	//picname = "EDAY_EP1"
	name = "$CHE_EDAY_EP1" // Hell on Mars
	key = m
}
*/

episode EDAY11
{
	//picname = "EDAY_EP2"
	name = "$CHE_EDAY_EP2" // Battle of Los Angeles
	key = e
}

episode EDAY22
{
	//picname = "EDAY_EP3"
	name = "$CHE_EDAY_EP3" // Within Unholy Territory
	key = h
}

episode MAP1KIMP
{
	name = "FBD 1000imps test map"
	key = "i"
}

/* will be ready in September
episode "chek01"
{
   name = "$CHEK_CAMPTIT" //"ChebMaster's Challenge"
   key = "z"
}
*/

gameinfo
{
	// not virtualizable, title music is set from TITLEMAP
	titlemusic = ""
    titletime = 8
	CreditPage = "CREDIT1", "CREDIT2", "CREDIT3"
}

map TITLEMAP "Titlemap"
{
	sky1 = "SUNRISE2" // in EDAY textures
	music = ""
	Intermusic = ""
}

map EDAY01 lookup CHE01_MAPNAME //"Hangar"
{
	//titlepatch "CWILV00"
	next = "EDAY02"
	secretnext = "EDAY02"
	
	//sky1 = "TSKY1", 0.1
	sky1 = "KYSRM", 0.1
	// KYSRM is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	// I fought long and hard to preserve it as it was, but TSKY1, while great in some places,
	// was absolutely NOT WORKING in other places (because it wraps creating an impression 
	// of a dark plain under that sky). Doom sky format being too quirky,
	// I cut this Gordian knot by making it into a cubemap. With haze below horizon
	// matching fog color, AND fake pixellation effect from low-res source,
	// both baked in.
	
	//cluster = 1
	//par = 60
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	ExitPic = "INTER1"
	Gravity = 500
	Par = 540
	LevelNum = 1
	lightmode = 3 // "Dark", as was designed and fine-tuned
}


map EDAY02 lookup CHE02_MAPNAME //"Nukage Processing"
{
	//titlepatch "CWILV01"
	next = "EDAY03"
	secretnext = "EDAY45"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 1
	//par = 90
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 780
	LevelNum = 2
	lightmode = 3 // "Dark"
}


map EDAY45 lookup CHE45_MAPNAME //"Water Treatment"
{
	next = "EDAY03"
	secretnext = "EDAY03"
	sky1 = "KYSRM", 0.1
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	LevelNum = 45
	lightmode = 3 // "Dark"
}


map EDAY03 lookup CHE03_MAPNAME //"Communications Center"
{
	//titlepatch "CWILV02"
	next = "EDAY04"
	secretnext = "EDAY04"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 1
	//par = 120
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	CheckSwitchRange
	Par = 780
	LevelNum = 3
	lightmode = 3 // "Dark"
}


map EDAY04 lookup CHE04_MAPNAME //"Life Support Facility"
{
	//titlepatch "CWILV03"
	next = "EDAY05"
	secretnext = "EDAY05"// wtf, d00d ? "EDAY06"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 1
	//par = 120
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 840
	LevelNum = 4
	lightmode = 3 // "Dark"
}


map EDAY05 lookup CHE05_MAPNAME //"Marine HQ"
{
	//titlepatch "CWILV04"
	next = "EDAY061"
	secretnext = "EDAY061"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 1
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 900
	LevelNum = 5
	lightmode = 3 // "Dark"
}

//***Che I split map 06 in half, now 061 and 062

map EDAY061 lookup CHE061_MAPNAME //"Nuclear Power Plant"
{
	//titlepatch "CWILV05"
	next = "EDAY062"
	secretnext = "EDAY44"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 2
	//par = 150
	//sucktime 1
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 1140
	LevelNum = 61
	lightmode = 3 // "Dark"
}



map EDAY44 lookup CHE44_MAPNAME //"Mutagenic waste tunnels"
{
	//titlepatch "CWILV05"
	next = "EDAY062"
	secretnext = "EDAY062"
	
	UsePlayerStartZ
	// because the players must start on top of the fancy 3d floor, not inside it
	
	sky1 = "KYSRM", 0.1
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	LevelNum = 44
	lightmode = 3 // "Dark"
}

map EDAY062 lookup CHE062_MAPNAME //"Brothers in arms no more"
{
	//titlepatch "CWILV05"
	next = "EDAY07"
	secretnext = "EDAY07"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	//cluster = 2
	//par = 150
	//sucktime 1
	music = ""
	Intermusic = ""
	ExitPic = "INTER1"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 240
	LevelNum = 62
	lightmode = 3 // "Dark"
}

// stub map (one room and two teleporters) for those trying to get there via console commands:
map EDAY06 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY061"
	secretnext = "EDAY062"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	Par = 30
	LevelNum = 6
}
// stub map (one room and one teleporter) for those trying to get there via console commands:
map EDAY49 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY062"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	Par = 30
	LevelNum = 49
}


map EDAY07 lookup CHE07_MAPNAME //"Staging Area"
{
	//titlepatch "CWILV06"
	next = "EDAY08"
	secretnext = "EDAY08"
	sky1 = "KYSRM", 0.1 //TSKY1", 0.1
	// This map had a 3d skybox with scrolling ceiling, I deactivated it without deleting it
	//cluster = 2
	//par = 120
	//Map07special replaced with ACS script
	music = ""
	Intermusic = ""
	ExitPic = "INTER4"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 840
	LevelNum = 7
	lightmode = 3 // "Dark"
}

map EDAY08 lookup CHE08_MAPNAME //"Lab Complex Entrance"
{
	//titlepatch "CWILV07"
	next = "EDAY09"
	secretnext = "EDAY09"
	//sky1 = "TSKY1", 0.1
	// This map does not actually have any sky, all indoors
	//cluster = 2
	//par = 120
	music = ""
	Intermusic = ""
	ExitPic = "INTER4"
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 840
	LevelNum = 8
	lightmode = 3 // "Dark"
}

map EDAY09 lookup CHE09_MAPNAME //"Bio Labs"
{
	//titlepatch "CWILV08"
	next = "EDAY10"
	secretnext = "EDAY10"
	//sky1 = "TSKY1", 0.1
	// No sky, all indoors
	ExitPic = "INTER4"
	//cluster = 2
	//par = 270
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 840
	LevelNum = 9
	lightmode = 3 // "Dark"
}


map EDAY10 lookup CHE10_MAPNAME // "Portal Testing Labs"
{
	//titlepatch "CWILV09"
	next = "EDAY11"
	secretnext = "EDAY11"
	//sky1 = "TSKY1", 0.1
	sky1 = "SKYHELF" // burning hell sky, only seen through a portal sfx
	//cluster = 3
	//par 90

	ExitPic = "INTER_H1" // from HESP, 320x200	
	music = ""
	Intermusic = ""
	
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Gravity = 500
	Par = 840
	LevelNum = 10
	lightmode = 3 // "Dark"
}

// New skies: sun ries in the east over Sierra Nevada, the burning LA is to the south. Player is questing south.

map EDAY11 lookup CHE11_MAPNAME //"The Air Base"
{
	//titlepatch "CWILV10"
	next = "EDAY12"
	secretnext = "EDAY12"

	// KYSR1 is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	sky1 = "KYSR1"
	//sky1="SUNRISE9"
	//cluster = 4
	//par = 210
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 600
	LevelNum = 11
	lightmode = 3 // "Dark"
}

map EDAY12 lookup CHE12_MAPNAME //Quiet. Too quiet.//"Return to Earth"
{
	//titlepatch "CWILV10"
	next = "EDAY13"
	secretnext = "EDAY13"
	//sky1 = "SUNRISE9"

	// KYSR2 is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	sky1 = "KYSR2"
	//cluster = 4
	//par = 210
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 900
	LevelNum = 12
	lightmode = 3 // "Dark"
}


map EDAY13 lookup CHE13_MAPNAME // "Dead Cargo"
{
	//titlepatch "CWILV12"
	next = "EDAY13I"
	secretnext = "EDAY46"
	//sky1 = "SKY2YELO", 0.1
	//cluster = 4
	//par = 150
	//ExitPic = "INTER2"
	ExitPic="TITKY13" // screenshot of your locomotive about to crush a pinky
	//music = EDMU13
	//sky1 = "DESERT1"

	// KYSR3 is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	// the burning city is baked in
	sky1 = "KYSR3"

	music = ""
	Intermusic = ""

	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1680
	LevelNum = 13
	lightmode = 3 // "Dark"
}

map EDAY46 lookup CHE46_MAPNAME // "Mock Town"
{
	next = "EDAY13I"
	secretnext = "EDAY13I"
	ExitPic="INTER7" // essential for a golden ending completed
	// KYSR3 is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	// the burning city is baked in
	sky1 = "KYSR3"
	
	music = ""
	Intermusic = ""

	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	//Par = 
	LevelNum = 46
	lightmode = 3 // "Dark"
}

map EDAY13I lookup CHE13_INTERNAME // "Better than a chainsaw!"
{
	next = "EDAY14"
	secretnext = "EDAY14"
	// exit pic is not used because cutscene maps skip intermission screen now
	ExitPic="TITKY13" // screenshot of your locomotive about to crush a pinky
	sky1 = "KYSR3"

	music = ""
	Intermusic = ""

	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	lightmode = 3 // "Dark"
	
	
	/* TODO:
	
		ChangeLevel ( "EDAY14", 0, CHANGELEVEL_NOINTERMISSION, -1);
	*/
	
	
}

map EDAY14 lookup CHE14_MAPNAME //"Industrial District"
{
	//titlepatch "CWILV12"
	next = "EDAY15"
	secretnext = "EDAY15"
	//sky1 = "DESERT2"

	// KYSR4 is a Quake 3 cubemap generated using CheSkymp and defined in GLDEFS.cubemaps
	// the humongous smoke pillar backlit by sun is partially baked in
	sky1 = "KYSR4"

	//cluster = 4
	//par = 150
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE


	UsePlayerStartZ
	// because the players must start on top of the fancy 3d floor, not inside it
	
	Par = 1620
	LevelNum = 14
	lightmode = 3 // "Dark"
}


map EDAY15 lookup CHE15_MAPNAME //"Roadblocks"
{
	//titlepatch "CWILV13"
	next = "EDAY15I"
	secretnext = "EDAY15I"
	//sky1 = "DESERT3"

	// a Quake 3 cubemap defined in GLDEFS.cubemaps
	sky1 = "KYSR5"

	//cluster = 5
	//par = 150
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 660
	LevelNum = 15
	lightmode = 3 // "Dark"
}


map EDAY15I lookup CHE15_INTERNAME //"Unskippable Cutscene"
{
	next = "EDAY16"
	secretnext = "EDAY16"
	sky1 = "KYSR6"
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	LevelNum = 150
	lightmode = 3 // "Dark"
}


map EDAY16 lookup CHE16_MAPNAME //"Warzone"
{
	//titlepatch "CWILV13"
	next = "EDAY17"
	secretnext = "EDAY17"
	//sky1 = "SKY2RED"

	// a Quake 3 cubemap defined in GLDEFS.cubemaps
	sky1 = "KYSR6"

	//cluster = 5
	//par = 150
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1260
	LevelNum = 16
	lightmode = 3 // "Dark"
}


map EDAY17 lookup CHE17_MAPNAME //"Twisted Neighborhood"
{
	//titlepatch "CWILV14"
	next = "EDAY18"
	secretnext = "EDAY18"
	//sky1 = "SKY2RED"

	// a Quake 3 cubemap defined in GLDEFS.cubemaps
	// dark smoke 360 degrees all around, NO city baked in. Using top layer geometry for distant cityscape from now on.
	sky1 = "KYSR7"

	//cluster = 5
	//par = 210
	ExitPic = "INTER2"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1560
	LevelNum = 17
	lightmode = 3 // "Dark"
}


map EDAY18 lookup CHE18_MAPNAME //"Dead Streets"
{
	//titlepatch "CWILV15"
	next = "EDAY19"
	secretnext = "EDAY40"


	sky1 ="KYSR8" 
	//the same as KYSR7 but darker and several puffs added, hiding too bright fringes close to the horizon an transparently obscuring the crack of open sky overhead

	//sky1 = "SKY2NI", 0.1

	//cluster = 5
	//par = 150
	ExitPic = "INTER5"
	
	// music can be switched by script if the player finds the secret mech.
	// if you change this, update the map ACS scripts accordingly.
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 2760
	LevelNum = 18
	lightmode = 3 // "Dark"
}

map EDAY40 lookup CHE40_MAPNAME //"Movie Night Out" //"Hollywood Holocaust"
{
	//titlepatch "CWILV15"
	next = "EDAY41"
	secretnext = "PSXM59"
	//sky1 = "SKY2NI", 0.2
	sky1 = "KYSR8"
	//cluster = 5
	//par = 200
	music = ""
	Intermusic = ""
	Par = 660
	LevelNum = 40
	lightmode = 3 // "Dark"
}

// pilfered from psxmaps.wad included with BDv21
map PSXM59 lookup CHE59_MAPNAME //"Club Doom"
{
	next = "EDAY41"
	secretnext = "EDAY41"
	sky1 = "KYSR8"
	//par = 60
	music = ""
	Intermusic = ""
	Par = 180
	LevelNum = 59
	lightmode = 3 // "Dark"
}



map EDAY41 lookup CHE41_MAPNAME // "Red Light District"
{
	next = "EDAY19"
	secretnext = "EDAY42"
	//sky1 = "SKY2NI", 0.2
	sky1 = "KYSR8"
	//cluster = 5
	
	//par = 200
	music = ""
	Intermusic = ""
	Par = 840
	LevelNum = 41
	lightmode = 3 // "Dark"
}


map EDAY42 lookup CHE42_MAPNAME //"Wolfenstein"
{
	//titlepatch "CWILV15"
	// since this map could be reached from map 18-40-41 or from map 29,
	//  the exit is chosen by ACS scripts monitoring player tokens
	next = "EDAY19"
	secretnext = "EDAY30"
	ExitPic="INTER7" // essential for a golden ending completed
	sky1 = "SKY2WOLF" 
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1620
	LevelNum = 42
	lightmode = 3 // "Dark"
}

map EDAY19 lookup CHE19_MAPNAME //"Final Destination"
{
	//titlepatch "CWILV16"
	next = "EDAY20"
	secretnext = "EDAY20"
	
	// sky can be seen through a hole in subway tunnel roof
	// a Quake 3 cubemap defined in GLDEFS.cubemaps
	// sunset sky with mountains and clouds, the only smoke is a vague cloud overhead
	sky1 = "KYSR9"
	
	//sky1 = "SKY2NIE", 0.1
	//cluster = 5
	//par = 420
	ExitPic = "INTER5"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE

	// https://forum.zdoom.org/viewtopic.php?t=71099
	//Grinding_Polyobj
	//P.S. doesn't work, see https://forum.zdoom.org/viewtopic.php?f=123&t=71099
	
	Par = 960
	LevelNum = 19
	lightmode = 3 // "Dark"
}

map EDAY20 lookup CHE20_MAPNAME //"Downtown Assault"
{
	//titlepatch "CWILV17"
	next = "EDAY21"
	secretnext = "EDAY48"
	sky1 = "KYSR9"
	//"SKY2MO", 0.1
	//cluster = 6
	//par = 150
	ExitPic = "INTER5"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
//	Par = 1080
	LevelNum = 20
	lightmode = 3 // "Dark"
}


map EDAY48 lookup CHE48_MAPNAME //"Dissolving District"
{
	next = "EDAY21"
	secretnext = "EDAY21"
	sky1 = "KYSR9" 
	ExitPic = "INTER5"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 48
	lightmode = 3 // "Dark"
}

map EDAY21 lookup CHE21_MAPNAME //"Eye of the Storm"
{
	//titlepatch "CWILV17"
	next = "EDAY22"
	secretnext = "EDAY22"
	sky1 = "KYSR9"
	//sky1 = "SKY2MO", 0.1
	//cluster = 6
	//par = 150
	
	ExitPic = "INTER_H2" // from HESP, 320x200
	Intermusic = EDAYINT // keepint the old EDAY Test 001 intermission music for both maps that end their chapters

	
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 180
	LevelNum = 21
	lightmode = 3 // "Dark"
}



map EDAY22 lookup CHE22_MAPNAME //"The Counter-Offensive"
{
	next = "EDAY23"
	secretnext = "EDAY23"
	//doesn't have any sky.
	//sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	ExitPic = "INTER3"
	
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 660
	LevelNum = 22
	lightmode = 3 // "Dark"
}


map EDAY23 lookup CHE23_MAPNAME //"The Tower"
{
	// Using old light level controlled fog.
	next = "EDAY241" // half of HESP map28
	secretnext = "EDAY47" // former eday21
	sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	//cluster = 7
	ExitPic = "INTER3"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	
	// allow summoned cyberdemon minions to telefrag player
	//P.S. Deprecated, no one is teleported anymore
	//allowmonstertelefrags
	Par = 660
	LevelNum = 23
	lightmode = 3 // "Dark"
}



map EDAY47 lookup CHE47_MAPNAME //"Hell's Backdoor"
{
	// Using old light level controlled fog.
	//next = "EDAY242"
	// in this version, you always exit to map 241, no more branching flow!
	next = "EDAY241"
	secretnext = "EDAY241"
	sky1 = "SKY3BC", 0.05
	//SkyStretch = 1
	//cluster = 71
	ExitPic = "INTER3"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1260
	LevelNum = 47
	lightmode = 3 // "Dark"
}


map EDAY241 lookup CHE241_MAPNAME //"Vile Playground"
{
	next = "EDAY242" 
	secretnext = "EDAY242" 
	sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	//cluster = 7
	ExitPic = "INTER3"
	
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1020
	LevelNum = 241
	lightmode = 3 // "Dark"
}


map EDAY242 lookup CHE242_MAPNAME //"Into the Black Jungle"
{
	next = "EDAY25"
	secretnext = "EDAY25"
	//no skybox, only a fullsphere red sky with a solid-color black cloud overhead to mask the zenith auto-blur
	//skybox bad for map ambience, ANY skybox, because gives directions thus destroying the disorienting feeling
	//again, NEVER work on a map without music. This map music *dictates* bad visibility and no orientirs.
	sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER3"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	Par = 1200
	LevelNum = 242
	lightmode = 3 // "Dark"
}

// stub maps (one room and one teleporter) for those trying to get there via console commands:
map EDAY24 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY242"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	Par = 30
	LevelNum = 24
}


map EDAY25 lookup CHE25_MAPNAME //"Stronghold"
{
	// switch fog scheme globally from light-based to one declared here 
	//fogdensity = 75

	//Feb 2020: Simplified the shit out of the skybox.
	// The scrolling clouds went the way of the T-Rex: were awesome but impractical.
	// Returned to the slowly rotating red sky of old, with only one rock spire left straight ahead.

	next = "EDAY26"
	secretnext = "EDAY26"
	sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER3"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 25
	lightmode = 3 // "Dark"
}



map EDAY26 lookup CHE26_MAPNAME //"House of Hell Nobles"
{
	// This map uses 5 skyboxes. 3 of them have fog, all light level controlled
	next = "EDAY26I"
	secretnext = "EDAY26I"
	sky1 = "SKY3BC", 0.035
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER3"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 26
	lightmode = 3 // "Dark"
}


// The  interlude map goes here

map EDAY26I lookup CHE26I_MAPNAME //"Detour, you say?" / "В обход, говорите?"
{
	next = "EDAY271"
	secretnext = "EDAY271"
	sky1 = "SKY3B", 0.1 // to ease map editing, the editor shows a blue sky otherwise
	ExitPic = "TITKY26I"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 260
	lightmode = 3 // "Dark"
}

// stub map (one room and two teleporters) for those trying to get there via console commands:
map EDAY27 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY271"
	secretnext = "EDAY272"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	LevelNum = 27
}


map EDAY271 lookup CHE271_MAPNAME //"Necropolis" / "Некрополь"
{
	next = "EDAY272"
	secretnext = "EDAY272"
	// uses a fully 3d skybox
	sky1 = "SKY3B", 0.1 // to ease map editing, the editor shows a blue sky otherwise
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER3"
	
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 271
	lightmode = 3 // "Dark"
}

map EDAY272 lookup CHE272_MAPNAME //"The crypts" / "Склепы"
{
	next = "EDAY28"
	secretnext = "EDAY28"
	// uses a fully 3d skybox
	sky1 = "SKY3B", 0.1 // to ease map editing, the editor shows a blue sky otherwise
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER_H3" // from HESP, 320x200
	
	music = ""
	Intermusic = ""
	
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 272
	lightmode = 3 // "Dark"
}


map EDAY28 lookup CHE28_MAPNAME //"City of Dis"
{
	next = "EDAY29"
	secretnext = "EDAY29"
	// uses a fully 3d skybox
	sky1 = "SKY3B", 0.1 // to ease map editing, the editor shows a blue sky otherwise
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER_H3" // from HESP, 320x200
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 28
	lightmode = 3 // "Dark"
}


map EDAY29 lookup CHE29_MAPNAME //"Impious Cathedral"
{
	next = "EDAY30"
	secretnext = "EDAY42" // ACS scripts monitor player tokens and prevent backward loop by blocking the secret exit
	// uses a fully 3d skybox	
	sky1 = "SKY3B", 0.1 // to ease map editing, the editor shows a blue sky otherwise
	//SkyStretch = 1
	//cluster = 8
	ExitPic = "INTER6"

	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 29
	lightmode = 3 // "Dark"
}



map EDAY30 lookup CHE30_MAPNAME //"Sacrificial Grounds"
{
	//titlepatch "CWILV27"
	next = "EDAY311"
	secretnext = "EDAY43"
	// uses a fully 3d skybox
	sky1 = "KYSRH", 0.2 // to ease map editing, the editor shows a blue sky otherwise
	//cluster = 10
	//par = 420
	ExitPic = "INTER6"
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 30
	lightmode = 3 // "Dark"
}


map EDAY43 lookup CHE43_MAPNAME // "Hell doesn't play fair";
{
	next = "EDAY311"
	secretnext = "EDAY311"
	//sky1 = "SKY3BCP", 0.05
	sky1 = "ZIRESK00", 0.1 // the same as HESP hell episode this was made from
	//sky1 = "KYSRH", 0.05
	ExitPic = "INTER6"
	
	music = ""
	Intermusic = ""
	
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 43
	lightmode = 3 // "Dark"
}


map EDAY311 lookup CHE311_MAPNAME //"Peak of the Gods"
{
	//titlepatch "CWILV26"
	next = "EDAY312"
	secretnext = "EDAY312"
	// uses a fully 3d skybox with moving clouds, dramatic thunderbolts and so on
	sky1 = "KYSRH", 0.2 // to ease map editing, the editor shows a blue sky otherwise
	//cluster = 9
	//par = 330
	ExitPic = "INTER6"

	
	music = ""
	Intermusic = ""
	
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	
	//OutsideFog = "80 00 00"
	//Now done via ACS script
	LevelNum = 311
	lightmode = 3 // "Dark"
}


map EDAY312 lookup CHE312_MAPNAME //"Temple of the Beast"
{
	//titlepatch "CWILV26"
	next = "EDAY313"
	secretnext = "EDAY313"
	// uses a 3d skybox BUT with a cubemap sky instead of scrolling ceiling
	// and with a raised camera,
	// to create a "mountaintop above rolling clouds" arena.
	// must NOT use "outsidefog"
	sky1 = "KYSRH", 0.2
	//cluster = 9
	//par = 330
	ExitPic = "INTER6"
	
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	//MONSTERFALLINGDAMAGE
	//*NO* monsterfallingdamage, otherwise pinkies splatter on impact with lava instead of burning
	
	LevelNum = 312
	lightmode = 3 // "Dark"
}

// stub map (one room and two teleporters) for those trying to get there via console commands:
map EDAY31 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY311"
	secretnext = "EDAY312"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	Gravity = 500
	LevelNum = 31
}
// stub map (one room and one teleporter) for those trying to get there via console commands:
map EDAY50 lookup NO_SUCH_MAP_MAPNAME 
{
	next = "EDAY312"
	ExitPic = "TITKYNSM" 
	music = ""
	Intermusic = ""
	LevelNum = 50
}


//***Che the only map created by yours truly from scratch. 
// A boss rush to showcase my super monsters
//   complicated by timed waves of weak monsters spawning all across the map
map EDAY313 lookup CHE313_MAPNAME //"Cocytus Maginot Line"
{
	next = "EDAY32"
	secretnext = "EDAY32"
	sky1 = "KYSRC"
	//ExitPic = "TITKY313"
	ExitPic = "SKYHEL1I" // see TEXTURES.skies
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	LevelNum = 313
	lightmode = 3 // "Dark"
}

map EDAY32 lookup CHE32_MAPNAME //"Traitor's Prison"
{
	//titlepatch "CWILV29"
	next = EDAY32I 
	secretnext = EDAY01 // New Game Plus 
	sky1 = "KYSRC" // only visible above the hole you start under -- meaning only the smiling sunny would be seen
		// OR if the boss catapults you skywards so hard without killing you that you break through the clouds - then you briefly see the sky!
	//cluster = 10
	ExitPic = "INTER6"
	//par = 180
	
	//allowmonstertelefrags // must be set for boss cubes to work as designed
	// Since I have completely changed the minion summoning mechanic
	//   in my Chebskies 1.15 update, this flag should NEVER be set.
	// Monsters now teleport in without any warning

	music = ""
	Intermusic = ""
	
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE

	UsePlayerStartZ
	// because the players must start on top of the fancy transparent ice 3d floor, not inside it
	
	LevelNum = 32
	lightmode = 3 // "Dark"
}

map EDAY32I lookup CHE32I_MAPNAME //"The Ending"
{
	next = "EndGame3"
	secretnext = "EndGame3"
	
	music = ""
	Intermusic = ""
	LevelNum = 320
	lightmode = 3 // "Dark"
	
	/*
		for NG+:
		ChangeLevel ("EDAY01", 0, CHANGELEVEL_NOINTERMISSION, -1);
		//P.S. no such formula could exist, incompatible with my non-standard game skills 
		// | CHANGELEVEL_CHANGESKILL, <a formula to adjust game skill>);
	
	*/
	
	sky1 = "KYETGES2" // for Earth beyond the portal and the good ending
	// all other cutscenes are using dumb backdrop walls exploiting the fact the camera is fixed
}

/*
map CHEK01 lookup CHEK01_MAPNAME //"Cheb's Dare: blind run THIS"
{
	//next = "CHEK02"
	//secretnext = "CHEK02"
	next = endgame {
	   pic = "INTERCKZ"
	}
	secretnext = "EndGameC"
	sky1 = "KYSRZ", 0.05
	ExitPic = "INTERCKZ"
	// SEE LANGUAGE.chekaizo_music
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	//Par=270
	AllowJump
	AllowCrouch
	AllowFreelook
	CheckSwitchRange
	ResetInventory
	UsePlayerStartZ // without this, instant death at start
	lightmode = 3 // "Dark"
}

map CHEK02 lookup CHEK02_MAPNAME //"Cheb's Red Hell-square"
{
	next = endgame {
	   pic = "INTERCKZ"
	}
	secretnext = "EndGameC"
	sky1 = "KYSRZ", 0.05
	ExitPic = "INTERCKZ"
	// SEE LANGUAGE.chekaizo_music
	music = ""
	Intermusic = ""
	FALLINGDAMAGE
	MONSTERFALLINGDAMAGE
	//Par=270
	AllowJump
	AllowCrouch
	AllowFreelook
	CheckSwitchRange
	ResetInventory
	UsePlayerStartZ
	lightmode = 3 // "Dark"
}


map CHEKTIT lookup CHEKTIT_MAPNAME //"The Winner is You"
// a.k.a. "ChebMaster falling for the primordial sin of making a neighborhood location into a doom map".
// I wanted *this* to be the boss fight map at first, BUT real locations make for BAD gameplay
//   so I relegated it to the episode end credits.
// Such a shame.
{
	// no next map
	sky1 = "KYSRZ", 0.05
	// SEE LANGUAGE.chekaizo_music
	music = ""
	Intermusic = ""
	lightmode = 3 // "Dark"
}
*/

