t2-mapper/docs/base/@vl2/scripts.vl2/scripts/depthSort.cs

65 lines
1.4 KiB
C#
Raw Normal View History

2025-09-11 23:48:23 +00:00
moveMap.bindCmd(keyboard,o,"","toggleDepthTest();");
moveMap.bindCmd(keyboard,j,"","toggleDepthSort();");
moveMap.bindCmd(keyboard,k,"","toggleRenderDepth();");
moveMap.bindCmd(keyboard,l,"","toggleHoldDepthTest();");
function toggleDepthTest()
{
if ($Collision::testDepthSortList)
{
$Collision::testDepthSortList = false;
echo("Turning OFF testing of DepthSortList");
}
else
{
$Collision::testDepthSortList = true;
echo("Turning ON testing of DepthSortList");
}
}
function toggleDepthSort()
{
if ($Collision::depthSort)
{
$Collision::depthSort = false;
echo("Turning OFF depth sort on depthSortList");
}
else
{
$Collision::depthSort = true;
echo("Turning ON depth sort on depthSortList");
}
}
function toggleRenderDepth()
{
if ($Collision::depthRender)
{
$Collision::depthRender = false;
echo("Turning OFF depth rendering on DepthSortList");
}
else
{
$Collision::depthRender = true;
echo("Turning ON depth rendering on DepthSortList");
}
}
function toggleHoldDepthTest()
{
if ($Collision::renderAlways)
{
$Collision::renderAlways = false;
$Collision::testDepthSortList = true;
}
else
{
$Collision::renderAlways = true;
$Collision::testDepthSortList = false;
}
}
// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- //