Initial commit

This commit is contained in:
nin0 2024-11-29 21:31:42 -05:00
commit 86453daede
No known key found for this signature in database
5 changed files with 222 additions and 0 deletions

32
Sources/Bot.swift Normal file
View file

@ -0,0 +1,32 @@
import DDBKit
@main
struct FjAdminBot: DiscordBotApp {
init() async {
let httpClient = HTTPClient()
bot = await BotGatewayManager(
eventLoopGroup: httpClient.eventLoopGroup,
httpClient: httpClient,
token: "MTMxMTY2NTg1OTQ3NTAxMzY1Mg.GgVETf.KbMqaqPhOR3JMNT-GiWT3qwiK862cbbjZm9RTc",
largeThreshold: 250,
presence: .init(activities: [], status: .online, afk: false),
intents: [.messageContent, .guildMessages]
)
cache = await .init(
gatewayManager: bot,
intents: .all,
requestAllMembers: .enabledWithPresences,
messageCachingPolicy: .saveEditHistoryAndDeleted
)
}
var body: [any BotScene] {
ReadyEvent { ready in
print("hi mom")
}
}
var bot: Bot
var cache: Cache
}

View file