private void LoadGameSession(IServicesInjector services) { var gameSession = services.Get <IGameSession>(); if (gameCharacterPrefab == null) { gameCharacterPrefab = gameSession.PrefabToSpawn; } CurrentCharacter = Instantiate(gameCharacterPrefab, transform, false); CurrentCharacter.transform.position = transformData.position; CurrentCharacter.transform.rotation = transformData.rotation; CurrentCharacter.SetupData(gameSession.InstanceData, services); transformData.gameObject.SetActive(false); }
public override void EarlyInitialization(IServicesInjector gamePlayServices) { Camera = gamePlayServices.Get <ICameraBinder>().GetCamera(); PlayerBinder = gamePlayServices.Get <IPlayerBinder>(); }
public override void EarlyInitialization(IServicesInjector gamePlayServices) { model = gamePlayServices.Get <IPlayerAnimatorModel>(); }
public override void EarlyInitialization(IServicesInjector gamePlayServices) { PlayerAimHelper = gamePlayServices.Get <IPlayerAimHelper>(); model = gamePlayServices.Get <IPlayerMovementModel>(); //rb = gamePlayServices.Get<PlayerBinder>().Rigidbody; }