From 0599f289f0a8d6b2ec3fd512b3723f9d0bc74fc1 Mon Sep 17 00:00:00 2001
From: GwWuYou <95328647+GeWuYou@users.noreply.github.com>
Date: Thu, 1 Jan 2026 21:48:21 +0800
Subject: [PATCH] =?UTF-8?q?refactor(godot):=20=E9=87=8D=E6=9E=84=E8=B5=84?=
=?UTF-8?q?=E6=BA=90=E5=B7=A5=E5=8E=82=E7=B3=BB=E7=BB=9F=E6=9E=B6=E6=9E=84?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 移除 IArchitecturePhaseAware 接口依赖
- 将 OnArchitecturePhase 方法改为重写基类方法
- 添加 Godot 模块命名空间占位类型
- 移除项目中未使用的 NUnit 包引用
---
.../GodotModuleMarker.cs | 6 ++++++
GFramework.Godot/assets/AbstractResourceFactorySystem.cs | 5 ++---
GFramework.csproj | 3 ---
3 files changed, 8 insertions(+), 6 deletions(-)
create mode 100644 GFramework.Godot.SourceGenerators.Abstractions/GodotModuleMarker.cs
diff --git a/GFramework.Godot.SourceGenerators.Abstractions/GodotModuleMarker.cs b/GFramework.Godot.SourceGenerators.Abstractions/GodotModuleMarker.cs
new file mode 100644
index 0000000..a56403b
--- /dev/null
+++ b/GFramework.Godot.SourceGenerators.Abstractions/GodotModuleMarker.cs
@@ -0,0 +1,6 @@
+namespace GFramework.Godot.SourceGenerators.Abstractions;
+
+///
+/// Godot 模块命名空间占位类型
+///
+internal sealed class GodotModuleMarker;
\ No newline at end of file
diff --git a/GFramework.Godot/assets/AbstractResourceFactorySystem.cs b/GFramework.Godot/assets/AbstractResourceFactorySystem.cs
index f986663..9c1ac24 100644
--- a/GFramework.Godot/assets/AbstractResourceFactorySystem.cs
+++ b/GFramework.Godot/assets/AbstractResourceFactorySystem.cs
@@ -1,4 +1,3 @@
-using GFramework.Core.Abstractions.architecture;
using GFramework.Core.Abstractions.enums;
using GFramework.Core.system;
using GFramework.Game.Abstractions.assets;
@@ -11,7 +10,7 @@ namespace GFramework.Godot.assets;
/// 资源工厂系统抽象基类,用于统一管理各类资源的创建与预加载逻辑。
/// 提供注册场景和资源的方法,并通过依赖的资源加载系统和资产目录系统完成实际资源的获取与构造。
///
-public abstract class AbstractResourceFactorySystem : AbstractSystem, IResourceFactorySystem, IArchitecturePhaseAware
+public abstract class AbstractResourceFactorySystem : AbstractSystem, IResourceFactorySystem
{
private IAssetCatalogSystem? _assetCatalogSystem;
private ResourceFactory.Registry? _registry;
@@ -22,7 +21,7 @@ public abstract class AbstractResourceFactorySystem : AbstractSystem, IResourceF
/// 在架构阶段发生变化时执行相应的处理逻辑。
///
/// 当前的架构阶段
- public void OnArchitecturePhase(ArchitecturePhase phase)
+ public override void OnArchitecturePhase(ArchitecturePhase phase)
{
if (phase == ArchitecturePhase.Ready)
{
diff --git a/GFramework.csproj b/GFramework.csproj
index 6c6de78..5c9bc32 100644
--- a/GFramework.csproj
+++ b/GFramework.csproj
@@ -110,7 +110,4 @@
-
-
-