From 6b51c04deb18cc31a9318079c7f53cdc6b6e81b1 Mon Sep 17 00:00:00 2001
From: GeWuYou <95328647+GeWuYou@users.noreply.github.com>
Date: Fri, 20 Feb 2026 22:29:30 +0800
Subject: [PATCH] =?UTF-8?q?feat(scene):=20=E6=B7=BB=E5=8A=A0=E7=8E=AF?=
=?UTF-8?q?=E7=BB=95=E5=9C=BA=E6=99=AF=E8=BF=87=E6=B8=A1=E5=A4=84=E7=90=86?=
=?UTF-8?q?=E5=99=A8=E6=B3=A8=E5=86=8C=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 实现 RegisterAroundHandler 方法用于注册环绕场景过渡处理器
- 实现 UnregisterAroundHandler 方法用于注销环绕场景过渡处理器
- 添加处理器选项配置参数支持
- 提供完整的环绕处理器生命周期管理功能
---
GFramework.Game/scene/SceneRouterBase.cs | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/GFramework.Game/scene/SceneRouterBase.cs b/GFramework.Game/scene/SceneRouterBase.cs
index 1425f4d..063b26b 100644
--- a/GFramework.Game/scene/SceneRouterBase.cs
+++ b/GFramework.Game/scene/SceneRouterBase.cs
@@ -141,6 +141,28 @@ public abstract class SceneRouterBase
_pipeline.UnregisterHandler(handler);
}
+ ///
+ /// 注册环绕场景过渡处理器。
+ ///
+ /// 环绕处理器实例。
+ /// 处理器选项配置。
+ public void RegisterAroundHandler(
+ ISceneAroundTransitionHandler handler,
+ SceneTransitionHandlerOptions? options = null)
+ {
+ _pipeline.RegisterAroundHandler(handler, options);
+ }
+
+ ///
+ /// 注销环绕场景过渡处理器。
+ ///
+ /// 环绕处理器实例。
+ public void UnregisterAroundHandler(
+ ISceneAroundTransitionHandler handler)
+ {
+ _pipeline.UnregisterAroundHandler(handler);
+ }
+
///
/// 添加场景路由守卫。
///