예제 #1
0
    void SaveSetting( )
    {
        var setting = new gamedef.LoginSetting();

        setting.Account = Account;
        setting.Address = Address;
        LocalSetting.Save <gamedef.LoginSetting>("login", setting);
    }
예제 #2
0
    public void Start( )
    {
        var a = new gamedef.LoginSetting();

        a.Account = "hello";

        var writer = new System.IO.MemoryStream();

        ProtoBuf.Serializer.Serialize(writer, a);

        writer.Position = 0;
        var c = ProtoBuf.Serializer.Deserialize <gamedef.LoginSetting>(writer);
    }
예제 #3
0
    public LoginModel(GameObject loginui)
    {
        _loginPeer = loginui.GetComponent <NetworkPeer>();

        _setting = LocalSetting.Load <gamedef.LoginSetting>("login");
    }