;--------------------------------------------------------------------
;STRIPPER CFG BY MOLTARD http://steamcommunity.com/id/0123456789ABC/
;--------------------------------------------------------------------
;FIX NO KNOCKBACK SKELETON AFTER DEATH
;--------------------------------------


add:
{
	"model" "*12"
	"targetname" "game_playerdie"
	"origin" "0 0 0"
	"StartDisabled" "1"
	"spawnflags" "0"
	"InputFilter" "14"
	"classname" "trigger_brush"
	"OnUse" "!activator,SetdamageFilter,,0.02,-1"
	"OnUse" "!activator,AddOutput,rendermode 0,0.02,-1"
}


;; _

;; stage 1 - fix afk teleport glitch spots

modify:
{
	match:
	{
		"targetname" "stage1_tp1"
		"classname" "trigger_multiple"
	}
	replace:
	{
		"origin" "1215 538.5 -948.5"
	}
}

add:
{
	"model" "*281"
	"wait" "0.1"
	"targetname" "stage1_tp1"
	"StartDisabled" "1"
	"spawnflags" "1"
	"origin" "757.5 538.5 -948.5"
	"classname" "trigger_multiple"
	"OnStartTouch" "!activator,AddOutput,origin 1171 -1316 -4088,0,-1"
}

;; stage 2,3 - fix afk teleport glitch spots

add:
{
	"targetname" "porttele1"
	"target" "teler1"
	"StartDisabled" "1"
	"spawnflags" "1"
	"origin" "-7111 14272 -3802.5"
	"classname" "trigger_teleport"
	"OnUser1" "!self,AddOutput,solid 2,0,1"
	"OnUser1" "!self,AddOutput,mins -474 -280 -130.5,0.1,1"
	"OnUser1" "!self,AddOutput,maxs 474 280 130.5,0.1,1"
}

modify:
{
	match:
	{
		"classname" "logic_auto"
		"hammerid" "135137"
	}
	insert:
	{
		"OnMapSpawn" "porttele1,FireUser1,,0,-1"
	}
}

add:
{
	"model" "*152"
	"targetname" "porttele3"
	"target" "teler1"
	"StartDisabled" "1"
	"spawnflags" "1"
	"origin" "-3486 12487 -3827"
	"classname" "trigger_teleport"
}
add:
{
	"model" "*152"
	"targetname" "stage3_mars_tp"
	"target" "hellteleport"
	"StartDisabled" "1"
	"spawnflags" "1"
	"origin" "-620 12611.5 -4292"
	"classname" "trigger_teleport"
}

;; stage 3 - disable zm push after bossfight a bit later

modify:
{
	match:
	{
		"targetname" "telehell1"
		"classname" "trigger_teleport"
	}
	delete:
	{
		"OnStartTouch" "logs1,Kill,,2,1"
	}
	insert:
	{
		"OnStartTouch" "logs1,Kill,,6,1"
	}
}

;; stage 3 - fix boss fall trigger

modify:
{
	match:
	{
		"model" "*230"
		"origin" "-1364.5 -4025.5 6965"
		"classname" "trigger_hurt"
	}
	replace:
	{
		"origin" "-1364.5 -4025.5 6901"
	}
	delete:
	{
		"filtername" "gloxs1"
	}
}

;; stage 2 - detect zm after the door is closed

modify:
{
	match:
	{
		"targetname" "zm_detec"
		"classname" "trigger_once"
	}
	insert:
	{
		"StartDisabled" "1"
	}
}
modify:
{
	match:
	{
		"targetname" "gront2"
		"classname" "func_door"
	}
	delete:
	{
		"OnFullyClosed" "lvl_tr_2,Enable,,0,1"
	}
	insert:
	{
		"OnFullyClosed" "zm_detec,Enable,,0,1"
		"OnFullyClosed" "lvl_tr_2,Enable,,3,1"
	}
}