Hi All,
I am a game programmer, I have developed couple of HTML5 games, few games for Android. Presently I am working on a card game ( with around 100 cards) so asset management will be a pain.
I have developed card games like blackjack , but since I was only dealing with 52 cards, I designed the game using classes and objects, a card is an object with a face value , a suit and an .jpeg. It was pretty much copy and paste with a replace all , so it was easy writing a huge class deceleration file.
Okay coming to my question, what is the best practice followed to declare assets in similar games , like buildings with costs, hit value etc. I am inclining towards classes and objects ( as its my comfort factor and easy for me), but if we talk about performance and ease of upgrading game etc what is being followed ? Another option I am exploring is XML/database i.e. every card will have a different xml/row, but not sure about their implementation do you read the all the files/whole file during run time or at the start of the game , store it in an array ? this sounds more complex than object and classes.
Please suggest what you guys have followed and how that worked out during various versions of your game.
thanks