I'm working on a project which is a collectable card game, where cards gonna have very different abilities, for example as in Hearthstone - one card kills another card, another gives mana, another deals damage, another gives additonal damage, another doubles it's damage, so those are completely different abilites. But I don't know where and how to store these abilites. How is it made? I think it's not possible to store this information in the DB. Or is it?
\$\begingroup\$
\$\endgroup\$
6
-
\$\begingroup\$ Why do you want to store them in a database? How often do you want to introduce new cards? How unique is the effect of an effect? \$\endgroup\$– ZibelasCommented May 12 at 9:08
-
3\$\begingroup\$ You may be interested in How to create data driven effects/abilities for collectable card game, How to implement trading card game's "special effects cards"?, How should I implement card effects in a card game?, Attaching scripts that trigger on specific events, and Q&A in the effect-modifier tag. (Search results) \$\endgroup\$– DMGregory ♦Commented May 12 at 11:03
-
\$\begingroup\$ If not in a DB, then where should I store them(that is a part of the question)? Each card is gonna have a unique effect, sometimes maybe they are gonna be the same but with different values (different amount of damage f.e.). I don't really know how often I gonna introduce new cards, but at the beggining it's gonna be 20 cards. \$\endgroup\$– 13ackspaceCommented May 12 at 11:29
-
1\$\begingroup\$ What game engine are you using? If you are unfamiliar with even the basics of storing data, perhaps you should consider some introductory programming books or courses, so you have a better foundation of knowledge to work from. \$\endgroup\$– KevinCommented May 13 at 0:40
-
\$\begingroup\$ Does it matter which engine I am using (it's UE5, anyways)? Why is it basics? I think that I should somehow store code as a string in the DB, but I don't know if it's a best practice to do so or there are some other ways \$\endgroup\$– 13ackspaceCommented May 13 at 19:39
|
Show 1 more comment