Raised This Month: $23 Target: $400
 5% 

[CS:GO] amuJS (better KZTimer Jumpstats) [UPDATED 01/29/2020]


Post New Thread Reply   
 
Thread Tools Display Modes
Author
hiiamu
Member
Join Date: Nov 2018
Plugin ID:
6706
Plugin Version:
1.1.1
Plugin Category:
General Purpose
Plugin Game:
Counter-Strike: GO
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Stronger jumpstats module based off KZTimer Jumpstats by 1NutWunder
    Old 09-03-2019 , 21:40   [CS:GO] amuJS (better KZTimer Jumpstats) [UPDATED 01/29/2020]
    Reply With Quote #1

    Original ver: https://forums.alliedmods.net/showthread.php?t=252392
    Powerind's ver: https://forums.alliedmods.net/showthread.php?p=2656979

    GitHub page: https://github.com/amuDev/amuJS

    Some info
    • Added ownages
    • Added blues
    • Added anti-cheat functions
    • Built in Distbug
    • Jump bug detection
    • Menu for all settings
    • Cookies!! for all settings
    • Added CVars for all settings
      > All stat values
      > Enable/Disable CT Jumpstats and Distbug


    Commands
    • sm_showkeys
    • sm_speed
    • sm_sync
    • sm_stats
    • sm_bstats
    • sm_sound
    • sm_ljblock
    • sm_colorchat
    • sm_jumptop
    • sm_top
    • sm_rtop
    • sm_buggedjumptop
    • sm_btop
    • sm_js
    • sm_jssettings

    Add to database.cfg
    Code:
        "amuJS"
        {
            "driver"              "sqlite"
            "host"                "localhost"
            "database"            "kzjumpstats-sqlite"
            "user"                "root"
            "pass"                ""
        }
        "amuJSb"
        {
            "driver"              "sqlite"
            "host"                "localhost"
            "database"            "bkzjumpstats-sqlite"
            "user"                "root"
            "pass"                ""
        }
    Update Logs
    PHP Code:
    4.1.1[01/29/2020]
    Added distbug cvar
    Spoiler
    Attached Files
    File Type: zip amuJS.zip (460.0 KB, 206 views)
    File Type: sp Get Plugin or Get Source (amuJS.sp - 94 views - 222.5 KB)

    Last edited by hiiamu; 01-29-2020 at 10:22. Reason: Updated
    hiiamu is online now
    OfficialSikari
    Junior Member
    Join Date: Aug 2017
    Location: /dev/null
    Old 09-04-2019 , 12:06   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #2

    Yo, truly an epic plugin you've made!

    Couple things I want to note:
    - Every single menu you've created leaks their menu handle.
    - You've copied almost the entire Distbug plugin without crediting the original author at all.
    - You've created a database connection for bugged and nonbugged stats, something that could be considered expensive.
    - While you've converted the plugin to new syntax, I could argue that its way less readable at its current state.

    And top this off, you've created an advertisement to your discord at a 80 second timer, without a convar to even toggle it off.
    Overall, like I said, pretty epic!
    OfficialSikari is offline
    xantis
    Junior Member
    Join Date: Feb 2019
    Old 09-04-2019 , 12:48   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #3

    Nice work mate! I'll use it on my server.
    (Add quake sound files and translations file to the zip.)

    Last edited by xantis; 09-04-2019 at 12:57. Reason: remind
    xantis is offline
    hiiamu
    Member
    Join Date: Nov 2018
    Old 09-04-2019 , 18:53   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #4

    Quote:
    Originally Posted by OfficialSikari View Post
    Yo, truly an epic plugin you've made!

    Couple things I want to note:
    - Every single menu you've created leaks their menu handle.
    - You've copied almost the entire Distbug plugin without crediting the original author at all.
    - You've created a database connection for bugged and nonbugged stats, something that could be considered expensive.
    - While you've converted the plugin to new syntax, I could argue that its way less readable at its current state.

    And top this off, you've created an advertisement to your discord at a 80 second timer, without a convar to even toggle it off.
    Overall, like I said, pretty epic!
    Next version(4.0.1) will include the following -
    • Credit to GameChaos
    • CVar to change or disable/enable both adverts, meant to remove those before release...
    Could you give me some info on what you mean by leaking the menu handle and how it can be affecting things in negative ways, I would like to improve those. Also could you give some pointers to make my plugin more readable?

    Last edited by hiiamu; 09-04-2019 at 18:55.
    hiiamu is online now
    OfficialSikari
    Junior Member
    Join Date: Aug 2017
    Location: /dev/null
    Old 09-05-2019 , 04:08   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #5

    Quote:
    Originally Posted by hiiamu View Post
    Next version(4.0.1) will include the following -
    • Credit to GameChaos
    • CVar to change or disable/enable both adverts, meant to remove those before release...
    Could you give me some info on what you mean by leaking the menu handle and how it can be affecting things in negative ways, I would like to improve those. Also could you give some pointers to make my plugin more readable?
    Looking better, regarding the leaked menu handles:

    PHP Code:
    public KeyColorSettingsHandler(Handle menuMenuAction:actionclientselect) {
        if(
    action == MenuAction_Select) {
            if(
    select == 0)
                
    g_iKeyColors[client] = 0;
            if(
    select == 1)
                
    g_iKeyColors[client] = 8;
            if(
    select == 2)
                
    g_iKeyColors[client] = 16;
            if(
    select == 3)
                
    g_iKeyColors[client] = 24;
            if(
    select == 4)
                
    g_iKeyColors[client] = 32;
            if(
    select == 5)
                
    g_iKeyColors[client] = 40;
            if(
    select == 6)
                
    g_iKeyColors[client] = 48;
            if(
    select == 7)
                
    g_iKeyColors[client] = 56;
            if(
    select == 8)
                
    g_iKeyColors[client] = 64;
            if(
    select == 9)
                
    g_iKeyColors[client] = 72;
            if(
    select == 10)
                
    g_iKeyColors[client] = 80;
            if(
    select == 11)
                
    g_iKeyColors[client] = 88;
            
    KeyColorSettings(client);
            
    char sCookie[128];
            
    IntToString(g_iKeyColors[client], sCookiesizeof(sCookie));
            
    SetClientCookie(clientg_hKeyColorCookiesCookie);
        }
        if(
    action == MenuAction_Cancel)
            
    SpeedPanelSettings(client);

    You're supposed to have a condition for MenuAction_End, and delete the menu handle there, the SourceMod Menu API reference mentions this as well.
    Heres an example on how to do that: https://wiki.alliedmods.net/Menu_API...od)#Basic_Menu

    P.S. Your if statement madness can be solved by
    PHP Code:
    g_iKeyColors[client] = (select 8); 
    Regarding on how to make the code more readable, this is a highly opinionated thing, but I prefer Allman as an indentation style.
    On the other hand, you have mixed new and old syntax. The lack of newlines and consistency makes it hard to read.

    Last edited by OfficialSikari; 09-05-2019 at 04:15.
    OfficialSikari is offline
    zwolofmeister
    Member
    Join Date: Aug 2018
    Old 09-05-2019 , 06:08   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #6

    Great job mate! Didn't expect you to release this piece of art! But instead of creating an extra table for distbug i'd add it all to a single database so installation and management would be easier.

    p.s
    Add it to a github repo and link it in the post
    zwolofmeister is offline
    hiiamu
    Member
    Join Date: Nov 2018
    Old 09-05-2019 , 09:54   Re: [CS:GO] amuJS (better KZTimer Jumpstats)
    Reply With Quote #7

    Quote:
    Originally Posted by OfficialSikari View Post
    Looking better, regarding the leaked menu handles:

    You're supposed to have a condition for MenuAction_End, and delete the menu handle there, the SourceMod Menu API reference mentions this as well.
    Heres an example on how to do that: https://wiki.alliedmods.net/Menu_API...od)#Basic_Menu
    I put these cases in to stop leaky menu handles will update download soon.
    Quote:
    Originally Posted by OfficialSikari View Post
    P.S. Your if statement madness can be solved by
    PHP Code:
    g_iKeyColors[client] = (select 8); 
    JoinedSenses recommended and a few other optimizations, these will be included in the next update.
    Quote:
    Originally Posted by OfficialSikari View Post
    On the other hand, you have mixed new and old syntax. The lack of newlines and consistency makes it hard to read.
    I tried to keep it all new syntax but haven't checked through for old syntax for a while. Will also try to update these in the next update.

    Quote:
    Originally Posted by zwolofmeister View Post
    Great job mate! Didn't expect you to release this piece of art! But instead of creating an extra table for distbug i'd add it all to a single database so installation and management would be easier.

    p.s
    Add it to a github repo and link it in the post
    Thanks, planing on making everything 1 database but that may take a few updates, going to start work on creating a repo for this.

    Last edited by hiiamu; 09-05-2019 at 09:55. Reason: fixed quote tag
    hiiamu is online now
    haooy
    Junior Member
    Join Date: Dec 2017
    Location: Poland
    Old 11-28-2019 , 11:47   Re: [CS:GO] amuJS (better KZTimer Jumpstats) [UPDATED 10/20/2019]
    Reply With Quote #8

    Hello, plugin is spamming these errors:
    [SM] Exception reported: Client x is not connected
    [SM] Blaming: hns/amuJS.smx
    [SM] Call stack trace:
    [SM] [0] ClientCommand
    [SM] [1] Line 2185, D:\dd\amuJS.sp::NumberThreePost
    [SM] [2] Line 2158, D:\dd\amuJS.sp::Top3Check
    [SM] [3] Line 2107, D:\dd\amuJS.sp::Top3CheckDelay
    please fix this, btw great plugin

    Last edited by haooy; 11-28-2019 at 11:49. Reason: .
    haooy is offline
    AuricYoutube
    Senior Member
    Join Date: Aug 2016
    Location: Here
    Old 11-29-2019 , 01:33   Re: [CS:GO] amuJS (better KZTimer Jumpstats) [UPDATED 10/20/2019]
    Reply With Quote #9

    A couple of issues, ^^ the error spam above, also a panel improvement also, why isn't there a back button and only an exit button, and also if stats don't exist in a category and you pick that category it closes the menu instead of telling you that stats don't exist there yet.
    AuricYoutube is offline
    haooy
    Junior Member
    Join Date: Dec 2017
    Location: Poland
    Old 11-29-2019 , 08:16   Re: [CS:GO] amuJS (better KZTimer Jumpstats) [UPDATED 10/20/2019]
    Reply With Quote #10

    please add crouch jump in stats
    haooy is offline
    Reply


    Thread Tools
    Display Modes

    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 22:31.


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