Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
D&D 2024 has arrived! Pre-order the new core rulebooks now and get an exclusive pre-order bonus for free!
Create a free account

[Script] CombatTracker

1537535282
The Aaron
Pro
API Scripter
Hmm.. I don't see how that could have fixed it.  prev is used for nothing in that function.  Also, you have an extra ) after prev, not sure if that is changing things for you.
1537547007

Edited 1537561099
Is it possible to add the same status to two different tokens and have it countdown separately? Currently every token with a status shares the duration when it links to StatusInfo and has an icon. It works fine when it's not referencing the other script. Thanks!
1537552535

Edited 1537552690
Victor B.
Pro
Sheet Author
API Scripter
@The Aaron, I know.  I saw the same thing.  Don't know why prev has to be there as it isn't being referenced.  However, I received the same ID not found error.  I traced it back to the on change events for handleGraphicMovement,  I commented out handleGraphicMovement onChange.  It worked.  I then commented back in those on change events, restored original code for that function and it worked.   Now it could be FIRST time in, it fails,  By commenting out those on change events, everything got set properly and the code change really isn't needed. Not entirely sure.     And since I did reset that function (handleGraphicMovement) back to original code (with prev), I haven't been able to recreate the ID error.  
I can't get the marker from who's turn is it on the token, the red painted circle from page 1. Tried resetting it to no avail, is there a command I didn't see ?
1538582476

Edited 1538582543
Victor B.
Pro
Sheet Author
API Scripter
First, did you grab TheAarons fixes to this script posted earlier?  You can't miss that post.  It's quite large.  I've noticed that if you are running it as DM (only) the token doesn't move.  Once the actual players are online, it moves. I haven't gone into depth in the code, but it may using player information within the campaign objects, so the player has to be online I believe.  But it does move.   Also note at top of script, there's a command to integrate with statusinfo.  You need to manually set that to true and it will import all of the statusinfo conditions into combattracker.  Then when you assign a condition, from within combattracker you type in the condition name (Blessed for example) then put in the duration, which is 10 rounds I believe, and you'll see that it will track that condition and shut if off at the end of 10 rounds.    
Found it! I just wasn't on the player page, then the tracking circle was there and moving, no need for players.
1538621401
Midgardia
Pro
Marketplace Creator
Sheet Author
Hello! Been using this script for a bit but recently, I get an error that breaks the API and I have to restart the sandbox. I haven't been able to pinpoint exactly what the problem IS or what I do consistently but I've had this same error break the script multiple times in one battle. I get this error showing on the API output: Error: toFront() must be given an object either from an event or getObj() or similar. undefined
1539073603
Robin
API Scripter
Oke, I think i'm really back now. I know I have said this before, but I plan on staying. I have read through all my messages and topics, and plan on updating/improving my scripts. I have made an update to CombatTracker in my Repo, the update only contains TheAron's fixes (Thanks for them!) so far, but a bigger update is coming. Let me know all the ideas/bugs! <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a>
1539081095
Robin
API Scripter
Update 0.2.2 Small update where it is optionally to automatic skip custom items in the turntracker. Made some change to the !ct show menu. With also a button to show custom condition messages and/or StatusInfo descriptions. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a>
1539089169
Victor B.
Pro
Sheet Author
API Scripter
A menu option to integrate statusinfo with combattracker would be great.&nbsp; &nbsp;Right now you need to change the code to do that.&nbsp; Then I create statuses in statusinfo and they become available in combattracker.&nbsp; A nice to have would be a graphic ability to set the condition rather than having to type the name of the condition from within combattracker.&nbsp;&nbsp;
1539098927
Robin
API Scripter
Victor B. said: A menu option to integrate statusinfo with combattracker would be great.&nbsp; &nbsp;Right now you need to change the code to do that.&nbsp; Then I create statuses in statusinfo and they become available in combattracker.&nbsp; A nice to have would be a graphic ability to set the condition rather than having to type the name of the condition from within combattracker.&nbsp;&nbsp; You mean a list with statuses from StatusInfo in CombatTracker to easily add them during combat?
1539117001
Victor B.
Pro
Sheet Author
API Scripter
Yep.&nbsp;&nbsp;
1539154385

