ravahn / FFXIV_ACT_Plugin

FFXIV Plugin for Advanced Combat Tracker
717 stars 58 forks source link

Combatant data should be an array #267

Closed bsides closed 3 years ago

bsides commented 3 years ago

I don't know if this should be posted here but I'm posting in both places just to be sure. The original one is here https://github.com/ngld/OverlayPlugin/issues/204

I would like to make a request, to make the Combatant data an array. Right now its data structure is not good, it's an object of n strings with common data inside. By JSON standards, this would benefit a lot from being an array, one of the main benefits of it being a structure with a iterator.

What I'm asking is this, change from:

Combatant: {
    "YOU": {
        // combat data
    },
    "Other Person": {
        // more combat data
    }
}

...to this:

Combatant: [
    {
        // YOU combat data straight here
    },
    {
        // OTHER PERSON's combat data right here
    }
]

This way, I would just iterate through Combatant (or other name to make it retro compatible, like Combatants) and search whatever I would like to show.

Would that be possible? Could I help with a PR?

Thank you in advance.

EQAditu commented 3 years ago

This repository has nothing to do with what format OverlayPlugin will output. (such as JSON) The FFXIV Plugin may have some of this data as binary objects in memory. ACT may have this data as objects in memory and can be exported as text.
Please don't triple post this to the ACT repository as well. 😛

bsides commented 3 years ago

Oh sure I wouldn't go that far, I was just checking if the data structure were coming from here or from Overlay's plugin. I just learned it comes from there, sorry for disturbing here. Thanks anyway!