| Lua/LuaWindow.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| Utility/TransformExtension.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
Lua/LuaWindow.cs
@@ -61,8 +61,11 @@ onActived = null; onLateUpdate = null; if (scriptEnv != null) { scriptEnv.Dispose(); } } protected override void BindController() { Utility/TransformExtension.cs
@@ -147,6 +147,23 @@ return false; } [XLua.LuaCallCSharp] public static void SetPosition(this Transform transform, float x, float y, float z, bool isLocal = false) { if (transform == null) { return; } if (isLocal) { transform.localPosition = new Vector3(x, y, z); } else { transform.position = new Vector3(x, y, z); } } public static Transform GetRoot(this Transform transform) {