
Hi everybody,
I was hoping for a bit of help on a bug that appears to have manifested itself recently with my campaign. I've had a poke about and figured out what I think might be wrong, but am struggling to find a way to resolve it at present.
Recently, myself and my players have become unable to roll initiative for our characters whilst tokens are selected, and thus been unable to add them to the turn tracker. This has certainly made running combat a little more difficult than before!
The error began whilst playing yesterday, and was not something we'd had any issues with before. To begin with, we were unable to roll initiative from our character sheets whatsoever (using the D&D 5e by Roll20 sheet). I had initially had "ADD DEX TIEBREAKER TO INITIATIVE" enabled in the game settings, but then prior to the session had decided to disable it as I did not like the clutter of the tiebreakers in the turn tracker. Before this, I had no issues with initiative and had been able to access it via character sheets, referenced in a macro, and also through API using CombatTracker.
Since playing without this in the sessions, I have found that no existing or new character sheets were able to roll initiative with or without tokens selected. Re-enabling the "ADD DEX TIEBREAKER TO INITIATIVE" in the game settings has meant that you can now roll initiative with a character sheet, but not with a token selected.This again applies to new or existing characters/tokens.
I thought to start with that CombatTracker may be the issue, as it was throwing up an error when I attempted to use it. However, even with this script disabled the issue still persists. Re-enabling it and looking at the error leads to me believe that perhaps, Roll20 is having difficulty finding the initiative stat of the character sheet associated with a token. To test this, I tried linking and unlinking tokens to character sheets, and creating new unrelated tokens- in every instance, whilst I had a token selected, I was unable to roll initiative whatsoever.
For ref, here is the API error when attempting to roll initiative through CombatTracker:
TypeError: Cannot read property 'id' of null
TypeError: Cannot read property 'id' of null
at turnorder.forEach.turn (apiscript.js:12057:20)
at Array.forEach (native)
at checkMarkerturn (apiscript.js:12056:19)
at getOrCreateMarker (apiscript.js:12026:9)
at resetMarker (apiscript.js:11773:22)
at startCombat (apiscript.js:11723:9)
at handleInput (apiscript.js:11406:17)
at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:151:1), <anonymous>:65:16)
at Object.publish (eval at <anonymous> (/home/node/d20-api-server/api.js:151:1), <anonymous>:70:8)
at /home/node/d20-api-server/api.js:1634:12
When selecting a token in game and using the following: @{selected|initiative}to roll a tokens initiative, the following error is thrown up:
No attribute was found for @{selected|initiative}
As well as this, I also had an error along the lines of "C is undefined" whilst attempting this.
I'm currently using Firefox 62.0.2 (64 bit), on Windows 10 (64-bit), with Javascript enabled, Avira Antivirus and the browser addons: Avira Browser Safety, Honey & Reddit Enchancement Suite. (I have also tried disabling all of these addons, clearing my browser cache and the problem still persisted).
If anybody could shed any light on the issue I'm experiencing, and guide me towards a possible solution, that would be massively appreciated. If there is any further information needed to look into this, I'd be happy to share that also.
Thanks guys!