Edited 1539154459
Robin
API Scripter
Victor B. said: Yep.&nbsp;&nbsp; Isn't that what !ct conditions shows? Or is that not what you meant?
1539160265
Robin
API Scripter
Tom said: Is it possible to add the same status to two different tokens and have it countdown separately? Currently every token with a status shares the duration when it links to StatusInfo and has an icon. It works fine when it's not referencing the other script. Thanks! Will be fixed in the next update.
1539161206
Robin
API Scripter
Update 0.2.3 Optionally whisper turns only to the GM. Fixed a bug where StatusInfo conditions couldn't have different durations. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a>
1539282912
Robin
API Scripter
Update 0.2.4 Changed config menu, turnorder settings are now in a seperate menu. Optionally run a character macro (ability) on the characters turn. Optionally turn off auto sorting the turnorder. Optionally reroll initiative on every new round. FX will now not show when a token is on the gmlayer. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a>
Robin said: Optionally reroll initiative on every new round. I freaking love this! Thanks Robin!
1539346204

Edited 1539346732
Robin said: Update 0.2.2 Small update where it is optionally to automatic skip custom items in the turntracker. I'm so happy with the this update, Thank You Robin and welcome back! I have two other suggestions : 1. When I open the Turnorder and roll initiative for all tokens via character sheet or other means and , and then use the !ct start command the CombatTracker Marker does not auto move to the token at the top of the Turnorder. I can get around this by adding !ct next and !ct prev to my start combat macro.&nbsp; 2. Combat Timer: Add option in CombatTracker Timer Config for autoskip turn when timer runs out. For example I want my players to state what they wish to do within 10 seconds then we usually use minutes to resolve that players turn and then the player presses macro with !ct next. Cheers&nbsp;&nbsp;
1539348920
Robin
API Scripter
Thanks for the replies guys! Dethelm said: 1. When I open the Turnorder and roll initiative for all tokens via character sheet or other means and , and then use the !ct start command the CombatTracker Marker does not auto move to the token at the top of the Turnorder. I can get around this by adding !ct next and !ct prev to my start combat macro.&nbsp; 2. Combat Timer: Add option in CombatTracker Timer Config for autoskip turn when timer runs out. For example I want my players to state what they wish to do within 10 seconds then we usually use minutes to resolve that players turn and then the player presses macro with !ct next. Both of these will be added/changed in the next update!
I don't know if you are trying to add this but what about rolling initiative at advantage?
1539351589
Robin
API Scripter
You mean autorolling the initiative with advantage?
1539352339

Edited 1539352734
Yes, because I select everything and roll the initiative. It's just quicker I think. Also, thoughts on tie breaking? Rolling with advantage is also something I would like to have in the Concentration API. So many casters have War Caster it only makes sense.
1539353955
Robin
API Scripter
Jerry F. said: Yes, because I select everything and roll the initiative. It's just quicker I think. Also, thoughts on tie breaking? Rolling with advantage is also something I would like to have in the Concentration API. So many casters have War Caster it only makes sense. Latest update of concentration has this.&nbsp; <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/Concentration" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/Concentration</a> I will look into the rest for CombatTracker.
1539546438

Edited 1539547366
Hi, I love using Combat Tracker and it's one of my favorite scripts, but there's a couple things I'd like to know about. First, is there a way to make the initiative rolls visible to everybody in chat? Second, the API console throws an error whenever a player in the GM's campaign tries to use !ct next &nbsp;before any tokens are added to the turn order (so basically when the turn order is empty). Here is the error I get: Is there already a fix for this? Or is it a special case on my end? Thanks! Edit: I noticed the !ct next error happens specifically when there are no tokens added onto the turn order. This means it's fine as long as there is at least one token (which doesn't have to be their token) on the turn order.
1539554652
Robin
API Scripter
Mark said: Hi, I love using Combat Tracker and it's one of my favorite scripts, but there's a couple things I'd like to know about. First, is there a way to make the initiative rolls visible to everybody in chat? Second, the API console throws an error whenever a player in the GM's campaign tries to use !ct next &nbsp;before any tokens are added to the turn order (so basically when the turn order is empty). Here is the error I get: Is there already a fix for this? Or is it a special case on my end? Thanks! Edit: I noticed the !ct next error happens specifically when there are no tokens added onto the turn order. This means it's fine as long as there is at least one token (which doesn't have to be their token) on the turn order. Thanks for your reply! The bug will be fixed in the next update. I will look into the initiative rolls before the next update.
1539601960

