[ADMN/WEB] OKB3 - Bulletin Board Bridge - Now on BukkitDev! [1337]

Discussion in 'Inactive/Unsupported Plugins' started by Kalman Olah, Jun 2, 2011.

  1. Offline

    Kalman Olah

  2. Offline

    austech360

    Code:
    mode: normal
    mysql-connection-info:
        mysql-host: Host
        mysql-user: USER
        mysql-password: thisisasecret
        mysql-database-name: DB
    old-school-mode:
        usertable: user_table
        minecraftname-field: mine_user
        rank-field: rank_field
        enable-multiple-tables: 'false'
        multitable:
            secondtable: mine_table
            useridfield-in-secondtable: user_id_field
            useridfield-in-usertable: user_id_field
    normal-mode:
        forum: smf
        type1:
            usertable: smf_members
            username-field: member_name
            userpassword-field: passwd
            rank-field: id_group
        type2:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
            location-of-passgenphp: http://yoursite.com/passgen.php
            password-set-in-config-inc-php: 12345pass
        type3:
            usertable: user_table
            rank-field: rank_field
            username-field: username_field
            password-field: pass_field
            secondtable: second_table
            useridfield-in-usertable: user_id_field
            useridfield-in-secondtable: user_id_field
        type4:
            usertable: user_table
            username-field: username
            password-field: mine_user
            rank-field: rank_field
            location-of-passgenphp: http://yoursite.com/passgen.php
            password-set-in-config-inc-php: 12345pass
    world-groups:
        enable-multiworld-groups: 'false'
        default:
            groups:
                '0': Member
                '1': Admin
                '2': Admin
                '9': Moderator
                '10': VIP
        exampleworld1:
            groups:
                '1': ExampleGroup1
                '2': ExampleGroup2
        exampleworld2:
            groups:
                '1': ExampleGroup1
                '2': ExampleGroup2
    whitelist:
        enable-whitelist: 'false'
        global:
            use-as-blacklist: 'false'
            kick-message: This is the message a user will see if their group isn't whitelisted.
            groups:
                '1': 'true'
                '2': 'false'
    nickname-sync:
        enable-nickname-syncing: 'false'
        nickname-field-in-usertable: ''
    forum-banning:
        is-server-ban-too: 'true'
        banned-forum-user-rank-id: '0'
        unbanned-forum-user-rank-id: '10'
        ban-message: Sorry, you are banned..
    promotion-tracks:
        '1': '3'
        '2': '5'
        '3': '16'
    forum-ranks:
        Admin: '1'
        Registered: '0'
        Moderator: '9'
    
    Ok. So. there is my config. skater and I are a team. I did as you said and it still resulted in the same error.


    Code:
    011-07-21 14:57:21 [WARNING] [OKB3] Error at SQL Query: cannot commit transaction - SQL statements in progress
    2011-07-21 14:57:21 [WARNING] [OKB3] Error at SQL Query: query does not return ResultSet
    
     
  3. Offline

    Kalman Olah

    Version 2.5.4

    • Fixed a bug where a player teleporting to a new world wouldn't get his ranks updated the first time.
    • Fixed an issue with login/quit messages displaying when blacklisted/banned users tried to connect. This has been solved by simply removing all login messages, and adding them back where the user isn't banned/whitelisted.
    @austech360
    @Deadlystrike
    Your issues will be looked into tomorrow, or "later" as it is 1 am here.
     
  4. Offline

    ExplosiveBacoN

    Though it still shows the quit message.
     
  5. Offline

    Kalman Olah

    You know, you could've put a smiley face in your post or something. Just plain whining doesn't actually make me want to fix stuff :(.

    Version 2.5.5
    • Possible fix for quit messages still displaying when blacklisted/banned users try to connect.
     
  6. Offline

    Donny

     
  7. Offline

    Kalman Olah

    As in: the quit messages still show?
     
  8. Offline

    Deadlystrike

    the plugin is still losing connection to the sql and not reistablishing it

    could u make it so that upon /sync or /resync if its not connected it will resistablish connection then carry though with command? or proccess?

    i reloaded the server and it established connection upon reboot as it should... somone /synced again and got error spamed with error at sql query dues not match data set and crash

    edit: just rebooted from crash and his rank was sycned upon login but /sync and resync still crashes us

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  9. Offline

    Kalman Olah

    The plugin is trying to keep the connection alive by executing a dummy query every 15 seconds. If your connection is getting closed faster than this:
    - You have a very shitty host
    - I have to know what the timeout timer is
     
  10. Offline

    ExplosiveBacoN

    Unfortunately I have the same problem. :(
     
  11. Offline

    Deadlystrike

    the timer is 30 seconds if inactivity maybe 29 but they said 30
     
  12. Offline

    Kalman Olah

    Updated to v2.5.6
    • Added a config.yml value "mysql-ping-interval" which allows you to set the mysql keepalive ping interval in seconds. Enjoy.

    Also: I'll be gone for much of the weekend, as in: almost no updates, some support, not a lot.
     
  13. Offline

    thernztrom

    Hey Kalman,
    I wonder how the /frank and /fpromote commands work when you are using phpbb3.

    In our phpbb3 forums I've made so that all people that join the forums have the rank Default User. (Witch gives them In-game rank: Default, aka no build rights). Then I've create a new group for every rank we have in-game. All from Member to Smod.
    [​IMG]
    So we mods+ then need to promote Defaults(normal registred members) to the group Member so that they get the Member rank.
    Also look at this: http://img801.imageshack.us/img801/4157/picturepd.png
    It shows the groups I have and what Forum rank respective In-game rank they give.

    So how would /fpromote and /frank work with the forum? Would fpromote change the user's default group? But how would /frank deal with this, since all groups have pre-defined ranks, or is it now possible to change the rank to something else than the default group-rank?

    You see the reason why I'm asking this is because im trying to solve how my Forum Moderators/Super Moderators are going to be able and promote people. (Since we use a Default group&rank where you cant build in-game, and you have to apply for Member-rank on our forums. Then our mods need to be able and move them to the Member group(which will give them Member rank) or change their rank somehow.. :/)
    I havent found a forum soution to it yet, only way to change it as of I know, is to go into the ACP and change a players group, but dont wanna grant all my mods with that. Therefore it'd be great if these commands would work with it.
    Anything special I should take note of when setting up the config if I want the fpromotion/frank to work?

    You maybee have a better solution on how to easily make your Forum mods be able to change ranks of registred members.. :)
    Thanks in advance!
     
  14. Offline

    Kalman Olah

    If you set it up correctly, /fpromote and /fdemote allow your moderators to both promote and demote users along a predefined track, both ingame and on the forums, meaning that ranks are changed on both fronts along a track you can set up. I understand that you don't want moderators promoting people to admins, so there is a limit in place using Permissions to define the last rank moderators can promote users to(using permissions).
    With the /frank command you can map certain forum ranks to certain names. For example, you can map the rank ID '3' to the name 'Moderator'. If you had your moderators use /frank <player> Moderator after this, that player's forum rank would be changed to the RANK ID (3), and his server group would be changed to the the group mapped to the 3 forum rank, using a regular sync.
    If you actually need help setting it up, PM me.
    I'd tell you to just map the mod member rank ID to the name Member in the config.yml, and to give your Moderators the /Frank permission. Alternately, you could make a full promotion/demotion track, and limit your Moderator's to promoting/demoting users to and from the Member rank.
    EDIT: You can use the regular sync group mapping to map the forum rank of accepted players to a Member PErmissions group, and you can make the standard PErmissions group one with no build permissions. This way accepted users will be promoted automatically.

    I probably didn't explain anything at all, I apologize.
    /fpromote & /fdemote & /frank change the field you have set as your rank-field to a value determined by your config.yml settings, meaning that if you map a rank to a RANK ID, the rank-field will be changed to the RANK ID for that player, should you promote him or change his rank using one of the commands. Using phpBB3, there are multiple ways you could handle promoting members to actual Builders. You could set your rank-field to "user_rank", and create a new rank for builders. Ingame, you would use /Frank <player> Builder, after some configuring. This would change their forum ranks to that of the Builder, and based on how your config.yml is set up, they would be put into a different Permissions group. The exact same can be done with group.
    Come to think of it, I probably still didn't answer your question =/.

    EDIT: I think I finally read your actual question.
    The answer: /frank changes the same MYSQL field /fpromote and /fdemote change It's just called /frank because it changes something to something you specificy, while promote/Demote can only promote/demote. If your rankfield is set to the group_id field, it'll still change their default group. So basically, they all change the same thing, and that thing is probably their default group, in your case. Alternately, if you had set the rank-field to "user_rank", the commands would change that field, and as such they would change their ranks, not their default groups.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  15. Offline

    austech360

    Problem isnt fixed. if you start the server, reload plugins, and /fsyncall. it crashes the server with the same error.
     
  16. Offline

    bocaj812

    hey kalman, have you looked at superperms yet? I was interested in seeing if okb3 worked with the bukkitpermissions and superpermbridge, but I had no success, I wouldn't mind seeing it become compatible, but It's no biggie, The yeti's permissions work just fine for the moment being
     
  17. Offline

    Kalman Olah

    Wow, THANK YOU. You are the first person to actually explicitly state the error is caused when you /RELOAD, THEN /FSYNCALL. I'll try to fix it right now :).
    Haven't looked into it yet. Will see what I can do on monday-ish. Got people over atm, so I can't really code a lot.
     
  18. Offline

    austech360

    Sorry mate. I fiddled with the server for about 2 hours. trying to figure out how to reproduce it. I hope you werent being sarcastic. sorry for being such a naggy bitch..
     
  19. Offline

    Kalman Olah

    No, I'm actually being serious. You are literally the first person to tell me when and why it's happening.

    Version 2.5.7
    Fixed all issues related to errors about SQL queries not returning ResultSets. Thanks to @austech360

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  20. Offline

    thernztrom

    Hello again Kalman, thanks for all the help.
    I set the rank field to group_id. But now I'm abit unsure about this part in the config:
    Is RANK NAME the rank they should get in the permssions file, and the RANK ID the id number it responds to in the forum?
    Like if i'd like to add Smod which have the forum group id 10 and called Smod in-game and Super Moderator in forums, would i then write:
    Smod: '10' or Super Moderator: '10' ?

    Thanks again for all help man! :)
     
  21. Offline

    Kalman Olah

    The RANK NAME is just an identifier for the forum RANK ID following it. It can be anything, it's just so you have something to type after /frank that's not a number. You can make it "derr" for all I care. It'll change the player's forum rank to what's mapped to it, and after that the plugin will try to sync that rank ID using a regular sync, as mapped at the top of the config.yml.

    EDIT: Make sure it's a single word though.
     
  22. Offline

    thernztrom

    Ok, but how does it know, liek if I do /frank thernztrom Smod. How does it know I should get the rank Smod in-game if the RANK NAME is just something to make the command easier to type. I guess there is somewhere in the config you should write what group_id relates to what in-game rank, but im unsure in what section I should do that.
    Could you point me right? :p

    Oh wait. Its here right:
    First thought it was for the multiword, but as of now reading your example config more closely, I see its not. :) Stupid me..

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  23. Offline

    Kalman Olah

    It gets it because Smod is mapped to '3', and '3' is mapped to the Permissions group "MODERATORGUY" in the groups at the top of the config.yml.
     
  24. Offline

    LibertasMens

    I'm confused. I keep getting
    Code:
    [OKB3] Error at SQL Query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'group FROM minecraft_users WHERE toon = 'LibertasMens'' at line 1
    2011-07-23 14:28:51 [SEVERE] Exception in thread "Thread-414"
    2011-07-23 14:28:51 [SEVERE] java.lang.NullPointerException
    2011-07-23 14:28:51 [SEVERE]     at me.kalmanolah.okb3.OKRunnable.run(OKRunnable.java:82)
    Similar to what I got with Warrant. Do the fields in my SQL table need to be of a certain type?
     
  25. Offline

    Kalman Olah

    When does this happen? Also, config.yml please :).
     
  26. Offline

    LibertasMens

    Whenever someone logs on.
    Code:
    mode: old-school
    mysql-connection-info:
        mysql-host: #.##.##.##
        mysql-user: #########
        mysql-password: ##########
        mysql-database-name: ########
    old-school-mode:
        usertable: minecraft_users
        minecraftname-field: toon
        rank-field: group
        enable-multiple-tables: 'false'
        multitable:
            secondtable: mine_table
            useridfield-in-secondtable: user_id_field
            useridfield-in-usertable: user_id_field
    #normal-mode:
    #    forum: phpbb
    #    type1:
    #        usertable: user_table
    #        username-field: username_field
    #        userpassword-field: user_pass_field
    #        rank-field: rank_field
    #    type2:
    #        usertable: user_table
    #        username-field: username_field
    #        userpassword-field: user_pass_field
    #        rank-field: rank_field
    #        location-of-passgenphp: http://yoursite.com/passgen.php
    #        password-set-in-config-inc-php: 12345pass
    #    type3:
    #        usertable: user_table
    #        rank-field: rank_field
    #        username-field: username_field
    #        password-field: pass_field
    #        secondtable: second_table
    #        useridfield-in-usertable: user_id_field
    #        useridfield-in-secondtable: user_id_field
    #    type4:
    #        usertable: user_table
    #        username-field: username
    #        password-field: mine_user
    #        rank-field: rank_field
    #        location-of-passgenphp: http://yoursite.com/passgen.php
    #        password-set-in-config-inc-php: 12345pass
    world-groups:
        enable-multiworld-groups: 'false'
        default:
            groups:
                '0': Default
                '1': User
                '9': Admin
    whitelist:
        enable-whitelist: 'false'
        global:
            use-as-blacklist: 'false'
            kick-message:
            groups:
    nickname-sync:
        enable-nickname-syncing: 'false'
        nickname-field-in-usertable: ''
    forum-banning:
        is-server-ban-too: 'true'
        banned-forum-user-rank-id: '-1'
        unbanned-forum-user-rank-id: '1'
        ban-message: You appear to be banned! How peculiar!
    promotion-tracks:
        '1': '3'
        '2': '5'
        '3': '16'
    forum-ranks:
        Default: '0'
        User: '1'
        Admin: '9'
    misc:
        mysql-ping-interval: '10'
    
     
  27. Offline

    Kalman Olah

    Try to not comment anything...Though I can't actually see an issue with your config.Yml, I'd guess that's the problem, assuming OKB3 used to work for you. Just delete your config.Yml and start over.
     
  28. Offline

    LibertasMens

    Same problem. :(

    What exactly is the query that you use?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  29. Offline

    Kalman Olah

    A very simple one.
    PHP:
    String query "SELECT " rankfield " FROM " table " WHERE " minecraftname " = '" player.getName() + "'";
    Result test Database.dbm.sqlQuery(query);
    if(
    test.next()){
    do{
    /*BUNCH OF SHIT
    */
    }while(test.next());
    }
     
  30. Offline

    LibertasMens

    Do you know what version of SQL your code is designed for? I'm thinking my site's SQL server may be out-of-date.
     
  31. Offline

    Kalman Olah

    Err...all of them? I literally can't think of a MySQL server that doesn't work with basic SELECT ... FROM ... WHERE ... = '...' syntax...

    EDIT: Is the field "group" in the table filled with numbers? Because the plugin needs group IDs, not names.
     

Share This Page