Re: Sessions VS MySQL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



As far as scalability goes, there's actually a game we're referencing a lot
to help us make it work at the get go called Kingdom of Loathing (
http://www.kingdomofloathing.com ). This game seems to have on average
around 1,000-1,500 users on at any given time. I've noticed when visiting
the page also, that is sends you to a random mirror of the site such as
www2..., www3..., etc.. I'm not sure if those shows that it's directing
people to various servers for the website, and that the database is possibly
stored on one server by itself. This seems a bit bulky a solution for an
online text/2d low res image rpg game, even with 1,000 users playing
simultaneously.

The point of saving only when I need to I get, and was planning to
implement. Such things as exploring around the game world, and, well, that's
all really, don't need to be saved as you'll start at the main location each
time you log in, but other things like battle, buying/selling/upgrading
items and inventory, and quest locations on the map, all need to be saved.

I guess one of my bigger concerns about saving is if it would seem natural
or strange to have it only save after the end of each battle, because the
way the battle system is planned to work is that you attack, it loads the
page, says how much dmg you did and the enemy did, then you may have to
attack again, loading the page howveer many more times is needed until you
die, or the enemy dies. There will be a function to run built in, but aside
from that the only other way to get out is to exit the browser. It seems a
bit cumbersome to have to access the db everytime an attack takes place, but
at the same time the player will be limited to a number of "moves" per day,
to make the game more fun, and help the server from dying. From what I
recall, mysql database calls take only .002 seconds, or something very quick
like that, so I suppose I shouldn't be too worried about the database
overloading from people using it, or should I? That's really one of my main
concerns.

Anyways, thanks for all the help and input so far, it's greatly appreciated.

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux