for turn based game, units can get buffed/debuffed with status effects, like poison, etc. I would like to ask the advisable place where to put amount of poison in the data structure. I can think of two approaches, one is, on the Status Effect object itself, or the Status Effect will just reference it from base ability used. I would like to ask for best practice, and if there are better approaches aside from 2 below. And if possible, I'd like to ask the pros and cons. Thank you very much.
I. On the Status Effect object itself
// Unit model
{
"unit_identifier": "some_unit_identifier1",
"status_effects": [
{
"status_identifier": "some_identifier1",
"status_type": "poison",
"custom_value": 50,
//... other properties
}
]
}
II. Status Effect will just reference it from base ability used. "some_status_effect_identifier2" will be used to get what ability was used. And get the value of poison from there.
// Unit model
{
"unit_identifier": "some_unit_identifier1",
"status_effects": [
{
"status_identifier": "some_status_effect_identifier2",
"status_type": "poison",
//... other properties
}
]
}