I have read (exhaustively) everything on the forums about plugins and 3rd party providers for multiplayer data storage. Also I have watched just about everything out there on youtube as well. I have come to the conclusion that there is no up to date guide on how to setup communication between client (remote player) and central online database that stores info specific to that player. My goal is to have a player log in and it to load that player’s stored health value, level value, and other important info and then save it intermittently to the database while playing.
I started using GameSparks because I thought it was going to be a not-so-painful way to setup authentication and this form of client to server to database communication. I was able to set up authentication easily because they have documentation on how to do that. However, they have almost 0 support to help me get these custom scripts set up and running. I have tried for a few weeks to store a single float to the database and have not been able to accomplish it.
I have also checked out 's save plugin. And while this might work if I figure out how to use it, it would only store data on the server machine. So if I had multiple servers the player would have a different account basically for each server, starting over every time. For this reason, I need a more permanent and available database all servers could use.
If anyone has a system that is working for them to save multiplayer data please enlighten me. I would love to chat on discord or any other means of communication. I’d be willing to shell out a good amount of $ to get a knowledgeable person to help me out with this. I have spent 13 months on my game and it works great so far. I have been testing it with my friends and everything is replicated properly, except next time they play none of their progress was stored.
Frezer748, What I am doing for the time being is using a custom system I have designed completely in blueprints to store players data on the server. I am using the built in “save to slot” feature in UE4. Basically, the player enters their username and password in, upon pressing login, the blueprint checks to see if there is a save slot that exists for the username+password, if so, it loads that players save and logs them in. if not, it prompts the player to try different credentials or create a new account. Creating a new account initializes a new save slot with default stats.
I will probably replace this system because I want to player to be able to load their characters save in not matter what server they are playing on, but I would need a professional to help me set up an SQL system.
Shadow, I have looked into the plugins on the marketplace and none seem easy to learn more about or set up. If there was a clearly popular choice with very clear documentation or video instructions on how to get a system set up I would by it. For now though, they only show off some nodes that would accomplish SQL communication, but setting up a system from start to finish is not as simple as “plug and play”.
I’ve setup gaming servers before, and my game in its current state has been able to get people from other countries all to connect to a single server. But SQL… that stuff is beyond me. Past my pay grade as a dev.
I have been using this plugin and it works pretty well, takes a bit to figure out but once you have the hang of it it works well, only limitation is that everything is done with strings. which you can work around for most things,the only problem I have found so far is with class references and trying to change them to a class variable, but I got around this by using a map variable, mapping string to class reference.
I am using the plugin to save player data to SQL 2017 and to store item data, all using GUID to uniquely identify items, the other problem I had is formatting the GUID for SQL as UE4 returns it without the dashes so just had to make a function to add the dashes in.
Also you need to make sure you dont send it any SQL missing varaibles etc as it tends to crash UE4, the error handling is fairly limited but as long as you check for null strings etc before calling the SQL all is good
I have all the SQL running in my gameinstance and access the data through there, so as far as I can figure unless someone actually hacks the server and gets access directly to the SQL it should be fairly safe. I am panning to use AES encryption with private and public keys for sensitive data like passwords, etc. but unless someone is sniffing as a man in the middle attack that is probably not necessary but belts and bracers as they say
Hey Dalton! Years later of this post i find myself at the same road. Now that its Nov 2022, what you do meet your above requirements! I hope youre still active ty!
Clients should not be directly connecting to a database. Massive security issue. It all should be done from the server.
Properly done you’ll want a RESTful API the server can send “requests” through and get back results (response). The request logic should be very discreet and specific. No way for custom requests to happen.