Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Conquer Online 2 > CO2 Private Server
You last visited: Today at 05:54

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Question] Item information storage

Discussion on [Question] Item information storage within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
littlechris95's Avatar
 
elite*gold: 0
Join Date: Nov 2011
Posts: 150
Received Thanks: 11
Question [Question] Item information storage

Which is better and why?

1 - Store all the information of the items in a dictionary own project as well as most sources do?

2 - Store the information of items in the database and do a search in the database each time the information is requested for an item?
littlechris95 is offline  
Old 01/20/2014, 22:56   #2
 
elite*gold: 0
Join Date: Feb 2006
Posts: 726
Received Thanks: 271
Store all the information in the database.
And then store all CURRENTLY used items in variables while the player is online.
Aceking is offline  
Thanks
1 User
Old 01/21/2014, 14:34   #3
 
littlechris95's Avatar
 
elite*gold: 0
Join Date: Nov 2011
Posts: 150
Received Thanks: 11
Quote:
Originally Posted by Aceking View Post
Store all the information in the database.
And then store all CURRENTLY used items in variables while the player is online.
Thanks for your opinion

- Anymore?
littlechris95 is offline  
Old 01/21/2014, 14:58   #4
 
elite*gold: 0
Join Date: May 2011
Posts: 648
Received Thanks: 413
Well... im a friend of the "lets put everything into ram" philosophy

Items arent big data, so you could always store evereything in memory and save time on access / IO locks.

Ram is cheap, efficient programming means using the ressources you have available. If you need to keep the ressource usage down, go with ace´s way. His way sounds very good to me but its harder to implement

Good luck!
Y u k i is offline  
Old 01/21/2014, 16:03   #5
 
littlechris95's Avatar
 
elite*gold: 0
Join Date: Nov 2011
Posts: 150
Received Thanks: 11
Quote:
Originally Posted by Y u k i View Post
Well... im a friend of the "lets put everything into ram" philosophy

Items arent big data, so you could always store evereything in memory and save time on access / IO locks.

Ram is cheap, efficient programming means using the ressources you have available. If you need to keep the ressource usage down, go with ace´s way. His way sounds very good to me but its harder to implement

Good luck!
Thank you very much!

#Closed
littlechris95 is offline  
Old 01/21/2014, 17:21   #6
 
elite*gold: 0
Join Date: Feb 2006
Posts: 726
Received Thanks: 271
Quote:
Originally Posted by Y u k i View Post
Well... im a friend of the "lets put everything into ram" philosophy

Items arent big data, so you could always store evereything in memory and save time on access / IO locks.

Ram is cheap, efficient programming means using the ressources you have available. If you need to keep the ressource usage down, go with ace´s way. His way sounds very good to me but its harder to implement

Good luck!
So you would load every item upon server start?
Not saying its a bad way just curious.

And it isn't really hard to implement.
Upon player login, just fill a dictionary with all that players items from the database. Then you just need to save it back whenever there are changes.
This way also ensures there is minimal data loss in the event of a crash.

If the server crashes or power fails and all that data in the RAM isn't saved, then its gone.
Aceking is offline  
Old 01/21/2014, 17:56   #7
 
littlechris95's Avatar
 
elite*gold: 0
Join Date: Nov 2011
Posts: 150
Received Thanks: 11
Quote:
Originally Posted by Aceking View Post
So you would load every item upon server start?
Not saying its a bad way just curious.

And it isn't really hard to implement.
Upon player login, just fill a dictionary with all that players items from the database. Then you just need to save it back whenever there are changes.
This way also ensures there is minimal data loss in the event of a crash.

If the server crashes or power fails and all that data in the RAM isn't saved, then its gone.
Excuse me, I forgot to mention. But I'm wondering about the information of all items (ItemType) and not the information of the items players.
littlechris95 is offline  
Old 01/21/2014, 20:22   #8
 
elite*gold: 0
Join Date: Feb 2006
Posts: 726
Received Thanks: 271
Oh, I would definitely say database.
Aceking is offline  
Reply


Similar Threads Similar Threads
[Question] check out storage keeper items by packets
04/04/2013 - Kal Online - 15 Replies
hey there everyone =] , i'm trying to check out all my items @ storage keeper by packets , the header is "0x32" (p.server) , but it takes "m" paremeter , any ideas how to use that ? thanks in advance =]
[Question] Max Storage / Exchange Gold
09/18/2012 - SRO Private Server - 1 Replies
Dear Comunity, i want edit my GameServer and want to change the max Store deposit and Exchange gold... in the Client i already edit it Store 006b296D FFFFFFFF 006b2975 FFFFFFFF Exchange
Item Plus Information (Item Levels)
06/12/2012 - CO2 Private Server - 0 Replies
#Solved myself request closed
Full Question Information [Question]
03/04/2011 - 9Dragons - 9 Replies
Hello. I Wanted to Post this topic coz my Problem i couldnt slove it so its all About 9Ddisciple 1-I Downloaded The lastest Ndreg For patch 32 2- i created the short cut and DID put This code >-U2TRZQ930QR3NC0Q9U03NDZ3XU And everything worked fine 3- I Did Open the 9Ddisciple First as an adminstrator Then
[Guide] Open Storage anywhere and Item Shop with UCE
05/11/2008 - Cabal Guides & Templates - 11 Replies
This is very simple and anyone should be able to do it at their first try. Might not as superb as other but at least usefull in certain situation =) - Open STORAGE anywhere Go to any port service NPC, now dont click the NPC yet. using UCE, search for 0 (4 bytes), u should have lots of address by now. now click on the port service NPC, drag some stuff out from your storage now dun close the storage yet. using UCE, search for 1 (4 bytes), u still have lots of address Now keep doing the...



All times are GMT +2. The time now is 05:54.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.