示例#1
0
        public Client(ISettings settings)
        {
            Settings = settings;

            Login = new Rpc.Login(this);
            Player = new Rpc.Player(this);
            Download = new Rpc.Download(this);
            Inventory = new Rpc.Inventory(this);
            Map = new Rpc.Map(this);
            Fort = new Rpc.Fort(this);
            Encounter = new Rpc.Encounter(this);
            Misc = new Rpc.Misc(this);

            Player.SetCoordinates(Settings.DefaultLatitude, Settings.DefaultLongitude, Settings.DefaultAltitude);
        }
示例#2
0
        public Client(Shared.ClientSettings settings)
        {
            ReadyToUse        = false;
            AuthType          = settings.userType;
            Username          = settings.userName;
            Password          = settings.password;
            proxy             = InitProxy(settings.proxyUrl, settings.proxyPort, settings.proxyUser, settings.proxyPass);
            PokemonHttpClient = new PokemonHttpClient();
            Login             = new Rpc.Login(this);
            Player            = new Rpc.Player(this);
            Download          = new Rpc.Download(this);
            Inventory         = new Rpc.Inventory(this);
            Map       = new Rpc.Map(this);
            Fort      = new Rpc.Fort(this);
            Encounter = new Rpc.Encounter(this);
            Misc      = new Rpc.Misc(this);
            Crypter   = new Crypto();
            Hasher    = new PokeHashHasher(settings.hashKey);
            Store     = new PokemonGo.RocketAPI.Rpc.Store(this);

            if (DeviceSetup.SelectedDevice.OSType == "iOS")
            {
                Platform = POGOProtos.Enums.Platform.Ios;
            }
            else
            {
                Platform = POGOProtos.Enums.Platform.Android;
            }

            Logger.Info("Platform:" + Platform);


            InventoryLastUpdateTimestamp = 0;

            AppVersion   = Resources.Api.AndroidClientVersionInt;
            SettingsHash = "";

            CurrentApiEmulationVersion = settings.currentApi;
        }
示例#3
0
        public Client(ISettings settings)
        {
            Settings          = settings;
            proxy             = InitProxy();
            PokemonHttpClient = new PokemonHttpClient();
            Login             = new Rpc.Login(this);
            Player            = new Rpc.Player(this);
            Download          = new Rpc.Download(this);
            Inventory         = new Rpc.Inventory(this);
            Map       = new Rpc.Map(this);
            Fort      = new Rpc.Fort(this);
            Encounter = new Rpc.Encounter(this);
            Misc      = new Rpc.Misc(this);

            Player.SetCoordinates(settings.DefaultLatitude, settings.DefaultLongitude, settings.DefaultAltitude);

            InventoryLastUpdateTimestamp = 0;

            AppVersion   = 4303;
            SettingsHash = "";

            CurrentApiEmulationVersion = new Version("0.43.3");
        }