namespace ET.Client { public static class UnitHelper { public static Unit GetMyUnitFromClientScene(Scene clientScene) { PlayerComponent playerComponent = clientScene.GetComponent(); Scene currentScene = clientScene.GetComponent().Scene; return currentScene.GetComponent().Get(playerComponent.MyId); } public static Unit GetMyUnitFromCurrentScene(Scene currentScene) { PlayerComponent playerComponent = currentScene.Parent.GetParent().GetComponent(); return currentScene.GetComponent().Get(playerComponent.MyId); } } }