diff --git a/src/actions/createModActionTicket.ts b/src/actions/createModActionTicket.ts
index 481666b..d6e9cd9 100644
--- a/src/actions/createModActionTicket.ts
+++ b/src/actions/createModActionTicket.ts
@@ -6,7 +6,7 @@
 
 export async function create(
     guild: Discord.Guild,
-    member: Discord.User,
+    user: Discord.User,
     createdBy: Discord.User,
     reason: string | null,
     customReason?: string
@@ -14,7 +14,7 @@
     const config = await client.database.guilds.read(guild.id);
     const { log, NucleusColors, entry, renderUser, renderChannel, renderDelta } = client.logger;
     const overwrites = [{
-        id: member,
+        id: user,
         allow: ["ViewChannel", "SendMessages", "AttachFiles", "AddReactions", "ReadMessageHistory"],
         type: OverwriteType.Member
     }] as unknown as Discord.OverwriteResolvable[];
@@ -30,78 +30,146 @@
             type: OverwriteType.Role
         });
     }
+    const targetChannel: Discord.CategoryChannel | Discord.TextChannel = (await guild.channels.fetch(config.tickets.category!))! as Discord.CategoryChannel | Discord.TextChannel;
 
-    let c;
-    try {
-        c = await guild.channels.create({
-            name: member.username,
-            type: ChannelType.GuildText,
-            topic: `${member.id} Active`,
-            parent: config.tickets.category,
-            nsfw: false,
-            permissionOverwrites: overwrites as Discord.OverwriteResolvable[],
-            reason: "Creating ticket"
-        });
-    } catch (e) {
-        return null;
-    }
-    try {
-        await c.send({
-            content:
-                `<@${member.id}>` + (config.tickets.supportRole !== null ? ` • <@&${config.tickets.supportRole}>` : ""),
-            allowedMentions: {
-                users: [member.id],
-                roles: config.tickets.supportRole !== null ? [config.tickets.supportRole] : []
+    let c: Discord.TextChannel | Discord.PrivateThreadChannel;
+    if (targetChannel.type === Discord.ChannelType.GuildCategory) {
+        const overwrites = [
+            {
+                id: user,
+                allow: ["ViewChannel", "SendMessages", "AttachFiles", "AddReactions", "ReadMessageHistory"],
+                type: Discord.OverwriteType.Member
             }
+        ] as Discord.OverwriteResolvable[];
+        overwrites.push({
+            id: guild.roles.everyone,
+            deny: ["ViewChannel"],
+            type: Discord.OverwriteType.Role
         });
-        await c.send({
-            embeds: [
-                new EmojiEmbed()
-                    .setTitle("New Ticket")
-                    .setDescription(
-                        "Ticket created by a Moderator\n" +
+        if (config.tickets.supportRole !== null) {
+            overwrites.push({
+                id: guild.roles.cache.get(config.tickets.supportRole)!,
+                allow: ["ViewChannel", "SendMessages", "AttachFiles", "AddReactions", "ReadMessageHistory"],
+                type: Discord.OverwriteType.Role
+            });
+        }
+
+        try {
+            c = await guild.channels.create({
+                name: `${user.username.toLowerCase()}`,
+                type: ChannelType.GuildText,
+                topic: `${user.id} Active`,
+                parent: config.tickets.category,
+                nsfw: false,
+                permissionOverwrites: overwrites as Discord.OverwriteResolvable[],
+                reason: "Creating ticket"
+            });
+        } catch (e) {
+            return null;
+        }
+        try {
+            await c.send({
+                content:
+                    `<@${user.id}>` +
+                    (config.tickets.supportRole !== null ? ` • <@&${config.tickets.supportRole}>` : ""),
+                allowedMentions: {
+                    users: [user.id],
+                    roles: config.tickets.supportRole !== null ? [config.tickets.supportRole] : []
+                }
+            });
+            await c.send({
+                embeds: [
+                    new EmojiEmbed()
+                        .setTitle("New Ticket")
+                        .setDescription(
+                            "Ticket created by a Moderator\n" +
                             `**Support type:** ${customReason ? customReason : "Appeal submission"}\n` +
                             (reason !== null ? `**Reason:**\n> ${reason}\n` : "") +
                             `**Ticket ID:** \`${c.id}\`\n` +
                             `Type ${await getCommandMentionByName("ticket/close")} to close this ticket.`
-                    )
-                    .setStatus("Success")
-                    .setEmoji("GUILD.TICKET.OPEN")
-            ],
-            components: [
-                new ActionRowBuilder<Discord.ButtonBuilder>().addComponents([
-                    new ButtonBuilder()
-                        .setLabel("Close")
-                        .setStyle(ButtonStyle.Danger)
-                        .setCustomId("closeticket")
-                        .setEmoji(getEmojiByName("CONTROL.CROSS", "id"))
-                ])
-            ]
-        });
-        const data = {
-            meta: {
-                type: "ticketCreate",
-                displayName: "Ticket Created",
-                calculateType: "ticketUpdate",
-                color: NucleusColors.green,
-                emoji: "GUILD.TICKET.OPEN",
-                timestamp: new Date().getTime()
-            },
-            list: {
-                ticketFor: entry(member.id, renderUser(member)),
-                createdBy: entry(createdBy.id, renderUser(createdBy)),
-                created: entry((new Date().getTime()).toString(), renderDelta(new Date().getTime())),
-                ticketChannel: entry(c.id, renderChannel(c))
-            },
-            hidden: {
-                guild: guild.id
-            }
-        };
-        log(data);
-    } catch (e) {
-        console.log(e);
-        return null;
+                        )
+                        .setStatus("Success")
+                        .setEmoji("GUILD.TICKET.OPEN")
+                ],
+                components: [
+                    new ActionRowBuilder<ButtonBuilder>().addComponents([
+                        new ButtonBuilder()
+                            .setLabel("Close")
+                            .setStyle(ButtonStyle.Danger)
+                            .setCustomId("closeticket")
+                            .setEmoji(getEmojiByName("CONTROL.CROSS", "id"))
+                    ])
+                ]
+            });
+        } catch (e) {
+            return null;
+        }
+    } else {
+        c = await targetChannel.threads.create({name: `${user.username} - ${user.id} - Active`,
+                                                autoArchiveDuration: 60 * 24 * 7,
+                                                type: Discord.ChannelType.PrivateThread,
+                                                reason: "Creating ticket"
+                                                }) as Discord.PrivateThreadChannel;
+        c.members.add(user.id);
+        c.members.add(createdBy.id);
+        try {
+            await c.send({
+                content:
+                    `<@${user.id}>` +
+                    (config.tickets.supportRole !== null ? ` • <@&${config.tickets.supportRole}>` : ""),
+                allowedMentions: {
+                    users: [user.id],
+                    roles: config.tickets.supportRole !== null ? [config.tickets.supportRole] : []
+                }
+            });
+            await c.send({
+                embeds: [
+                    new EmojiEmbed()
+                        .setTitle("New Ticket")
+                        .setDescription(
+                            "Ticket created by a Moderator\n" +
+                            `**Support type:** ${customReason ? customReason : "Appeal submission"}\n` +
+                            (reason !== null ? `**Reason:**\n> ${reason}\n` : "") +
+                            `**Ticket ID:** \`${c.id}\`\n` +
+                            `Type ${await getCommandMentionByName("ticket/close")} to close this ticket.`
+                        )
+                        .setStatus("Success")
+                        .setEmoji("GUILD.TICKET.OPEN")
+                ],
+                components: [
+                    new ActionRowBuilder<ButtonBuilder>().addComponents([
+                        new ButtonBuilder()
+                            .setLabel("Close")
+                            .setStyle(ButtonStyle.Danger)
+                            .setCustomId("closeticket")
+                            .setEmoji(getEmojiByName("CONTROL.CROSS", "id"))
+                    ])
+                ]
+            });
+        } catch (e) {
+            return null;
+        }
     }
+    const data = {
+        meta: {
+            type: "ticketCreate",
+            displayName: "Ticket Created",
+            calculateType: "ticketUpdate",
+            color: NucleusColors.green,
+            emoji: "GUILD.TICKET.OPEN",
+            timestamp: new Date().getTime()
+        },
+        list: {
+            ticketFor: entry(user.id, renderUser(user)),
+            createdBy: entry(createdBy.id, renderUser(createdBy)),
+            created: entry((new Date().getTime()).toString(), renderDelta(new Date().getTime())),
+            ticketChannel: entry(c.id, renderChannel(c))
+        },
+        hidden: {
+            guild: guild.id
+        }
+    };
+    log(data);
     return c.id;
 }
 
