mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-17 08:20:58 -05:00
Compare commits
2 Commits
4dc5d236ce
...
d9da63e1f8
Author | SHA1 | Date | |
---|---|---|---|
|
d9da63e1f8 | ||
|
8983990f16 |
@ -1,5 +1,5 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<img width="450" height="270" src="https://cdn.discordapp.com/attachments/1015195575693627442/1081877631068295178/DaggerwinServerBanner2023.gif">
|
<img width="650" height="240" src="https://cdn.discordapp.com/attachments/1118960531135541318/1151036641717260348/Daggerbot-TS-repo.gif">
|
||||||
<h1 align="center">Daggerbot-TS Description</h1>
|
<h1 align="center">Daggerbot-TS Description</h1>
|
||||||
<p align="center">
|
<p align="center">
|
||||||
This is a 1st generation bot that is a TypeScript-based Daggerbot converted from JavaScript at <s><a href="https://github.com/SpaceManBuzz/DaggerBot-">SpaceManBuzz/DaggerBot-</a></s> (now archived and privated)
|
This is a 1st generation bot that is a TypeScript-based Daggerbot converted from JavaScript at <s><a href="https://github.com/SpaceManBuzz/DaggerBot-">SpaceManBuzz/DaggerBot-</a></s> (now archived and privated)
|
||||||
|
@ -12,7 +12,6 @@ import {FSPlayer, FSData, FSCareerSavegame} from '../typings/interfaces';
|
|||||||
export default async(client:TClient, Channel:string, Message:string, Server:TServer, ServerName:string)=>{
|
export default async(client:TClient, Channel:string, Message:string, Server:TServer, ServerName:string)=>{
|
||||||
let isServerOnline = false;
|
let isServerOnline = false;
|
||||||
let playerData:Array<string> = [];
|
let playerData:Array<string> = [];
|
||||||
let noContentImage = 'https://cdn.discordapp.com/attachments/1118960531135541318/1140906691236479036/68efx1.png';
|
|
||||||
const msg = await (client.channels.resolve(Channel) as Discord.TextChannel).messages.fetch(Message);
|
const msg = await (client.channels.resolve(Channel) as Discord.TextChannel).messages.fetch(Message);
|
||||||
const serverErrorEmbed = new client.embed().setColor(client.config.embedColorRed).setTitle('Host did not respond back in time');
|
const serverErrorEmbed = new client.embed().setColor(client.config.embedColorRed).setTitle('Host did not respond back in time');
|
||||||
const genericEmbed = new client.embed();
|
const genericEmbed = new client.embed();
|
||||||
@ -25,7 +24,6 @@ export default async(client:TClient, Channel:string, Message:string, Server:TSer
|
|||||||
|
|
||||||
if (!hitDSS ?? !hitCSG){
|
if (!hitDSS ?? !hitCSG){
|
||||||
if (hitDSS && !hitDSS.slots) return console.log(LogPrefix('MPModule'), `DSS failed with unknown slots table for ${client.MPServerCache[ServerName].name}`);
|
if (hitDSS && !hitDSS.slots) return console.log(LogPrefix('MPModule'), `DSS failed with unknown slots table for ${client.MPServerCache[ServerName].name}`);
|
||||||
if (hitDSS && !hitCSG) return msg.edit({content: 'No savegame found or autosave has ran.', embeds: [genericEmbed.setColor(client.config.embedColorOrange).setImage(noContentImage)]});
|
|
||||||
else return msg.edit({embeds: [serverErrorEmbed]});
|
else return msg.edit({embeds: [serverErrorEmbed]});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user