Armax / Pokemon-GO-node-api

Pokemon GO api node.js library
MIT License
875 stars 198 forks source link

"Static SpawnPoint" keeps moving #89

Closed AlexZaccaria closed 8 years ago

AlexZaccaria commented 8 years ago

Running various HeartBeat with the same char's coords, the coords of the spawn points keep changing.

This is an example of looping.

(loop x) My Char Pos: 45.4654219 9.1859243 Cell[0], Spawn[0]: 45.46624197263168 9.195482249460966

(loop x+1) My Char Pos: 45.4654219 9.1859243 Cell[0], Spawn[0]: 45.46279173734066 9.191362482551467

(loop x+2) My Char Pos: 45.4654219 9.1859243 Cell[0], Spawn[0]: 45.46613823976688 9.191262744225018

    for (var idx = 0; idx < hb.cells[i].DecimatedSpawnPoint.length; idx++)
    {
        var SP = hb.cells[i].DecimatedSpawnPoint[idx];
        if (idx === 0 && i === 0)
        {
            console.log(Pokeio.playerInfo.latitude, Pokeio.playerInfo.longitude);
            console.log(SP.Latitude, SP.Longitude);
        }
             (some other code)
     }

Any idea why? PS: I was unable to get the coords of the detected pokemon in the cells, can we expose them to track them down? Thank you.

Elyx0 commented 8 years ago

Heartbeat is broken currently. Wait for update. Pokemon are in WildPokemon & MapPokemon array of the cells

st0ffern commented 8 years ago

@AlexZaccaria It is working in my API.. https://github.com/stoffern/pokemon-go-api

AlexZaccaria commented 8 years ago

I'm going to check @stoffern heartbeat, thank you for your cooperation. Last question: does anyone knows how to check borders of current cells ? 'because i'm moving in my loop, but since i cannot figure out the bounds of the cells, i'm adding 0,001 to the last trackable item