We now have a Steam Chat Bot!

Discussion in 'Site Discussion' started by Fantasmos, Nov 8, 2015.

  1. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    You read the title right folks, TF2Map’s Steam chat room is getting its very own bot!

    What is a VBOT?
    You may ask, well it’s a user in chat that is 100% controlled by software, this means it can interact with the chat in awesome ways, such as keeping the chat updated with server status or having it's own commands!

    As of right now it can be accessed via our Steam and Discord chatrooms.

    Contributing
    if contributing is your idea or you'd like to run your very own VBot, the github repository is at: https://github.com/TF2Maps/SteamBotLite

    Command list
    VBot's command list is constantly changing along with the syntax making tracking it pretty difficult. In order to do this I have included multiple methods to get it directly from VBot:
    • http://vbot.site/ Will display all commands
    • The !commandlist command will send all commands to the user
    Important Commands for Admins
    VBot has some important commands that admins can utilise to configure the Bot and ensure it functions properly.

    General Commands
    • !reboot -Resets the connection
    • !Rejoin -Leaves and enters chat
    • !WebsiteReboot -Reboots the web server
    Module Commands
    By enabling and disabling modules, Admins can prevent the bot acting upon messages it receives within the module.
    However:
    • The bot will still run the module's automatic commands in the background (such as posting the MOTD).
    • Upon rebooting the module list reset to default.
    These commands are:
    • !modulelist can be used to show all currently activated modules
    • !moduleremove <modulename> can be used to remove a module, thus deactivating it (CASE SENSITIVE)
    • !moduleadd <modulename> can be used to re-add a module, no duplicates allowed
    Keep in mind the bot will not respond immediately confirming/denying if it was deleted/added, so you'll have to check yourself

    The modules are (all load on boot):
    • MotdModule
    • MapModule
    • IdentityModule
    • MapWeberver
    • CountdownModule
    • ServerListModule
    • UsersModule (Undeletable)
    • RepliesModule
    • AdminModule (Undeletable)
    • SearchModule
    • ServerModule
    Imp Commands

    The bot also has commands and functions to help with the running of imps, these are:

    !ADD <Map Name> <DownloadURL> <notes> Adds the map and download url to the map list, a download URL is required even if the map is already uploaded to the servers, and everything after will be added as notes, if your map is over 50mb please specify this in the notes

    !maps posts a list of maps to the chat, and messages the sender the download urls

    !wipe (ADMIN ONLY) Clears the map list

    !delete <mapname> removes the map from the list, can only be done by the original sender or an admin.

    !update <Current Entry> <New Map name> <New url> <New Notes>​

    These commands will help users who want to have their map imp’d but are unable to be in chat all the time, as Imp-Hosters will be able to check the map list for maps people have requested.

    Rules
    So there are some rules and punishments relating to bot-interaction:
    • Spamming Bot-Commands is equivalent to spamming Chat and will be treated accordingly
    • Do not ethically misuse the Any Command (bugs included), you may become blacklisted meaning you can no longer use ANY bot feature
    • If there is a command that is admin-only but a bug allows you to use it, do not use it and report it to this thread, you will become blacklisted for continued abuse
    What to discuss in this thread
    So, this thread will serve as a way for users to have any questions they have answered, as well as request for bot-features or report bugs.

    This thread will also be used to keep users updated about the bot's updates, like a map workshop... but for a bot.

    Thanks to:
    Layl + PuffBit: Helping out with a lot of the coding, a gigantic thanks for all the help provided.

    Fubar + Psy: Significant production on the bot


    Geit:
    Hosting the bot on his server during its initial year, and showing me the ins and outs of running the server, as well as helping with complicated coding issues. Without Geit's help this would not have got to the point it's at now.

    Yrr: Continuously contributing useful feedback to the bot
     
    • Thanks Thanks x 18
    • Useful Useful x 8
    • Creative Creative x 2
    Last edited: Mar 3, 2017
  2. JMaxchill

    JMaxchill L5: Dapper Member

    Messages:
    220
    Positive Ratings:
    64
    Is it possible for a player to remove their map from the list to imp; if they found a game-breaking bug, say?
    e: Also, can we have a !bot command that links to this post if people don't know which commands do which?
     
    • Agree Agree x 1
    Last edited: Nov 9, 2015
  3. Hyperion

    aa Hyperion L16: Grid Member

    Messages:
    679
    Positive Ratings:
    444
    Something like !imp remove would be nice if you mistype yours map name
     
    • Agree Agree x 3
  4. YM

    aa YM LVL100 YM

    Messages:
    7,079
    Positive Ratings:
    5,680
    Does it check that a map is on the server??

    Could easily do so by polling http://redirect.tf2maps.net/maps/ for the filename added to the imp.

    IMHO the !imp command should firs check there and then do two things:
    1. If the map is present, add it to the list of !maps command
    2. If it isn't, return something like "Use the !upload command with a URL to add to the upload queue" then people can use the !upload command with no URL after it to return the full list of maps to upload.
    This way, if someone has a map but it isn't uploaded, the imp host knows A) that it needs to be uploaded and B) the link to get the map in order to upload it.

    I forsee situations where an imp host does !maps and gets a bunch of maps that aren't uploaded as a result.

    Please also add a "!OopsIFuckedUp command so that people can remove their fuck up from the map list. You're tracking steamIDs so you should be able to do some kind of system where users can undo a typo into the imp list without needing an admin to clear it entirely.

    Aaaalallllssooo !help should return the URL of this thread.

    Just one more request: adding "quiet" or some similar keyword into the bot's command should prevent it from returning anything to the chat so that people can use multiple commands in quick succession if needs be without spamming up chat.

    Finally: Ban non-group members from using the bot.
     
    • Agree Agree x 5
    • Useful Useful x 1
  5. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    What it does is let users put in their own text, so they could do !imp Koth_backwoods <dropbox link>

    I'm planning on redoing the imp system soon, and will definitely add these features
     
  6. worMatty

    aa worMatty Repacking Evangelist

    Messages:
    1,029
    Positive Ratings:
    793
    Do we clear the map list after each imp or is it good practice to leave the maps on there for 24 hours so they can be in more than one imp, say one EU and one US? Do the maps expire automatically? If not, then we could do that and we wouldn't have to clear the list, but it would also mean that the two sets of regional server users would playtest a map, and the author wouldn't need to be around to make sure it stays on the list.
     
  7. YM

    aa YM LVL100 YM

    Messages:
    7,079
    Positive Ratings:
    5,680
    Nah don't do that, that ability is getting used for the powers of evil and foolishness:
     
  8. LeSwordfish

    aa LeSwordfish semi-trained quasi-professional

    Messages:
    3,892
    Positive Ratings:
    4,915
    I've already commented my disappointment that you can't add "maps" privately so as to leave a entire-bee-movie-script timebomb.
     
    • Like Like x 1
  9. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    Sweet, people are using the bot (gotta really clean the system though)

    Anyways bot update:

    Mostly internal stuff, I can now read and comment in chat through the bot, which is good (can do it on mobile as well) !clear works now (admin only still) and that's really it. I won't be in the bot chat 24/7 obviously though.
     
  10. Osspial

    Osspial L2: Junior Member

    Messages:
    63
    Positive Ratings:
    71
    It might be nice for people to be able to type multiple commands into one line of chat by separating them with semicolons.
     
    • Agree Agree x 1
  11. MegapiemanPHD

    MegapiemanPHD Doctorate in Deliciousness

    Messages:
    729
    Positive Ratings:
    270
    Would it be possible to include a "add to imp" function on TF2maps.net's website (if it's not already there)? I'm not one for public chats.
     
    • Agree Agree x 1
  12. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    So, the current system i'm considering, is when a !maps command is done, it will post the map list to chat, and PM the download links to the sender. I'm also considering making this command work when directly messaging the bot so 5 people don't spam to get download links. Thoughts?

    Edit: What about google sheets?
     
    • Thanks Thanks x 1
    Last edited: Nov 10, 2015
  13. Sergis

    aa Sergis L666: ])oo]v[

    Messages:
    1,857
    Positive Ratings:
    1,117
    if that thing can be taught to check if a map is on redirect, oops a typo command becomes obsolete

    unless of course someone has made and uploaded a map with your exact typo
     
  14. LeSwordfish

    aa LeSwordfish semi-trained quasi-professional

    Messages:
    3,892
    Positive Ratings:
    4,915
    Also it's useful to add maps that aren't uploaded.
     
  15. JMaxchill

    JMaxchill L5: Dapper Member

    Messages:
    220
    Positive Ratings:
    64
  16. worMatty

    aa worMatty Repacking Evangelist

    Messages:
    1,029
    Positive Ratings:
    793
    Suggestion: Number each map as it's added to the list. For example, using the !maps command would show a list like this:

    1. cp_tekton_a8 , 2. cp_shortpeak_a6 , 3. cp_alpine_a3 , 4. http://tf2maps.net/resources/cp_intrusion.832/ , 5. cp_mard_a1c , 6. koth_overflow_b5 , 7. cp_pillowcase_a4 , 8. cp_bridgework_a2 , 9. cp_alpine_a3 if we dont have enough maps , 10. cp_bridgework_a2 http://tf2maps.net/resources/bridgework.926/ ,

    The reasons for this are:
    • You can tell at a glance just how many maps there are to be play tested
    • It would make identification and selection easier if there was a map deletion command introduced in future. The staff user could just type !delete 3 for example.
    • It helps separate the entries to make them more readable and prevents URLs and comments from spilling over in to adjacent entries.
    Thanks!
     
    • Agree Agree x 4
  17. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    The new imp system is on the road to being implemented!

    To begin using the system I encourage the following commands

    !add <mapname> <downloadURL> (Gets the map list
    !remove <Mapname> (only usable by the person who added the map and admins)
    !view (post the map list to chat and pm's the URL list, this is a temporary solution, the improvement will be awesome)
    !wipe (Removes all map from the list)

    I've been definitely reading this thread, and this new system will allow me to properly cater to these requests. Gotta just get the major components (these) cleaned up. The current system is going to be running parallel with this system, just so users don't get confused.
     
    • Thanks Thanks x 2
    • Like Like x 1
  18. LeSwordfish

    aa LeSwordfish semi-trained quasi-professional

    Messages:
    3,892
    Positive Ratings:
    4,915
    This may have already come up, but what about being able to check if a map is uploaded? !check koth_gunfight_a6 or something.
     
  19. Fantasmos

    aa Fantasmos

    Messages:
    838
    Positive Ratings:
    888
    Yeah, definitely been interested in doing this, and it's 100% feasible. I want to implement the google sheet system first though but this is 2nd on my list because it ties into my surprise feature.
     
    • Like Like x 1
  20. Davekillerish

    aa Davekillerish Lvl 1: Respectfully Disagree'd Member

    Messages:
    1,405
    Positive Ratings:
    749
    I love the bot, keep working on it, its an amazing addition to the community as a whole.
     
    • Agree Agree x 2
    • Like Like x 1