-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
closes wwosimulation/tracker/issues/583 #406
base: main
Are you sure you want to change the base?
Conversation
@@ -11,7 +11,7 @@ module.exports = { | |||
const players = db.get(`players`) | |||
let player = db.get(`player_${message.author.id}`) || { status: "Dead" } | |||
|
|||
if (!message.channel.name.startsWith("priv")) return // if they are not in the private channel | |||
if (!message.channel.parentId == "892046231516368906") return // if they are not in the private channel |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
magic number (or more like string but ya get what i mean)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
really important considering it repeats in so many locations
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also good practice ig
@@ -19,7 +19,7 @@ module.exports = { | |||
.replace(/@here/g, "here") | |||
.replace(/<([@#])+[&]?[\d]{10,20}>/g, "[ping]") | |||
|
|||
if (message.channel.name.startsWith("priv")) { | |||
if (message.channel.parentId == "892046231516368906") { | |||
if (!["Jailer", "Medium", "Ritualist", "Alpha Werewolf", "Sect Leader", "Instigator"].includes(player.role) && !["Jailer", "Medium", "Ritualist", "Alpha Werewolf", "Sect Leader", "Instigator"].includes(player.dreamRole)) return |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
honestly the if's one after another are suffocating each other NL plz?
@@ -372,7 +375,7 @@ module.exports = { | |||
|
|||
let guy = await interaction.guild.members.fetch(player) | |||
|
|||
let channel = await interaction.guild.channels.create(`priv-${roleData.name.toLowerCase().replace(/\s/g, "-")}`, { | |||
let channel = await interaction.guild.channels.create(index + 1 + "-" + guy.user.username, { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
voodoo? why the plus one there
closes wwosimulation/tracker/issues/583
closes wwosimulation/tracker/issues/580