/// <summary> /// Initializes a new instance of the <see cref="SpawningEventArgs"/> class. /// </summary> /// <param name="player"><inheritdoc cref="Player"/></param> /// <param name="roleType"><inheritdoc cref="RoleType"/></param> public SpawningEventArgs(Player player, RoleType roleType) { Player = player; RoleType = roleType; (Vector3 postion, float rotation) = roleType.GetRandomSpawnProperties(); if (postion == Vector3.zero) { Position = player.ReferenceHub.characterClassManager.DeathPosition; RotationY = 0f; } else { Position = postion; RotationY = rotation; } }