@aurigami/sdk 1.12.8 → 1.12.9-hf
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ChangeLog.md +371 -0
- package/dist/interactors/PlyGame.d.ts +1 -0
- package/dist/sdk.cjs.development.js +53 -13
- package/dist/sdk.cjs.development.js.map +1 -1
- package/dist/sdk.cjs.production.min.js +1 -1
- package/dist/sdk.cjs.production.min.js.map +1 -1
- package/dist/sdk.esm.js +53 -13
- package/dist/sdk.esm.js.map +1 -1
- package/package.json +4 -3
- package/src/.DS_Store +0 -0
- package/src/interactors/PlyGame.ts +10 -1
- package/src/interactors/misc.ts +8 -5
package/dist/sdk.esm.js
CHANGED
|
@@ -4836,7 +4836,10 @@ var MiscRead = /*#__PURE__*/function (_BlockchainEntityRead) {
|
|
|
4836
4836
|
return p;
|
|
4837
4837
|
}, new BigNumber(0));
|
|
4838
4838
|
_context.next = 19;
|
|
4839
|
-
return this.env.comptroller.getAccountLiquidity(userAddress)
|
|
4839
|
+
return this.env.comptroller.getAccountLiquidity(userAddress)["catch"](function (e) {
|
|
4840
|
+
console.log(e);
|
|
4841
|
+
return [BigNumber$1.from(0), BigNumber$1.from(0)];
|
|
4842
|
+
});
|
|
4840
4843
|
|
|
4841
4844
|
case 19:
|
|
4842
4845
|
accountLiquidity = _context.sent;
|
|
@@ -5512,6 +5515,43 @@ var PlyGameRead = /*#__PURE__*/function (_BlockchainEntityRead) {
|
|
|
5512
5515
|
return getLastJackpotResult;
|
|
5513
5516
|
}();
|
|
5514
5517
|
|
|
5518
|
+
_proto.overallLeaderboard = /*#__PURE__*/function () {
|
|
5519
|
+
var _overallLeaderboard = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee8() {
|
|
5520
|
+
var _this5 = this;
|
|
5521
|
+
|
|
5522
|
+
var result;
|
|
5523
|
+
return runtime_1.wrap(function _callee8$(_context8) {
|
|
5524
|
+
while (1) {
|
|
5525
|
+
switch (_context8.prev = _context8.next) {
|
|
5526
|
+
case 0:
|
|
5527
|
+
_context8.next = 2;
|
|
5528
|
+
return getPaginatedApi('/plygame/overallLeaderboard');
|
|
5529
|
+
|
|
5530
|
+
case 2:
|
|
5531
|
+
result = _context8.sent;
|
|
5532
|
+
return _context8.abrupt("return", result.items.map(function (item) {
|
|
5533
|
+
return {
|
|
5534
|
+
player: item.user,
|
|
5535
|
+
unlockedPulpAmount: new TokenAmount(_this5.pulpToken, item.unlockedAmount),
|
|
5536
|
+
gamesPlayed: item.count
|
|
5537
|
+
};
|
|
5538
|
+
}));
|
|
5539
|
+
|
|
5540
|
+
case 4:
|
|
5541
|
+
case "end":
|
|
5542
|
+
return _context8.stop();
|
|
5543
|
+
}
|
|
5544
|
+
}
|
|
5545
|
+
}, _callee8);
|
|
5546
|
+
}));
|
|
5547
|
+
|
|
5548
|
+
function overallLeaderboard() {
|
|
5549
|
+
return _overallLeaderboard.apply(this, arguments);
|
|
5550
|
+
}
|
|
5551
|
+
|
|
5552
|
+
return overallLeaderboard;
|
|
5553
|
+
}();
|
|
5554
|
+
|
|
5515
5555
|
return PlyGameRead;
|
|
5516
5556
|
}(BlockchainEntityRead);
|
|
5517
5557
|
var PlyGameReadWrite = /*#__PURE__*/function (_PlyGameRead) {
|
|
@@ -5529,19 +5569,19 @@ var PlyGameReadWrite = /*#__PURE__*/function (_PlyGameRead) {
|
|
|
5529
5569
|
_proto2.makeBetOnce =
|
|
5530
5570
|
/*#__PURE__*/
|
|
5531
5571
|
function () {
|
|
5532
|
-
var _makeBetOnce = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function
|
|
5533
|
-
return runtime_1.wrap(function
|
|
5572
|
+
var _makeBetOnce = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee9(amount) {
|
|
5573
|
+
return runtime_1.wrap(function _callee9$(_context9) {
|
|
5534
5574
|
while (1) {
|
|
5535
|
-
switch (
|
|
5575
|
+
switch (_context9.prev = _context9.next) {
|
|
5536
5576
|
case 0:
|
|
5537
|
-
return
|
|
5577
|
+
return _context9.abrupt("return", this.env.plygame.connect(this._networkConnection.signer).makeBetOnce(amount.rawAmount()));
|
|
5538
5578
|
|
|
5539
5579
|
case 1:
|
|
5540
5580
|
case "end":
|
|
5541
|
-
return
|
|
5581
|
+
return _context9.stop();
|
|
5542
5582
|
}
|
|
5543
5583
|
}
|
|
5544
|
-
},
|
|
5584
|
+
}, _callee9, this);
|
|
5545
5585
|
}));
|
|
5546
5586
|
|
|
5547
5587
|
function makeBetOnce(_x5) {
|
|
@@ -5552,19 +5592,19 @@ var PlyGameReadWrite = /*#__PURE__*/function (_PlyGameRead) {
|
|
|
5552
5592
|
}();
|
|
5553
5593
|
|
|
5554
5594
|
_proto2.approve = /*#__PURE__*/function () {
|
|
5555
|
-
var _approve = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function
|
|
5556
|
-
return runtime_1.wrap(function
|
|
5595
|
+
var _approve = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee10(amount) {
|
|
5596
|
+
return runtime_1.wrap(function _callee10$(_context10) {
|
|
5557
5597
|
while (1) {
|
|
5558
|
-
switch (
|
|
5598
|
+
switch (_context10.prev = _context10.next) {
|
|
5559
5599
|
case 0:
|
|
5560
|
-
return
|
|
5600
|
+
return _context10.abrupt("return", this.env.ply.connect(this._networkConnection.signer).approve(this.env.plygame.address, amount.rawAmount()));
|
|
5561
5601
|
|
|
5562
5602
|
case 1:
|
|
5563
5603
|
case "end":
|
|
5564
|
-
return
|
|
5604
|
+
return _context10.stop();
|
|
5565
5605
|
}
|
|
5566
5606
|
}
|
|
5567
|
-
},
|
|
5607
|
+
}, _callee10, this);
|
|
5568
5608
|
}));
|
|
5569
5609
|
|
|
5570
5610
|
function approve(_x6) {
|