ArkShop Sharing Kits

Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Public Service Announcement

    Hey Guest, I’ve got some exciting news to share! 🎉

    Starting this December, I’ll be moving the entire GameServersHub website away from WordPress and rebuilding it in Next.js! This upgrade will bring incredibly faster speeds, smoother performance, and a modern user experience that sets the stage for everything coming next.

    In 2026, GameServersHub will be entering a new era. I’ll be revamping the entire platform from the ground up and launching a brand-new, fully modernized marketplace. It’ll feature a cleaner design, improved functionality, and better tools for both creators and server owners.

    On top of that, development has already started on the GameServerListing project at https://gsl-six.vercel.app/, which is expected to launch in early Q1 2026. This new system will make discovering and managing servers easier than ever before.


    👉 Stay in the loop!
    Join our Discord for behind-the-scenes updates, early previews, and community discussions.

    » Click here to join our Discord! «

    ~ MrOwlSky

PedroArmindo

Well-known member
Joined
Sep 18, 2020
Messages
62
The kits are being shared among the players. I don't know how to solve it.

See picture, the player are sharing the kits.
Player 1 receive 2 kit and get 1 kit, left 1
Player 2 receive 2 kit and get 1 kit, left 0

So player 2 are not geting 2 kit, they are sharing.
 
Still, the API and Permission and all plugins are built on SteamID (uint64) Not even sure what value EpicID is
 
Still, the API and Permission and all plugins are built on SteamID (uint64) Not even sure what value EpicID is

Okay, but does this have anything to do with my problem or do you have no idea what it might be?
 
Okay, but does this have anything to do with my problem or do you have no idea what it might be?
Only thing I know is that the ArkShop checks for players Kits by using this SQL Command:

SQL:
    std::string GetPlayerKits(uint64 steam_id) override
    {
        std::string kits_config = "{}";

        try
        {
            kits_config = db_.query("SELECT Kits FROM ArkShopPlayers WHERE SteamId = %I64u;", steam_id).get_value<std::string>();
        }
        catch (const std::exception& exception)
        {
            Log::GetLog()->error("({} {}) Unexpected DB error {}", __FILE__, __FUNCTION__, exception.what());
        }

        return kits_config;
    }

And when someone is using a Kit it updates the database with this SQL Command:

SQL:
       bool UpdatePlayerKits(uint64 steam_id, const std::string& kits_data) override
    {
        try
        {
            return db_.query("UPDATE ArkShopPlayers SET Kits = '%s' WHERE SteamId = %I64u;", kits_data.c_str(),
                             steam_id);
        }
        catch (const std::exception& exception)
        {
            Log::GetLog()->error("({} {}) Unexpected DB error {}", __FILE__, __FUNCTION__, exception.what());
            return false;
        }
    }

And those look correct and pretty much bulletproof and since the query includes "WHERE SteamId = <SteamID> and with that it could only hit one entire in the database.
Cause SteamId is a unique index. (Can't be duplicate of same SteamId in the database)
 
If you can include the ID's of the players (NOT playerID) and the database maybe someone can troubleshoot where it goes wrong. But I'm pretty sure it's related to the input from the players SteamID (Or if there is a EpicID)
 
If you can include the ID's of the players (NOT playerID) and the database maybe someone can troubleshoot where it goes wrong. But I'm pretty sure it's related to the input from the players SteamID (Or if there is a EpicID)
Thank you very much Foppa, but these settings are beyond my understanding.
I did a simple test, created a new server, from 0 and installed the plugin, it worked very well. I got into account 1 I got the kit, I got into account 2 I got the kit and they are not sharing. My new server for testing is not clustered.
Is that the problem? Where the error occurs are 4 clustered servers.
 
Thank you very much Foppa, but these settings are beyond my understanding.
I did a simple test, created a new server, from 0 and installed the plugin, it worked very well. I got into account 1 I got the kit, I got into account 2 I got the kit and they are not sharing. My new server for testing is not clustered.
Is that the problem? Where the error occurs are 4 clustered servers.
The plugin doesn't know if the server is clustered or not. So it shouldn't matter.
 
Thank you everyone.

I fix reinstaling my server from 0. Install API again and plugin again, works fine.
 
Back
Top