Advertisement
Guest User

Untitled

a guest
Feb 20th, 2019
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. this.contract.methods.getPlayerAnimals(this.address)
  2. .call({ from: this.address })
  3. .then((animals) => {
  4. for (var animal of animals) {
  5. this.contract.methods.getAnimal(animal)
  6. .call({ from: this.address })
  7. .then((animalContract) => {
  8. this.playerAnimals.push(fullAnimal)
  9. });
  10. }
  11. this.socket.emit('playerAnimals', this.playerAnimals)
  12. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement