elightcap / blackmail

0 stars 0 forks source link

Channel creation flow #20

Closed effinowen closed 3 years ago

effinowen commented 3 years ago

!build "name" - creates a text channel with name, assigns user as the owner of the channel in database !privatization - checks for users to see what channel they are the owner of, sets @everyone role in users channel to No View access, creates a new server role called "@username's channel", gives "@username's channel" role the View access to the channel. Assigns role to user who used !privatization. Logs @role name to database under that channels entry !userinvite @name - Checks database for user to see if they own a channel, if they do pull the @role name from the database listed under their channel and add role to the @name invited

effinowen commented 3 years ago

Users start with @Home Seeker role, users buy Constructions item -> users gain Home Builder role -> users do !build and it creates channel, logs them as the owner, removes Home Builder role and grants Home Owner role

elightcap commented 3 years ago

link to #18

effinowen commented 3 years ago

When channel gets nuked, remove all users from that channels assigned role To regain access to channel, users buy cleanup item, get the @cleanup role and then use !cleanup !cleanup - reassigns owner to their channels role

effinowen commented 3 years ago

Issue with !cleanup idea at the moment, when a user gets nuked and they get removed from their custom role for their custom channel, the user will still have @home owner which would enable the !invite command still, not sure how to deal with that at the moment as they might be able to !invite @themselves as well as everyone back without having to buy the !cleanup command

effinowen commented 3 years ago

Also, currently channels are created without adding Poker bot or Unbelievaboat to the channel, only cashier is being added so users are unable to use any commands Workaround: Users can manually invite the bots to their channel still with !invite @unbelievaboat Total fix: As part of channel creation, add unbelievaboat and poker bot to the channel permissions with view access

effinowen commented 3 years ago

Maybe the !cleanup issue could be resolved like so: When !nuke #channel happens, add @home destroyed role to owner of channel If user tries !invite, check for @homedestroyed role, if exists then say you must cleanup your property first Cleanup item when bought removes the @homedestroyed role automatically and adds the @cleanup role, user does !cleanup to add themselves back to the custom channel role and remove the @cleanup role

effinowen commented 3 years ago

Created a flow chart in discord as a reference, created an @Home Destroyed role Pretty much all that would need to be changed for how I can imagine it working would be adding the @home destroyed to the owner of the channel that gets nuked as well as setting the @eveyone view permission to off when a channel is nuked, this helps resolve the issue of how to handle nuking public channels that have not yet been !privatized as it will force those channel owners to still purchase a !cleanup to re-enable the channel, and then making !invite check for the @home destroyed role and if it exists to deny the usage of !invite.