FSO.Client.Program.GetClientVersion C# (CSharp) Method

GetClientVersion() private static method

Loads the client's version from "Client.manifest". This is here because it should be one of the first things the client does when it starts.
private static GetClientVersion ( ) : string
return string
        private static string GetClientVersion()
        {
            string ExeDir = GlobalSettings.Default.StartupPath;

            //Never make an assumption that a file exists.
            if (File.Exists(ExeDir + "\\Client.manifest"))
            {
                using (BinaryReader Reader = new BinaryReader(File.Open(ExeDir + "\\Client.manifest", FileMode.Open, FileAccess.Read, FileShare.Read)))
                {
                    return Reader.ReadString() + ".0"; //Last version number is unused.
                }
            }
            else
            {
                //Version as of writing this method.
                return "0.1.26.0";
            }
        }