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

[ANY] Connection Data


Post New Thread Reply   
 
Thread Tools Display Modes
Author
JoinedSenses
Senior Member
Join Date: Sep 2013
Plugin ID:
6958
Plugin Version:
0.1.3
Plugin Category:
Statistical
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    10 
    Plugin Description:
    A plugin which stores player connection data in a database.
    Old 02-29-2020 , 19:27   [ANY] Connection Data
    Reply With Quote #1

    Connection Data

    Description:
    A plugin which stores player connection and map history data in a database. Similar to the player analytics plugin by McKay.

    Requires extension GeoIP2 and a database configuration in databases.cfg for "connectiondata"

    Note:
    If you install, shut down server first. Any plugins which currently use geoip would have to be recompiled to use new include file.

    Stored Player Data:
    • Server IP.
    • Player count
    • Map name
    • Client name
    • SteamID2
    • Connection method
    • Date
    • Time
    • Day (0 - 6, starting from Sunday)
    • Formatted date string
    • Session connection duration
    • IP, City, Region, Country
    • Total time connected in seconds
    • Total connection count

    Stored Map Data:
    • Server IP
    • Map name
    • Date
    • Time
    • Day (0 - 6, starting from Sunday)
    • Formatted date string
    • Session duration
    • Total accumulated map time in seconds
    • Total map play count


    Project here:
    Github
    __________________

    Last edited by JoinedSenses; 04-02-2020 at 22:42.
    JoinedSenses is offline
    CrazyHackGUT
    AlliedModders Donor
    Join Date: Feb 2016
    Location: Izhevsk, Russia
    Old 03-01-2020 , 00:15   Re: [ANY] Connection Data
    Reply With Quote #2

    Why you don't use Database.Format() or Database.Escape() for username?
    __________________
    My english is very bad. I am live in Russia. Learning english language - very hard task for me...
    CrazyHackGUT is offline
    Send a message via ICQ to CrazyHackGUT Send a message via Skype™ to CrazyHackGUT
    JoinedSenses
    Senior Member
    Join Date: Sep 2013
    Old 03-01-2020 , 11:02   Re: [ANY] Connection Data
    Reply With Quote #3

    Should be fixed - added escape to playername. Using FormatEx due to the way connection method is handled and forgot to add Escape(). Thanks.
    __________________

    Last edited by JoinedSenses; 03-01-2020 at 13:24.
    JoinedSenses is offline
    eliteroyal
    AlliedModders Donor
    Join Date: Dec 2016
    Location: Moldova
    Old 03-02-2020 , 02:44   Re: [ANY] Connection Data
    Reply With Quote #4

    On a full 40/40 server will this have some performance inpact?
    __________________
    PEACE FROM MOLDOVA
    eliteroyal is offline
    JoinedSenses
    Senior Member
    Join Date: Sep 2013
    Old 03-02-2020 , 07:32   Re: [ANY] Connection Data
    Reply With Quote #5

    It shouldnt, since the queries are threaded.
    __________________
    JoinedSenses is offline
    Notifications
    AlliedModders Donor
    Join Date: Oct 2015
    Old 03-02-2020 , 21:35   Re: [ANY] Connection Data
    Reply With Quote #6

    Is it possible to have this create a further list of IPs? Like if a user joins with IP 127.0.0.1 then later it changes to 0.0.0.0 - if you had to search up their SteamID, it would display both 127 and 0.0?
    Notifications is offline
    JoinedSenses
    Senior Member
    Join Date: Sep 2013
    Old 03-03-2020 , 10:37   Re: [ANY] Connection Data
    Reply With Quote #7

    You can query it with:

    SELECT DISTINCT `ip` FROM `connect_sessions` WHERE `authid2` = 'STEAM_whatever'

    If using PhpMyAdmin, there is a tab to query the database with the text "SQL"
    __________________

    Last edited by JoinedSenses; 03-05-2020 at 18:12.
    JoinedSenses is offline
    Lubricant Jam
    AlliedModders Donor
    Join Date: Oct 2016
    Location: United Kingdom
    Old 03-07-2020 , 23:38   Re: [ANY] Connection Data
    Reply With Quote #8

    Can you improve the tables relations and the data types used. Would help with queries to this later down the line.
    __________________
    Lubricant Jam is offline
    JoinedSenses
    Senior Member
    Join Date: Sep 2013
    Old 03-08-2020 , 11:34   Re: [ANY] Connection Data
    Reply With Quote #9

    Quote:
    Originally Posted by Lubricant Jam View Post
    Can you improve the tables relations and the data types used. Would help with queries to this later down the line.
    I'm having trouble deciphering what this means.
    __________________
    JoinedSenses is offline
    Lubricant Jam
    AlliedModders Donor
    Join Date: Oct 2016
    Location: United Kingdom
    Old 03-16-2020 , 16:22   Re: [ANY] Connection Data
    Reply With Quote #10

    Quote:
    Originally Posted by JoinedSenses View Post
    I'm having trouble deciphering what this means.
    For example, joining tables together on repetitive fields and overall not duplicating things.
    __________________
    Lubricant Jam 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 06:00.


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