private void CreatePlayerFromTemplate(AvatarTemplate template) { GameObject player = Instantiate(template.visuals, playerSpawnSpot.transform.position, playerSpawnSpot.transform.rotation); currentPlayer = player.AddComponent <Player>(); }
private void HandleAvatarUpdated(AvatarTemplate template) { //TODO Optimize this Destroy(_currentAvatar); _currentAvatar = Instantiate(template.visuals, this.transform.position, this.transform.rotation); }
private void HandleAvatarSelected(AvatarTemplate template) { //TODO Optimize this Destroy(_currentAvatar); }
private void HandlePlayerSelected(AvatarTemplate template) { this.gameObject.SetActive(false); //TODO //Call the audio manager to play the avatar SFX }
private void HandleAvatarSelected(AvatarTemplate template) { CreatePlayerFromTemplate(template); }