No, nothing in particular. Im just looking forwad to it. Always something exciting and new when you update it. :)
Printable View
No, nothing in particular. Im just looking forwad to it. Always something exciting and new when you update it. :)
is there any way you can get the dice macros to count the number of even dice results as per the Ubiquity powered RPG's?
in Ubiquity powered games get get to roll a pool of dice which can any size as long as the number of sides is even and you count the number of even rolls as your successes. I could do a number d2-1 rolls i suppose
This isn't a particularly big deal, but looking through the desktop/scripts/morecore_trenloe_countsuccesses.lua file I noticed that he sets "rRoll.nMod = 0;" on line 38 which I THINK pulls in if there is a + number at the end of a string. I'm not sure I'm understanding lua scripting right, mind you, but I was wondering if line 70 "rRoll.nSuccessLevel = nSuccessLevel;" could be appropriately modified to something like "rRoll.nSuccessLevel = nSuccessLevel + rRoll.nmod;" to properly output any modifies as additional successes? For example something like /successes 3d10x7+1 would provide anywhere from 1 to 4 successes instead of just 0 to 3 as it would do now (or with, effectively, a +0 modifier). That might satisfy at least one instance I know of where that is used, although there are also instanced where -1 is used in something like Katanas & Trenchcoats (If you don't "keep it fresh" by doing the same action with at least one part of the dice pool being different you are supposed to reduce the result by a success.)
rRoll.nMod is a modifier to the total of the dice rolled. Hence why it is not appropriate to count successes and is set to 0 in the example extension just to be sure - but it's not actually used. The code does not look for anything after the success level - that part of the dice string is not parsed and so is ignored.
However, as you say, it is possible to strip a "modifier" from the dice string and use that in the specific action handler code to adjust the final number of successes. It's probably easier to use something other than nMod modifier (just change the name of the variable, because that's all it is) and code for it specifically, just to avoid confusion in the code - perhaps use something like nSuccessMod. This type of action would need to be coded as the current count successes does not parts any modifier.
This way, adding/removing numbers of successes can be done. It would have to be coded into a specific dice roll handler - perhaps using a similar string with a different action type, maybe /successesmod 3d10x7+1 or something like that.
[Edited since original post to add further thoughts...]
Ok, thanks. Not completely sure I get how to do that. Apparently I need to figure out lua better, first, but the guidance you've provided should be helpful.