Edited 1539601980
Robin
API Scripter
Update v0.2.5 Toggle auto skip turn when timer runs out. Optionally show auto initiative rolls in chat. !ct next bugfix. Other bugfixes. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a> ** Soon in the one click installer**
Robin said: Update v0.2.5 Toggle auto skip turn when timer runs out. Optionally show auto initiative rolls in chat. !ct next bugfix. Other bugfixes. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a> ** Soon in the one click installer** Soo freeking awesome Robin... However i am getting this error sometimes when I have rolled init and type !ct start. API Output Console Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your scripts and click the "Save Script" button and we'll attempt to start running them again.&nbsp; More info... For reference, the error message generated was:&nbsp; TypeError: Cannot read property 'get' of undefined TypeError: Cannot read property 'get' of undefined at selected.forEach.s (apiscript.js:10081:33) at Array.forEach (native) at rollInitiative (apiscript.js:10077:18) at startCombat (apiscript.js:10066:13) at handleInput (apiscript.js:9707:17) at eval (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:65:16) at Object.publish (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:70:8) at /home/node/d20-api-server/api.js:1634:12 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560&nbsp; at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) &nbsp; Cheers
Robin said: Update 0.2.2 Small update where it is optionally to automatic skip custom items in the turntracker. Hi Robin. I just tested some more and when having a Custom Item with a direction of for excample -1 and you have set the CombatTracker to skip custom, the custom item won't "tick" down every round. Any chance you can make that work?
1539958346
SᵃᵛᵃǤᵉ
Sheet Author
API Scripter
Suggestions: I would recommend a menu option to set the dice or die for the initiative roll, to include the option for zero sided dice rolls. Menu option to easily configure attribute used for initiative. (not sure if this is addressed already) Also the ability to add an arbitrary bonus to a roll including rolls with zero sides for a flat bonus Group rolls (select a group then roll, similar to Group-Init).
Robin said: Update 0.2.3 Optionally whisper turns only to the GM. Fixed a bug where StatusInfo conditions couldn't have different durations. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a> Awesome. Really appreciate it!
Scott S. said: Suggestions: I would recommend a menu option to set the dice or die for the initiative roll, to include the option for zero sided dice rolls. Menu option to easily configure attribute used for initiative. (not sure if this is addressed already) Also the ability to add an arbitrary bonus to a roll including rolls with zero sides for a flat bonus Group rolls (select a group then roll, similar to Group-Init). Good suggestions, also I would ask: Ability to sort initiative (eg. if you add someone after the initial rolls) -- maybe this is already baked in?
I could see how a !ct sort would be a good idea. I add things to the Turn order all the time after combat has started.
Great scrip, and thanks. One thing I'd like to see is an "up next" marker (toggleable). Use a green "circle" just like your red active player image, but marking the token who is up next in initiative. Could also add this to the announcement in chat...basically to "push" players into thinking about their next actions. Maybe skip tokens (don't show the next "circle" on the token) that are not on the object layer or that are invisible (so as to not give away location). I actually do this in my face-to-face games and works like a charm...speeds up combat quite a bit. Of course, I generally have a party who tend to sometimes get sidetracked by outside influences or are so focused on what the current player is doing so are not thinking about their characters.
One question I have for Robin (or anyone I guess): are players supposed to use !ct start to roll for their tokens, or do they just roll initiative from their sheets after I (GM) runs !ct start? I had them use !ct start last night and it didn't seem to work.
Evan said: One question I have for Robin (or anyone I guess): are players supposed to use !ct start to roll for their tokens, or do they just roll initiative from their sheets after I (GM) runs !ct start? I had them use !ct start last night and it didn't seem to work. Evan they can roll from the sheet it will add to the turn order and when you !ct start it will add who ever you have selected and go to the first PC or NPC in the order.
Jerry F. said: Evan said: One question I have for Robin (or anyone I guess): are players supposed to use !ct start to roll for their tokens, or do they just roll initiative from their sheets after I (GM) runs !ct start? I had them use !ct start last night and it didn't seem to work. Evan they can roll from the sheet it will add to the turn order and when you !ct start it will add who ever you have selected and go to the first PC or NPC in the order. So to clarify the best process is: 1. Open turn tracker 2. Have PCs roll initiative 3. Select NPCs and run !ct start Is that correct?&nbsp; I would definitely love a sort function then because stuff often happens all at once and then the turn tracker is out of order :(
You don't need to have the turn order open, the rolls of your PCs will be stored.
1540242425
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Tip: remember to clear the turn order after a combat. I can't count the number of times I've asked players to roll initiative, only to discover the Turn Tracker is littered with turns from the previous combat.
!ct stop does it automatically.
1540305369
Robin
API Scripter
Dethelm said: Robin said: Update v0.2.5 Toggle auto skip turn when timer runs out. Optionally show auto initiative rolls in chat. !ct next bugfix. Other bugfixes. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a> ** Soon in the one click installer** Soo freeking awesome Robin... However i am getting this error sometimes when I have rolled init and type !ct start. API Output Console Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your scripts and click the "Save Script" button and we'll attempt to start running them again.&nbsp; More info... For reference, the error message generated was:&nbsp; TypeError: Cannot read property 'get' of undefined TypeError: Cannot read property 'get' of undefined at selected.forEach.s (apiscript.js:10081:33) at Array.forEach (native) at rollInitiative (apiscript.js:10077:18) at startCombat (apiscript.js:10066:13) at handleInput (apiscript.js:9707:17) at eval (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:65:16) at Object.publish (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:70:8) at /home/node/d20-api-server/api.js:1634:12 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560&nbsp; at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) &nbsp; Cheers Is your auto roll ini. config option enabled or disabled? Dethelm said: Robin said: Update 0.2.2 Small update where it is optionally to automatic skip custom items in the turntracker. Hi Robin. I just tested some more and when having a Custom Item with a direction of for excample -1 and you have set the CombatTracker to skip custom, the custom item won't "tick" down every round. Any chance you can make that work? Will take a look into that. --- I will also take a look into the other suggestions.
1540358803

