Beispiel #1
0
        private void SetupPlayer(GamePlayer player)
        {
            if (!player.TankSelectionIsValid) //Do the selection for them if their selection is invalid
            {
                player.SelectedTankReflectionName = Gamemode.DefaultTankTypeReflectionName;
            }

            var tank = Tank.ReflectiveInitialize(player.SelectedTankReflectionName, player, this, false);

            player.SpawnPoint = Map.GetSpawnPosition(Gamemode.GetTeamIndex(player));

            tank.Position  = player.SpawnPoint;
            tank.ColorMask = player.Team.TeamColor;

            AddGameObject(tank);
            player.Tank = tank;
        }