@twitchfy/chatbot
Version:
A powerful node module to make your own Twitch ChatBot
27 lines (26 loc) • 841 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ChatBotUser = void 0;
const User_1 = require("./User");
/**
* Represents a Twitch chatbot user.
*/
class ChatBotUser extends User_1.User {
/**
* Creates a new instance of the chatbot user.
* @param chatbot The current instance of the chatbot.
* @param data The data of the user returned from the API.
*/
constructor(chatbot, data) {
super(chatbot, data);
}
/**
* Sets the name color of the chatbot user which will be visible in the chat.
* @param color The color of the name. This can be a hex color code or a color name.
* @returns
*/
async setNameColor(color) {
return await this.chatbot.helixClient.updateUserColor(this.id, color);
}
}
exports.ChatBotUser = ChatBotUser;