AcManager.Tools.SemiGui.VariablesReplacement.GetType C# (CSharp) Метод

GetType() публичный статический Метод

public static GetType ( Game startProperties, [ result ) : string
startProperties AcTools.Processes.Game
result [
Результат string
        public static string GetType(Game.StartProperties startProperties, [CanBeNull] Game.Result result) {
            // TODO: drag mode
            if (startProperties.ModeProperties is Game.DriftProperties) {
                return "Drift";
            }

            if (startProperties.ModeProperties is Game.TimeAttackProperties) {
                return "Time Attack";
            }

            if (startProperties.ModeProperties is Game.HotlapProperties) {
                return "Hotlap";
            }

            if (startProperties.ModeProperties is Game.OnlineProperties) {
                return "Online";
            }

            if (startProperties.ModeProperties is Game.PracticeProperties) {
                return "Practice";
            }

            if (result?.Sessions?.Length == 1) {
                return "Race";
            }

            if (result?.Sessions?.Length > 1) {
                return "Weekend";
            }

            return startProperties.ModeProperties is Game.RaceProperties ? "Race" : "Something Unspeakable";
        }