transformice.js
Version:
Node.js client for Transformice with full Typescript support.
50 lines (49 loc) • 1.14 kB
TypeScript
import { ValueOf, ByteArray } from "../utils";
import { genders } from "../enums";
import Client from "../client";
import Player from "./Player";
/** Represents a friend from the friend list */
export default class Friend extends Player {
/**
* The player's id
*/
id: number;
/**
* The player's gender
*/
gender: ValueOf<typeof genders>;
/**
* If the player is the soulmate of the client
*/
isSoulmate: boolean;
/**
* If the player has added the client back
*/
hasAddedBack: boolean;
/**
* If the player is connected
*/
isConnected: boolean;
/**
* The community of the player
*/
community: number;
/**
* The room name of the player (if they are online)
*/
roomName: string;
/**
* The player's last connection time
*/
lastConnection: number;
/**
* @hidden
*/
constructor(client: Client);
/**
* Returns friend data from a packet
*
* @hidden
*/
read(packet: ByteArray, isSoulmate: boolean): this;
}