aboutsummaryrefslogtreecommitdiff
path: root/webAO/client/sender/sendCharacter.ts
blob: 5e8172752f35cf98dc21fcc0fa7c28071f06383a (plain)
1
2
3
4
5
6
7
8
9
10
11
import { client } from "../../client";

/**
 * Requests to play as a specified character.
 * @param {number} character the character ID
 */
export const sendCharacter = (character: number) => {
    if (character === -1 || client.chars[character].name) {
        client.sender.sendServer(`CC#${client.playerID}#${character}#web#%`);
    }
}