Raised This Month: $51 Target: $400
 12% 

QuizEngine


Post New Thread Reply   
 
Thread Tools Display Modes
Author
recon0
Veteran Member
Join Date: Sep 2007
Location: US
Plugin ID:
520
Plugin Version:
1.3
Plugin Category:
Server Management
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Quizzes players on connection to a SRCDS server.
    Old 08-24-2008 , 04:23   QuizEngine
    Reply With Quote #1

    *** 1.3 Released ***

    This plugin was designed for games that require teamwork and extensive knowledge.

    In those types of games (most are MODs), there are generally two groups of people. People who are new to the game, and experienced players. Sometimes experienced players want to play somewhere with other experienced players. This plugin is basically as a filter so that servers could be created for experienced players only.

    This plugin was designed for EmpiresMod, a FPS / RTS hybrid by a member of that community. A first attempt at coding a plugin was not completed. I then took over the position of lead (and only) coder and wrote this plugin from scratch.

    Features

    Asks a configurable number of random questions from the questions.cfg KV file.

    Kicks / bans (configurable) users for failing to answer a quesiton or for failing to complete the quiz in the required amount of time (configurable).

    When a user completes the quiz, their SteamIDs is stored in a SQLite or MySQL database. The current date is also stored. When they reconnect, they will not be quized again. The last connected date will be updated.

    The above database is automatically pruned once a day by the plugin. All records with a last connected date older then 20 days will removed from the database.

    Installation
    Copy Files
    • addons/sourcemod/configs/quizengine/questions.cfg
    • addons/sourcemod/configs/quizengine/settings.cfg
    • addons/sourcemod/plugins/quizengine.smx
    Edit Config Files
    • questions.cfg
      • Add your own questions
    • settings.cfg
      • Read the file for details
    Database.cfg
    For SQLite add to addons/sourcemod/configs/databases.cfg before the last }

    Code:
     
    "quizengine"
    {
            "driver"            "sqlite"
            "database"          "quizengine"
    }
    For MySQL create a user and database. Grant all permissions for that database to a user. Allow that user to connect to MySQL from your game server.

    Add to addons/sourcemod/configs/databases.cfg before the last }

    Code:
    "quizengine"
    {
         "driver"            "mysql"
         "host"              "mysqlserver"
         "database"          "databasename"
         "user"              "username"
         "pass"              "password"
         //"timeout"         "0"
         //"port"            "0"
    }
    Common Errors
    • If you forget to close a quote in one of the KV files, it will fail to parse and most likely, the plugin will not run correctly.
    • If you get blank questions, make sure the value of totalQuestions (in settings.cfg) is set to the value of the last section (so if you had 30 questions, totalQuestions would be 29).
    Changelog
    • 1.0
      • First public release
    • 1.1
      • Fixed grammar error (whoops)
    • 1.2
      • Connect message now configurable from settings.cfg
      • The number of times connect message is sent is configurable from settings.cfg
      • Quiz pass message now configurable from settings.cfg
      • Quiz pass message can be configured to broadcast to all players
      • The max age of a quiz pass record is now configurable from settings.cfg
    • 1.3
      • DB pruning can now be disabled by setting maxQuizRecordAge to -1
      • CS:S radio style menus can be forced by setting forceRadioMenu to 1 (not currently working, leave the setting as is)
    • v.Next
      • Turn filter mode off
        • Option for no punishment for failing a quiz or timing out
        • Option to disable saving user info if the user passes a quiz
      • Start quiz every x number of rounds
        • Once one user completes the quiz, all other quizes are canceled - config option
      • Reward user on completion of the quiz (reward.cfg file will allow you to define what you would like to give the user with standard server commands probably)
    Credits

    Special thanks to Porthos for the original idea and for being an excellent tester.

    Special thanks to MAD for letting me test on their server.
    Attached Files
    File Type: cfg settings.cfg (2.5 KB, 502 views)
    File Type: cfg questions.cfg (435 Bytes, 671 views)
    File Type: sp Get Plugin or Get Source (quizengine.sp - 1301 views - 17.2 KB)
    __________________

    Last edited by recon0; 09-22-2008 at 17:40.
    recon0 is offline
    DontWannaName
    Veteran Member
    Join Date: Jun 2007
    Location: VALVe Land, WA
    Old 08-24-2008 , 05:19   Re: QuizEngine
    Reply With Quote #2

    When you say on connect do you mean when in the server or when its loading the map?
    __________________

    DontWannaName is offline
    willy1234x1
    Senior Member
    Join Date: Jun 2008
    Old 08-24-2008 , 05:40   Re: QuizEngine
    Reply With Quote #3

    Alright looking plug-in I'd personally edit it so players can type !quiz between spawns and have a fun quiz that I can post once a week.
    willy1234x1 is offline
    recon0
    Veteran Member
    Join Date: Sep 2007
    Location: US
    Old 08-24-2008 , 05:45   Re: QuizEngine
    Reply With Quote #4

    Quote:
    Originally Posted by willy1234x1 View Post
    Alright looking plug-in I'd personally edit it so players can type !quiz between spawns and have a fun quiz that I can post once a week.
    Good idea.

    Quote:
    Originally Posted by DontWannaName View Post
    When you say on connect do you mean when in the server or when its loading the map?
    After the map loads and the player is fully in game.
    __________________

    Last edited by recon0; 08-24-2008 at 05:48.
    recon0 is offline
    recon0
    Veteran Member
    Join Date: Sep 2007
    Location: US
    Old 08-24-2008 , 19:43   Re: QuizEngine
    Reply With Quote #5

    *** Bump

    1.2 Released
    __________________
    recon0 is offline
    willy1234x1
    Senior Member
    Join Date: Jun 2008
    Old 08-24-2008 , 22:50   Re: QuizEngine
    Reply With Quote #6

    Any possibility of my suggestion coming in?
    Like maybe adding a quiz_type variable where 1 is the current method and 0 is fun one?
    willy1234x1 is offline
    recon0
    Veteran Member
    Join Date: Sep 2007
    Location: US
    Old 08-24-2008 , 23:25   Re: QuizEngine
    Reply With Quote #7

    Quote:
    Originally Posted by willy1234x1 View Post
    Any possibility of my suggestion coming in?
    Like maybe adding a quiz_type variable where 1 is the current method and 0 is fun one?
    Probably in the next version.
    __________________
    recon0 is offline
    YellowCakeKlan
    Junior Member
    Join Date: Aug 2008
    Old 08-25-2008 , 00:23   Re: QuizEngine
    Reply With Quote #8

    I would like to see a quiz type plugins that awards players for getting the question right, like 50 extra health, 25% speed increase, 30% lower gravity, etc.

    It would ask all players the question, and the first player to answer it wins, and gets the award.

    This quiz question would pop up once per round, or once every 5 rounds, or whatever, depending on a cvar.

    that would be the best plugin evar and I'm personally willing to mail a check for $1,000 to anyone that can make it.
    YellowCakeKlan is offline
    willy1234x1
    Senior Member
    Join Date: Jun 2008
    Old 08-25-2008 , 00:50   Re: QuizEngine
    Reply With Quote #9

    Quote:
    Originally Posted by YellowCakeKlan View Post
    I would like to see a quiz type plugins that awards players for getting the question right, like 50 extra health, 25% speed increase, 30% lower gravity, etc.

    It would ask all players the question, and the first player to answer it wins, and gets the award.

    This quiz question would pop up once per round, or once every 5 rounds, or whatever, depending on a cvar.

    that would be the best plugin evar and I'm personally willing to mail a check for $1,000 to anyone that can make it.
    I don't think that one would work well with anything except CS:S. I'd want to create a 50 question quiz or something else and whoever can answer all of them get's their name and steam ID written to a file or MySQL DB so I can give them a reserved slot.
    willy1234x1 is offline
    recon0
    Veteran Member
    Join Date: Sep 2007
    Location: US
    Old 08-25-2008 , 03:12   Re: QuizEngine
    Reply With Quote #10

    Quote:
    Originally Posted by YellowCakeKlan View Post
    I would like to see a quiz type plugins that awards players for getting the question right, like 50 extra health, 25% speed increase, 30% lower gravity, etc.

    It would ask all players the question, and the first player to answer it wins, and gets the award.

    This quiz question would pop up once per round, or once every 5 rounds, or whatever, depending on a cvar.

    that would be the best plugin evar and I'm personally willing to mail a check for $1,000 to anyone that can make it.
    Quote:
    Originally Posted by willy1234x1 View Post
    I don't think that one would work well with anything except CS:S. I'd want to create a 50 question quiz or something else and whoever can answer all of them get's their name and steam ID written to a file or MySQL DB so I can give them a reserved slot.
    For willy's idea to work, someone would have to build a little plugin to add users to a reserved slot file from a server command.

    Do you guys like what you see in the changelog for v.Next?
    __________________

    Last edited by recon0; 08-25-2008 at 03:35.
    recon0 is offline
    Reply



    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 03:22.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode