add: Template Define
This commit is contained in:
@@ -9,6 +9,7 @@
|
|||||||
<Compile Remove="script_templates/**/*.*"/>
|
<Compile Remove="script_templates/**/*.*"/>
|
||||||
<Compile Remove="embedded/polonium_templates/**/*.cs"/>
|
<Compile Remove="embedded/polonium_templates/**/*.cs"/>
|
||||||
<AdditionalFiles Include="Assets/**/*.tscn"/>
|
<AdditionalFiles Include="Assets/**/*.tscn"/>
|
||||||
|
<AdditionalFiles Include="Data/**/*" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<Target Name="PoloniumPrepare" BeforeTargets="PoloniumClean">
|
<Target Name="PoloniumPrepare" BeforeTargets="PoloniumClean">
|
||||||
|
|||||||
9
src/Attributes/TemplateDefines/TemplateBlock.cs
Normal file
9
src/Attributes/TemplateDefines/TemplateBlock.cs
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
namespace Polonium.Attributes.TemplateDefines;
|
||||||
|
[AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
|
||||||
|
public class TemplateBlock(string signature, string template, string dataFile, string deps="") : Attribute
|
||||||
|
{
|
||||||
|
public string Signature { get; set; } = signature;
|
||||||
|
public string Template { get; set; } = template;
|
||||||
|
public string DataFile { get; set; } = dataFile;
|
||||||
|
public string Deps { get; set; } = deps;
|
||||||
|
}
|
||||||
9
src/Attributes/TemplateDefines/TemplateInline.cs
Normal file
9
src/Attributes/TemplateDefines/TemplateInline.cs
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
namespace Polonium.Attributes.TemplateDefines;
|
||||||
|
|
||||||
|
[AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
|
||||||
|
public class TemplateInline(string template, string dataFile, string deps="") : Attribute
|
||||||
|
{
|
||||||
|
public string Template { get; set; } = template;
|
||||||
|
public string DataFile { get; set; } = dataFile;
|
||||||
|
public string Deps { get; set; } = deps;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user