- Home /
Unity and a Server
I am trying to create a game, and i have the networking all worked out. The thing i want to add is User credentials, and progress saving. How do I go about that, because I do not have a server, ( or the funds to buy hosting) . I am thinking of a way to use an FTP site, like sta.sh or dropbox or something that is free and easy to interface to. Thanks
I assume you're using Peer-to-peer networking because you mention there is no dedicated server.
Why can't you save the state locally? Hosting with Dropbox (or any other service) is problematic because it assumes that the user already has, or is willing to create, an account. Saving to the cloud for a peer-to-peer game (even an authoritative server style solution) seems unnecessary to me.
I am using Photon as my networking solution. The .unity3d file is hosted onto dropbox, but I have no way of saving a file to the dropBox w/o user credentials. I just want to save a file with username, email, password, rank, kills, deaths, in something like a .csv file.
Answer by Yokimato · Mar 28, 2013 at 12:30 PM
I'm doing a project with the Photon cloud, and I've found that calling an API that I host myself as a great solution. The API I made is just a mongodb (though you could go with any db you felt comfortable with) backed with Microsoft's new WebAPI projects, part of MVC 4. From the game side, I'm just making HTTP requests. Works beautifully for checking login credentials and storing saved characters.
How can I implement that with my project, using Dropbox, of FTP or webs.com account/
The point that I'm trying to make is that you don't. Storing files in dropbox would be a disaster. Use a database--that's what they're for. $$anonymous$$y suggestion was to make yourself a simple API that interacts with your database so that you can call it from your game.
also...unless I'm missing something, the webs.com thing is a site to make websites.... I'm struggling to understand it's role.
What I am saying is, Where do I store the Database?
webs.com supports file upload.
Sorry, but you'll have to learn how to communicate with a database. Conceptually, interacting with a db is trivial compared to making a game. Look at $$anonymous$$ongoDb, or SQLLite--these are quick, easy technologies to get running locally. It's up to you to learn and use them.