promotional bannermobile promotional banner

PlaytimeLogger

This mod logs players' playtime on the server using Google Spreadsheets API. Useful for monitoring server's active player base.

Playtime Logger Mod

Purpose

If you ever encountered a problem with monitoring your server's activity, you might be interested in this modification. This mod uses Google Spreadsheets API to automatically log every player's logins and logouts, calculates individual session timeframes and shows this information in an easy and comfort way.

Setup

  1. Download and install this mod on your dedicated server.
  2. For now, you can follow this tutorial
  • Follow the link and create new Project
  • Enable the API
  • Create OAuth consent screen and setup External user type. After that, you can use this project in the testing environment.
  • Don't forget to add scope "./auth/spreadsheets"
  1. Download your generated OAuth client as a json file.
  2. Rename it to "credentials.json" and put this file to "/config/playtimelogger/" (if you have started your server, this directory should already exist)
  3. Restart your server. If everything works correctly, you will be prompted to follow the link in your server console. Follow the link and authorize with Google project that you created. Your credentials will be used by Playtime Logger to generate and update spreadsheet.

Usage

After successful initialization you can start tracking your players' playtime activity. Go to the Google Spreadsheets, authorize with your Google account and search for "Playtime Logger" spreadsheet (the name might be different if you replaced it in the config file). There you will see two sheets:

  1. First one, by default, is called "Total Playtime". There you will see all unique players that visited your server starting from the moment you installed the mod. There you will see players' names, UUIDs (for servers in offline mode), playtime for specified period and last login date.
  2. The second sheet is called "Logs" by default. There you will see individual logins and logouts of every player. Those events are described by Epochs (in seconds), Dates (using =EPOCHTODATE formula), and session playtime in seconds.

License

This project is available under the MIT license. Feel free to learn from it and incorporate it in your own projects.

The PlaytimeLogger Team

profile avatar
  • 1
    Followers
  • 3
    Projects
  • 1.7K
    Downloads

More from JustS_js

  • Custom Item Models project image

    Custom Item Models

    • 263
    • Mods

    Custom Item Models Mod powered by Custom Model Data Component

    • 263
    • April 9, 2025
    • Mods
    • +1
  • Hexxy Attributes project image

    Hexxy Attributes

    • 1.4K
    • Mods

    This modification adds a few Player Entity Attributes that may be used to change your experience playing with Hex Casting.

    • 1.4K
    • January 11, 2025
    • Mods
    • +3
  • Custom Item Models project image

    Custom Item Models

    • 263
    • Mods

    Custom Item Models Mod powered by Custom Model Data Component

    • 263
    • April 9, 2025
    • Mods
    • +1
  • Hexxy Attributes project image

    Hexxy Attributes

    • 1.4K
    • Mods

    This modification adds a few Player Entity Attributes that may be used to change your experience playing with Hex Casting.

    • 1.4K
    • January 11, 2025
    • Mods
    • +3