Ejemplo n.º 1
0
    public void ShowGold(uint nGold, uint nTime)
    {
        m_sharetype = ShareType.SHARE_GOLD;
        InIt();
        m_labelWin.text      = NumtoString(nGold);
        m_labelgametime.text = nTime.ToString() + "分钟";

        uint nMaxWin = 0;

        byte[] data = RuntimeInfo.GetLocalFile(RuntimeInfo.GameShareMaxWin());
        if (data != null)//第一次
        {
            nMaxWin = System.BitConverter.ToUInt32(data, 0);
        }

        if (nGold > nMaxWin)
        {
            System.IO.MemoryStream ms = new System.IO.MemoryStream();
            System.IO.BinaryWriter bw = new System.IO.BinaryWriter(ms);
            bw.Write(nGold);
            RuntimeInfo.SaveLocalFile(RuntimeInfo.GameShareMaxWin(), ms.ToArray());
        }

        m_labelmaxwin.text = NumtoString(nMaxWin);
    }