mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-03-22 10:34:30 +08:00
feat(template): 添加控制器类模板并更新项目配置
- 添加了控制器类模板文件 ControllerTemplate.cs - 在项目文件中添加 Godot 目录的排除规则 - 更新项目引用和编译排除规则 - 统一项目配置中的路径格式 - 添加控制器模板的元数据信息 - [skip ci]
This commit is contained in:
parent
f87c9cf421
commit
e23a53c3d4
@ -51,6 +51,7 @@
|
||||
<None Remove="GFramework.Generator.Attributes\**"/>
|
||||
<None Remove="GFramework.Godot.SourceGenerators.Attributes\**"/>
|
||||
<None Remove="GFramework.SourceGenerators.Attributes\**"/>
|
||||
<None Remove="Godot\**"/>
|
||||
</ItemGroup>
|
||||
<!-- 聚合核心模块 -->
|
||||
<ItemGroup>
|
||||
@ -85,6 +86,7 @@
|
||||
<Compile Remove="GFramework.Generator.Attributes\**"/>
|
||||
<Compile Remove="GFramework.Godot.SourceGenerators.Attributes\**"/>
|
||||
<Compile Remove="GFramework.SourceGenerators.Attributes\**"/>
|
||||
<Compile Remove="Godot\**"/>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Remove="GFramework.Core\**"/>
|
||||
@ -105,6 +107,7 @@
|
||||
<EmbeddedResource Remove="GFramework.Generator.Attributes\**"/>
|
||||
<EmbeddedResource Remove="GFramework.Godot.SourceGenerators.Attributes\**"/>
|
||||
<EmbeddedResource Remove="GFramework.SourceGenerators.Attributes\**"/>
|
||||
<EmbeddedResource Remove="Godot\**"/>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<AdditionalFiles Remove="AnalyzerReleases.Shipped.md"/>
|
||||
|
||||
22
Godot/script_templates/Node/ControllerTemplate.cs
Normal file
22
Godot/script_templates/Node/ControllerTemplate.cs
Normal file
@ -0,0 +1,22 @@
|
||||
// meta-name: 控制器类模板
|
||||
// meta-description: 负责管理场景的生命周期和架构关联
|
||||
using Godot;
|
||||
using GFramework.Core.Abstractions.controller;
|
||||
using GFramework.SourceGenerators.Abstractions.logging;
|
||||
using GFramework.SourceGenerators.Abstractions.rule;
|
||||
|
||||
|
||||
[ContextAware]
|
||||
[Log]
|
||||
public partial class _CLASS_ :_BASE_,IController
|
||||
{
|
||||
/// <summary>
|
||||
/// 节点准备就绪时的回调方法
|
||||
/// 在节点添加到场景树后调用
|
||||
/// </summary>
|
||||
public override void _Ready()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user