Saving data to the server

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

elmuerte

Master of Science
Jan 25, 2000
1,936
0
36
43
the Netherlands
elmuerte.com
one important note, when you are required to save a lot of info (e.g. a lot of users who's records have to be saved for a long time) you are better of saving the data off-site and request them from the off-site server when required to.
The only solution for that is to use a TcpLink subclass.
 

elmuerte

Master of Science
Jan 25, 2000
1,936
0
36
43
the Netherlands
elmuerte.com
a little side note, don't try to connect to the database directly, it'll be hell and a bad choice.
it's best to write an application that will connect to the database, you just connect to that application from your UT2003 server using your own protocol.
Code:
+----- Game Host ------+ +------------- Database Host -----------------+
|                      | |                                             |
|  [ UT2003 Server ] <-----> [ Front end ] <----> [ Database server ]  |
|                      | |                                             |
+----------------------+ +---------------------------------------------+
 

JohnnyFantastic

New Member
Jun 27, 2003
5
0
0
Visit site
Thanks for the help everyone. I just got mySQL up and running and I've built a DLL to talk to the server, but I have no idea how to integrate this into UT. I was guessing that I would just declare my exported functions as native in the .uc file, but do I need to have an engine license to do this? Thanks again
 

Mychaeel

New Member
JohnnyFantastic said:
I just got mySQL up and running and I've built a DLL to talk to the server, but I have no idea how to integrate this into UT. I was guessing that I would just declare my exported functions as native in the .uc file, but do I need to have an engine license to do this?
Yes... unless you can convince Epic to just give you access to the C++ headers. They have said they might do it in special cases (though I don't know whether they're still following this policy and whether your venture qualifies as such a "special case").

Keep in mind that with a DLL you're restricting use of your mod to Windows clients and servers. That's a pretty harsh restriction.

You could solve that problem on several levels: Create an UnrealScript solution for communicating with the MySQL server; or set up a Perl or PHP script on a web server that acts as a layer between the game server and the MySQL server, and have the game server talk to that Perl or PHP script via HTTP.
 

JohnnyFantastic

New Member
Jun 27, 2003
5
0
0
Visit site
OK, I've gotten rid of my dll altogether. Now I have a conduit program that talks with UT and the mySQL server (I've extended TcpLink as suggested) and everything is working fine. Thanks for all the help!