rol.count doesn't work...anymore
Posted: Tue Aug 10, 2010 4:40 am
Can anyone explain to me why roll.count all of a sudden doesn't work anymore in this routine (I haven't touched it since the last time it did work:
edit, I've simplified the code, same 'error':
the debug gives as output (in case of 4 extra shots): 2,2,2,2
Last session I ran this (b63) it still worked and now all of a sudden it doesn't. I did try the standard: [COUNT(5, "<br>"): "This is roll " + roll.count] and that does work.
Code: Select all
<!--Output extra hit locations for Full Auto Burst-->
[r,if(extraShotsFullAuto > 0), count(extraShotsFullAuto), CODE: {
<!--Calculate damage-->
[h:getDamage(wpnUsed,govChar,allowRighteousFury)]
[h:output = macro.return]
[h:damage.json = json.get(output,2)]
<!--create damage tooltip-->
[h:TTDamage = formatTooltip(damage.json)]
[h:check = roll.count+1]
[h:pause("check")]
[r:"<b>"+table(extraTable, roll.count+1)+"</b> (<b>"+TTDamage+"</b> dmg)"]
[h:fury = max(fury,json.get(output,0))]
};{}]
simple
Code: Select all
[r, count(extraShots), CODE:{
<!--Calculate damage-->
[h:getDamage(wpnUsed,govChar,allowRighteousFury)]
[h:output = macro.return]
[h:damage.json = json.get(output,2)]
<!--create damage tooltip-->
[h:TTDamage = formatTooltip(damage.json)]
<!--calculate damage-->
[h:damage = formatTooltip(damage.json,2)]
<!--retrieve location-->
[h:location = table(extraTable, i)]
[i=i+1]
<!--text output to chat-->
[r:"<b>"+location+"</b> (<b>"+TTDamage+"</b> dmg)"]
[h:fury = max(fury,listget(macro.return,0))]
[h:bla=roll.count]
[h:pause("bla")]
}]
Last session I ran this (b63) it still worked and now all of a sudden it doesn't. I did try the standard: [COUNT(5, "<br>"): "This is roll " + roll.count] and that does work.