Edited 1540358896
Robin said: Soo freeking awesome Robin... However i am getting this error sometimes when I have rolled init and type !ct start. API Output Console Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your scripts and click the "Save Script" button and we'll attempt to start running them again.&nbsp; More info... For reference, the error message generated was:&nbsp; TypeError: Cannot read property 'get' of undefined TypeError: Cannot read property 'get' of undefined at selected.forEach.s (apiscript.js:10081:33) at Array.forEach (native) at rollInitiative (apiscript.js:10077:18) at startCombat (apiscript.js:10066:13) at handleInput (apiscript.js:9707:17) at eval (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:65:16) at Object.publish (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:70:8) at /home/node/d20-api-server/api.js:1634:12 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560&nbsp; at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) &nbsp; Cheers Is your auto roll ini. config option enabled or disabled? Hi Robin Just tried to do some investigation, here is what I did: Set Auto roll ini to false. Open clean turnorder window Select a token (in this case a player character) and roll init via character sheet. (Repeat with 3 different tokens) type !ct start Then I got this error, and I get it every time i do the above: SyntaxError: Unexpected end of JSON input SyntaxError: Unexpected end of JSON input at JSON.parse (&lt;anonymous&gt;) at handleTurnOrderChange (apiscript.js:9364:14) at eval (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:65:16) at Object.publish (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:70:8) at TrackedObj.set (/home/node/d20-api-server/api.js:1020:14) at updateLocalCache (/home/node/d20-api-server/api.js:1318:18) at /home/node/d20-api-server/api.js:1608:7 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560 at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) at Kd (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:546) If i restart the API sandbox and type !ct start then it will work. If i changed auto roll init to true and repeat the steps above i get the same error. Hope this helps
1540543411
Robin
API Scripter
Update v0.2.6 Custom items will now count down/up correctly when applied. Set initiative die in the config. Sort turnorder with&nbsp; !ct sort . Bugfixes. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a>
1540563200

