Garzec
July 29, 2018, 1:25pm
1
Hi,
I am new to database design and want to create a small RPG database. I took MMORPGs like World of Warcraft as a example.
Let’s assume effects are attached to gear and consumables. How can I design these effect tables?
Some effects for example
head: increase lifereg +x
shoulder: slow down all enemies within 10 yards
legs: get +x movementspeed
sword: lifesteal +x
gun: shoots twice per shot
bow: arrows explode on hit
I want to attach random effects to items. This is my database so far, if there are any mistakes please tell me!
U use ids, which is fine in your approach.
Garzec
July 29, 2018, 3:43pm
3
@Antypodish but how would you store such examples in a database?
If you specifically ask about data base system/storing:
I use SQLite to store data locally.
You can alternatively use server with MySQL.
And there are other alternatives.
Garzec
July 29, 2018, 4:38pm
5
sorry, I did not mean that. My question was how you would build up a table structure for effects (consider my examples)
Again, multiple ways to do it.
One way, is having one property per effect.
ID; Effect Name; Value
0; increase lifereg +x
1; slow down all enemies within 10 yards
2; … and so on
Then you may need another table, with sets of effects
ID: Effect Set Name, Effect IDs (as array)
0; “eff 0”; 0,2,5
1; “eff 1”; 1,2
2; …
and so on