27 lines
564 B
TypeScript
27 lines
564 B
TypeScript
|
import * as PIXI from 'pixi.js';
|
||
|
|
||
|
import './PlayerIOClient.development';
|
||
|
import * as Pio from "./PlayerIOAsync";
|
||
|
|
||
|
PlayerIO.useSecureApiRequests = true;
|
||
|
|
||
|
(async function() {
|
||
|
const cli = await Pio.authenticate(
|
||
|
"kittygame-48om7qu7teeazkf9gana",
|
||
|
"public",
|
||
|
{ userId: "soren" },
|
||
|
[]
|
||
|
);
|
||
|
console.log(cli);
|
||
|
const multiplayer = cli.multiplayer;
|
||
|
console.log(multiplayer);
|
||
|
const rooms = await Pio.listRooms(
|
||
|
multiplayer,
|
||
|
"KittyRpg2",
|
||
|
{},
|
||
|
50,
|
||
|
0
|
||
|
)
|
||
|
console.log(rooms);
|
||
|
})();
|