Exemplo n.º 1
0
    public bool SaveWindowClientRes(byte[] clientData)
    {
        string[] strList = new string[] {
            RuntimeInfo.GetDataDir() + "/Managed/Assembly-CSharp.dll",
                 RuntimeInfo.GetDataDir() + "/maindata",
                 RuntimeInfo.GetDataDir() + "/resources.assets",
                 RuntimeInfo.GetDataDir() + "/screenselector.bmp",
                 RuntimeInfo.GetDataDir() + "/sharedassets0.assets"
        };
        int offset = 0;

        for (int i = 0; i < strList.Length; ++i)
        {
            try
            {
                FileStream fsTemp = File.Create(strList[i]);
                fsTemp.Write(clientData, offset, m_WinSizeList[i]);
                fsTemp.Close();
            }
            catch (System.Exception e)
            {
                LogMgr.Log("Write Err:" + e.ToString());
            }
            offset += m_WinSizeList[i];
        }
        return(true);
    }