getInitiativeList question
Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice
getInitiativeList question
The list of tokens that comes back in this call, is it in the order of he initiative? Or can that not be trusted?
Re: getInitiativeList question
It's a json object that has an array called tokens which holds an object with the token info in the order or the initiative panel.
For example:
Fyi, I use this bit of code to show me the json structure:
For example:
Code: Select all
{
"round": -1,
"map": "Catacombs",
"current": -1,
"tokens": [
{
"holding": false,
"initiative": "20.05",
"tokenId": "00000000942370A89223000000000000"
},
{
"holding": false,
"initiative": "15.01",
"tokenId": "00000000812370A8EE22000000000000"
}
]
}
Code: Select all
[dialog("D"):{<pre>[R: json.indent(replace(getInitiativeList(),"<","<"))]</pre>}]
Downloads:
- Notepad++ MapTool addon
- RPEdit details (v1.3)
- Coding Tips: Modularity and Design
- Videos: Macro Writing Tools