I made an empty arrayy playersList = []
that gets filled as the code runs.
To fill it I use: playersList.push({license, coins: playerCoins})
, which it's working.
I now have something like this:
[
{
"license": "a123"
"coins": 100
}
{
"license": "b123"
"coins": 200
}
{
"license": "c123"
"coins": 100
}
]
I would like to know how can I remove an object through it's license, as they have no reference. I've looked online and tried index = playersList.findIndex(GetIdentifier(global.source, 'license').toString())
but it says license it's not a function.