2025-01-03 12:09:23 +00:00
|
|
|
using Godot;
|
|
|
|
using System.Collections;
|
|
|
|
using System.Collections.Generic;
|
|
|
|
using Godot.Collections;
|
|
|
|
|
|
|
|
namespace Rokojori
|
|
|
|
{
|
|
|
|
[Tool]
|
|
|
|
[GlobalClass]
|
|
|
|
public partial class LODArrangement:Resource
|
|
|
|
{
|
|
|
|
[Export]
|
2025-02-12 16:48:15 +00:00
|
|
|
public LODLevel[] levels = new LODLevel[ 0 ];
|
2025-01-03 12:09:23 +00:00
|
|
|
|
|
|
|
public LODLevel GetLevel( LODNode node )
|
|
|
|
{
|
|
|
|
for ( int i = 0; i < levels.Length; i++ )
|
|
|
|
{
|
|
|
|
if ( ! levels[ i ].Evaluate( node ) )
|
|
|
|
{
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
|
|
|
|
return levels[ i ];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|