Edited 1540567813
Robin said: Update v0.2.6 Custom items will now count down/up correctly when applied. Set initiative die in the config. Sort turnorder with&nbsp; !ct sort . Bugfixes. <a href="https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker" rel="nofollow">https://github.com/RobinKuiper/Roll20APIScripts/tree/master/CombatTracker</a> Hi Robin. I really appreciate the improvements, however: Im still getting the error when i described in my previous post. (dunno if my issue was part of the bug fixes?) !ct sort also gives me an error and crashes the API. Skip Custom Item ticks 2 down when set to direction -1. Tested it with different directions: ticks 4 down when set to -2 and finally ticks 3 down when set to -3... I'm wondering if I'm the only one getting thes errors? Cheers
I just tried the new version of CT, and !ct sort is working great for me with no errors; sandbox is still up and running after. I did not try "skip custom items" though
I found the culprit to the API crashes im getting. The API called MARK by The Aaron is the one that is crashing the API when typing !ct start or !ct sort. Mark can be installed from the Roll20 API script Library. Can you fix this Robin since I would really like to use both :)
Another thing i mentioned earlier that I would like to see in CombatTracker is: Make the Marker go to the GM layer before moving on to the next token. This is so the players cannot see which direction a monster they cannot see is. Also I tested a bit, and when a monster is one the GM layer and the Auto Skip is set to false it still announces that that monsters time is up. So lets say I have an Invisible Stalker that the players don't know about (on the GM layer) and it is in the turn order, when the Invisible Stalker's time is up it states that to all players, making the players aware of the Invisible Stalker. Hope this can be implemented, and thank you again Robin your great work.
1540627218
Robin
API Scripter
Dethelm said: I found the culprit to the API crashes im getting. The API called MARK by The Aaron is the one that is crashing the API when typing !ct start or !ct sort. Mark can be installed from the Roll20 API script Library. Can you fix this Robin since I would really like to use both :) I will run some tests with both scripts asap. Dethelm said: Another thing i mentioned earlier that I would like to see in CombatTracker is: Make the Marker go to the GM layer before moving on to the next token. This is so the players cannot see which direction a monster they cannot see is. Also I tested a bit, and when a monster is one the GM layer and the Auto Skip is set to false it still announces that that monsters time is up. So lets say I have an Invisible Stalker that the players don't know about (on the GM layer) and it is in the turn order, when the Invisible Stalker's time is up it states that to all players, making the players aware of the Invisible Stalker. Hope this can be implemented, and thank you again Robin your great work. Ah, offcourse, will look into them.
1540635878
Robin
API Scripter
Dethelm said: I found the culprit to the API crashes im getting. The API called MARK by The Aaron is the one that is crashing the API when typing !ct start or !ct sort. Mark can be installed from the Roll20 API script Library. Can you fix this Robin since I would really like to use both :) Dethelm, I think the following should fix it. Mind testing it? I don't have the time to do the testing today. <a href="https://gist.githubusercontent.com/RobinKuiper/d0afa8d99ecf2424dec359e43f0679d6/raw/05e874d10b834c263d54a55554fc882ff023df20/CombatTracker-Mark%2520fix%253F" rel="nofollow">https://gist.githubusercontent.com/RobinKuiper/d0afa8d99ecf2424dec359e43f0679d6/raw/05e874d10b834c263d54a55554fc882ff023df20/CombatTracker-Mark%2520fix%253F</a>
1540664729

Edited 1540664815
Still getting error, this is what i get: SyntaxError: Unexpected end of JSON input SyntaxError: Unexpected end of JSON input at JSON.parse (&lt;anonymous&gt;) at handleTurnOrderChange (apiscript.js:1773:14) at eval (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:65:16) at Object.publish (eval at &lt;anonymous&gt; (/home/node/d20-api-server/api.js:151:1), &lt;anonymous&gt;:70:8) at TrackedObj.set (/home/node/d20-api-server/api.js:1020:14) at updateLocalCache (/home/node/d20-api-server/api.js:1318:18) at /home/node/d20-api-server/api.js:1608:7 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560 at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) at Kd (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:546)
That error&nbsp; (i think) is originating with the Mark script, not combat tracker. Looking at the script of both CT and Mark, both have a call of handleturnorderchange...but each capitalize it differently. CT's is handleTurnorderChange Mark's is handleTurnOrderChange Based on the error list you provided, due to the capitalization (the 4th error line), it is Mark that is throwing up the error. But I'm not the author of either script, so could be wrong.