mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-05-29 10:24:34 +00:00
Move Common functionality to Core project & rendering and Model support as well
This commit is contained in:
17
PckStudio.Core/Extensions/MaterialExtensions.cs
Normal file
17
PckStudio.Core/Extensions/MaterialExtensions.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using OMI.Formats.Material;
|
||||
|
||||
namespace PckStudio.Core.Extensions
|
||||
{
|
||||
public static class MaterialExtensions
|
||||
{
|
||||
public static bool HasInvalidEntries(this MaterialContainer materials)
|
||||
{
|
||||
return materials.Any(mat => !MaterialContainer.SupportedEntities.Contains(mat.Name) || !MaterialContainer.ValidMaterialTypes.Contains(mat.Type));
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user