5
« on: July 12, 2014, 09:04:27 pm »
Hello, I am working on an ORPG and I am wondering on the best method to store the users data, by this I mean, I want to be able to store the items that the user has in the his/her inventory or bank.
The user has a their username, password and other details stored in a database, my first initial idea to store the users value was to have a secondary table with a foreign key from the item table and the player table, but having multiple players updating a database all the time is slow? (Correct me if I am wrong!)
My second thought was too load all the possible items from the database into a list array with the item class type and use that though out the applications life time, but if I do this the list array will only exist while the application is running unless I store the values on the server or a database of some sort, preferably after the user logs out of the game?
I am just wondering if I am on the right tracks to do this, is the logic I am trying to accomplish the most efficient? Any tips or resources would be greatly appreciated on this. Thanks