[REGISTER] or [LOGIN] to browse without adverts
52 posts / 0 new
Last post
Cthulhu Netobvious
Cthulhu Netobvious's picture
Roll20
Roll20 Player Search
The popular Roll20 Online tool (hoping experienced users guide newbies)
1 vote
+
Vote up!
-
Vote down!

TAJ-07: Technopriest And Justicar Of 7thSea2e

Don Alfonso Sán...
Don Alfonso Sánchez de Ilurdoz's picture

I´ve used it a couple of times and I totally recomend it. You can show pictures of the NPC, maps were the players can move their character, it generates dice rolls (it can add the ressults, choose the highest...) and, of course, you can share voice and video.

As said, totally recomended.

Cthulhu Netobvious
Cthulhu Netobvious's picture

Important Roll20 API guides for developers, since for 7thSea rules we need developers. ;-)

https://wiki.roll20.net/API:Utility_Functions

https://wiki.roll20.net/API:Script_Index

https://app.roll20.net/forum/category/46806

TAJ-07: Technopriest And Justicar Of 7thSea2e

Seth Woolwine
Seth Woolwine's picture

I have asked the creators on the kickstarter if there was any chance we would get some official support for Roll20 as far as character sheets and card decks go. I have not heard anything yet except John Wick acknowledging we asked. I am sure it is doable by us, the community, at the very least anyways.

BluSponge
BluSponge's picture

Based on the QS, a character sheet would be super easy to create. I created one for my Witch Hunter campaign that is super complex, but covering the basics is really simple once you get the formatting down. I might just put on together as a starting point for anyone who wants to run the QS.

As for the cards, you can't really have official support (at least as far as I know). But the PDFs will be easy enough to rip apart and drop into the card fields. Again, easily done.

Tom

Tec Goblin
Tec Goblin's picture

Hi NetObvious! Nice idea about using roll20, I saw your comment in kickstarter. I was thinking more about something that also works on phones (but without the interactive map) and is less text-based. So more of a game-aid (for people playing locally) than a game-platform (for distant games). I also see that code reuse possibilities between roll20 and another app are relatively limited (due to roll20 restrictions: no http, no angular or other data-binding or templating frameworks etc).

So, here's a suggestion:

1) Write the dice rolling code. It's pretty hard, John Wick has by accident created an NP-complete problem I think. We have to make him reason and simplify the raise calculation (particularly the part that you're incited to find the best match in order to starve your DM of unspent dice makes using simple heuristics difficult). I will write it in typescript, compile to js and share it as roll20 utility function.

2) Decide on the character repository. We have to talk to the roll20 guys to see if we could use their repository with external apps - so a player will only have to create his character once and then use both roll20 and any other companion. In addition, we have to see whether roll20 could keep an inventory of advantages, traits and virtues (and see with John if he's fine with that).

3) Based on 2 we'll see if roll20 can be the primary client or not. If it cannot, then the client I was thinking about would have to include character editing, services for saving characters etc. If it can, then the client I had in mind would be just just synchronising with roll20 and be a simple 'roll the dice for my character' version mostly for phones - with offline access. It would be just 'filling the gaps' of roll20, not trying to do what it already does.

Cthulhu Netobvious
Cthulhu Netobvious's picture

Thank you, @TecGoblin for joining up. I too was thinking of writing solution from the ground up. Then some fans here, such as @MorganWolfe and others, suggested tools already existed that were already popular with Role Playing Games.

Thus, I looked into several such options including Fantasy Grounds vs Roll20 vs OpenRPG.

  • Roll20 has a public API; it is not the best, yet the fact they are thinking API makes it seem they understand modern software practices.
  • OpenRPG is built in Java (which is great for programming) but requires Python instalaltion first, so may be too much of a bother.
  • Fantasy Grounds is also popular (DnD5e especially), but still uses LUA as the scritping language (not popular with devs)

 

ROLL20 - API

Core API Details: https://wiki.roll20.net/API:Use_Guide

Examples for API: https://wiki.roll20.net/API:Basic_Examples

 

FANTASY GROUNDS - API
https://www.fantasygrounds.com/modguide/scripting.xcp

 

Here is a subreddit that discusses the three pouplar ones Fantasy Grounds vs Roll20 vs MapTools
https://www.reddit.com/r/rpg/comments/42y2f0/roll20_vs_maptools_vs_fantasy_grounds/

 

Based on my own preliminary review, Roll20 offers the most open API for developers to add new functionality and integrate its core with other applications like the mobile phone clients you are suggesting, @TecGoblin.

It will be nice if we get the ball rolling since the 7th Sea community is pretty strong and diverse.

 

 

TAJ-07: Technopriest And Justicar Of 7thSea2e

Tec Goblin
Tec Goblin's picture

Your research was super useful and indeed it's the right direction! It's not reasonable to build 2-3 alternative apps from scratch, to be used by 1000 people.

But we can follow this idea to the next level: Here's what I proposed to roll20:

https://app.roll20.net/forum/post/3205988/server-api-for-characters-and-...

I think roll20 has a lot of the ingredients to be a platform for all roleplaying apps: one place to save powers, one service to integrate with. But I think they could offer even more. By removing the system-specific logic from their super specific js files and letting us put it in our servers in a REST api, we can more easily mix and match things: It would be sufficient to have ONE implementation of 7thSea roll and powers (let's say a REST Api built by us), ONE implementation of vault and character storage (roll20) and every app would just need to care about how to present the results (with roll20 being the default solution).

It would also help us more easily split the work depending on our skills. Some might prefer converting json to html by hand in roll20, some might working on the REST API rolling dice or proposing related advantages to your rolls, some others might be stronger in building a lightweight companion app for phones which could consume the API.

 

Tec Goblin
Tec Goblin's picture

The idea had already been proposed by one of the users. For those who have voting rights (I don't), you can upvote it here: https://app.roll20.net/forum/post/2645758/slug%7D#newtopic

Cthulhu Netobvious
Cthulhu Netobvious's picture

Roll20 has a lot to gain if they publish their API to the public because if more and more of us use their system, it gets even more popular than competitors like Fantasy Grounds. Hope, that Roll20 will work with us and others like us to bring even more games (like 7th Sea) under its umbrella. yes

TAJ-07: Technopriest And Justicar Of 7thSea2e

Doctor
Doctor's picture

1) Write the dice rolling code. It's pretty hard, John Wick has by accident created an NP-complete problem I think. We have to make him reason and simplify the raise calculation (particularly the part that you're incited to find the best match in order to starve your DM of unspent dice makes using simple heuristics difficult).

I have been looking into the dice rolling problem for a while; it is a supreme pain to model (I am making some headway with, of all things, a TI-83, though), you'd be better off displaying X dice and letting the human do the grouping. I don't think John is going to change the dice. Modeling the cards is a lot easier.

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

I'm not sure why you guys are having such a tough time with the dice rolling code.  I guess if you are expecting the computer to do all the work for you it would be tough to do with Roll20, but you can get pretty close without breaking a sweat.  I put together a campaign for the QS that I've yet to run, but here's what I did:

/roll round((( ?{Trait|Brawn, @{Brawn}|Finesse, @{Finesse}|Wits, @{Wits}|Resolve, @{Resolve}|Panache, @{Panache}} + @{SKILL}+?{Bonus Dice|0} )d10)/10)

This macro is tied to each skill.  What it does is prompts you for which trait you are using with the skill and asks for a number of bonus dice (default: 0). Then it rolls that many d10s and divides the result by 10 and rounds to the nearest whole, which nets you roughly the number of Raises you receive.  The player needs to double check the result because it isn't 100% accurate, but its close enough to work as a guide.  Like the good Doctor said, humans have to do the final grouping.  The equation just takes the edge off.

Ideally, these will be tied to the skills on the character sheet.  But since I only have pregens to work with, I just built them into the Abilities area.

This works in concert with three decks of cards: Raises (helpful for action sequences), Hero Points, and Danger Pool.  In addition to the skill macros, players each have three macro buttons: Risk (pretty much the same as above but just asks for total dice instead of prompts), Action Sequence (same as Risk but adds the result to the Initiative Tracker – this way you know who goes first, second, etc.), and Reroll (to handle rerolls and exploding dice from skill rank bonuses).

I believe this makes for a very accessible combination and doesn't require the API at all.  Any player/GM could use it.  For free.  With nothing but basic Roll20 functionality.

Now, I can think of a couple of nice APIs that would be easy to create:

"Auto rerolls": Rolls the dice and immediately prompts for any rerolls.

"Auto deal": for Action Sequences; you roll your dice and it immediately deals a number of "Raise" cards equal to the rounded result.

A wrinkle I need to work out is spending a doom point to boost the difficulty.  But that's as easy as adding a diffuclty prompt into the core.  Instead of dividing the result by 10, it would divide it by 15.

Now, beyond that, I can almost assure you Roll20 is not going to allow its API or its Character repository to be accessed by external apps.  If you want to create a 7th Sea App, that would be smoking cool, but it would work outside the roll20 framework.

Cthulhu Netobvious
Cthulhu Netobvious's picture

Thank you, @BluSponge. That was very informative, especially how you already got a work-around for 7th Sea raises.

Roll20 is still the most friendly API for developers, though I suspedt Fantasy Grounds (from what I have seen) is better for players (overall deisn of the user interface).
 

TAJ-07: Technopriest And Justicar Of 7thSea2e

BluSponge
BluSponge's picture

Thanks, CN.  I can't take all the credit though.  Plenty of people early on noticed you could just divide the total roll by 10 and come up with the approximate number of raises.  It still requires some player input but ANYONE could use these macros and techniques without having to subscribe to the monthly service.  Is it ideal?  No.  But what you don't get you make up in accessibility.

FG and Roll20 are interesting beasts when it comes to support.  I love the look of FG, but they don't have a mac client.  Also, since I seem to be the only one out there playing Witch Hunter: The Invisible World online, the set up would be enormous.  If I was JWP and wanted OFFICIAL support for 7th Sea, I would probably go with FG.  They already handle support for DnD5 and Savage Worlds.  Roll20 isn't really set up for that level of "official" support.  Though it would be nice for the devs to build in some official tools to support the dice mechanics of 7S2.

I should also point out that there are some cool CSS tricks that could be employed with a character sheet that could make skill rank bonuses easier to manage.  For the Danger Pool boosting difficulty, a lot of GMs use a "dummy token" on the screen to do things like this.  Basically, you have a danger token on the screen that sets the difficulty at a default (10 in this case), but you (the GM) can boost it (to 15).  All dice rolls could tap into that token value.  The trick would be remembering to reset it – or you could use the API to do that for you.

Anyway, there are hundreds of tricks people have figured out.  And the forums are VERY helpful and newbie friendly.  Character sheets, once made, are available to anyone for free (you need a premium subscription to create one or use a custom one, however).  I'll probably start the process of creating one once we have an official character sheet to go by.

Tec Goblin
Tec Goblin's picture

I'd disagree with both you and the Doctor. Calculating raises is so hard that I saw it bringing games to a slog when players decided to optimise the best way in order not to leave any leftover dice for the GM to steal. For people playing in the same tabletop (most), it's THE killer feature. The other features of roll20 are not vast improvements over paper (unless you place from afar of course).

We have to try to do it. I still try to bring some sense to John to make it easier or at least less important to use all leftover dice, but if we actually want to find the best solution to this problem, it's I think NP Complete. It's around 1000 operations per roll, but still within the realms of what even a phone can do quickly.

A naïve algorithm (which can have some optimisations): calculate all possible combinations of dice groups with a sum less than 18 (but in which if you remove one dice it's less than 10)*. Take the one with the most raises and least leftover dice. Finding all possible combinations of dice groups is an exponential problem, but the constraints might in practice reduce it to something more reasonable.

*I was into a more precise alrogithm than that, involving first taking out 10s directly as raises, then creating the first set of dice groups by adding a number to the group as long as the sum remains <=Max(10, 10+the smallest element already in the group). This is a pretty quick way of creating a dice group, and as long as the first is created it'd be continuously easier to create the rest. But then, creating all possible *combinations of dice groups* could be slow. A first optimisation trick is to have a very efficient hashkey of the different combinations (and of individual groups), so that you can easily verify if one set has been already created, but there're more tricks to do in order to exhaust all possibilities in an efficient order. I think of doing some combination of heuristics: once you've found a combination (let's say 3 dice groups), remove the last dice group and start searching from the number after the next you've used last time. Then recursively do the same for the second group etc. It won't find ALL combinations, but that's what I try to avoid. With some rules and heuristics we might be able to almost reliably find one of the optimal solutions in fewer operations.

Once I have a first try I'll post it here and I'll give it to a mathematician friend to improve it.

BluSponge
BluSponge's picture

I think we're talking about different things here.

As far as its application in Roll20, I'm not trying to find optimal combinations.  I just have the macro round everything to the nearest number.  So if I roll 4 dice and get 9, 2, 1, and 7 (19), the macro will tell me I have 1 raise.  There are some combinations it will return an incorrect result, in that the player may be able to add a raise to the mix.  But it works well enough at a glance to keep the game running smoothly.

I think if you and your players are the types to obsess endlessly about finding the optimal combination to rob the GM of dice to buy, you are playing by the letter but against the spirit of the rules.  Remember that the GM isn't ALWAYS obligated to by off your extra dice for the Danger Pool.  By comparison, this would be like never spending Drama Dice in 1st edition 7th Sea because doing so would add to the GM's pool of Drama Dice.

But that is a completely different argument from the one I'm making.  That with very little effort you are able to create a functional dice rolling macro for 7S2 on Roll20 that anyone can use without having to resort to paying a monthly subscription and employing the API engine.  And it certainly doesn't require gigaflops of computer power to render an adequate result.  Sure, I would love it if I could sort the virtual dice on screen into nice clusters of raises (something I might be able to do on FG, I don't know), but I can't so let's not quibble over it.  There might be a way to use an API script to "optimize" your dice into raises but that is going to cut into your accessibility to a certain degree.

As to whether or not JWP is going to dump the core mechanic they've presented to the world at the 11th hour and replace it with a standard "roll d10s and count 5s"?  Magic Eight Ball says that is "highly unlikely."  But I'll agree it would be worlds easier to work with in some respects on R20 since the mechanical support is already there.

Red Jenny
Red Jenny's picture

I'm a sysadmin, not a coder, so my code fu is comparatively weak, but wouldn't an algorithm like this work?

Clear dice pool array

Clear raises counter

Roll x dice, add them to pool.

Find all tens, count them as raises, remove them from pool.

Find all nines.

     For every nine, find a 1. remove sets from pool. increment raise counter

     If still more nines, for every nine, find a 2, remove sets from pool. increment raise counter

     etc.

    If still more nines, for every nine, find an 8, remove sets from pool. increment raise counter

    If still more nines, for every two nines, remove set from pool. increment raise counter

Find all eights.

    For every eight, find a 2. remove sets from pool. increment raise counter

    If still more eights, for every eight, find a 3. remove sets from pool. increment raise counter

    etc.

    If still more eights, for every eight find a 7. remove sets from pool. increment raise counter

    If still more eights, for every two eights, remove set from pool. increment raise counter

ETC.

Find all fives

   for every two fives, remove set from pool. increment raise counter

(see asterisk*)

Count all remaining dice in pool. This is the remainder for GM use

 

* I haven't read the QS, so I don't know if you can do raises with more than 2 dice, but if you could, then the algorithm gets more complicated, as you have to factor in 1s under the 'find all eights, sevens, etc.), and you have to go down past 5 through 'find all fours, threes, twos, ones' to see about making complete sets.

 

I'm not sure how many cycles it'd take to process it, but I think that would provide a reasonable approach to dice counting for raises.

Morgan Wolfe
Morgan Wolfe's picture

My code-fu is mostly from the 80s-90s, so I'm staying out of this one, other than to say yes, you can use as many dice as needed to make a raise. If you roll four dice and get 4-3-2-2, it's one Raise (with a "dot" left over).

Morgan Wolfe
aka Capt. Doña Sir Kestrel of Avalon http://silver-gateway.com/7sea/

Doctor
Doctor's picture

* I haven't read the QS, so I don't know if you can do raises with more than 2 dice, but if you could, then the algorithm gets more complicated, as you have to factor in 1s under the 'find all eights, sevens, etc.), and you have to go down past 5 through 'find all fours, threes, twos, ones' to see about making complete sets.

And there, my friend, is the pain in the butt. Not only can you make sets with as many dice as needed, the optimal arrangement is the arrangement of sets which leave the fewest dice remaining (So if your roll is 8,8,3,2,1,1, the optimal arrangement is [8,3],[8,1,1],[2] not [8,3],[8,2],[1,1]). For number X, you would have to factor in numbers equal to (10-X) as well as possible arrangements of all numbers equal to or less than (10-X-1). Also, Raises only have to meet or exceed 10, so for a roll of 8,7,3,2,2,2, the optimal arangment it [8,2][7,2,2][3] not [8,2][7,3][2,2]. Moral of the story? It gets hediously ugly fast. Basically, 10s are easy, everything else goes to s*** at high speeds. Even with 9's, you can't just "find 1's" because if the roll is 9,7,2,1 the optimal arrangement is [7,2,1][9] not [9,1][7,2]. Basically you need to test all possible combinations within every possible permutation (ordering). Finding a way to do that efficiently is "a non trivial problem in computer science" and if we were to find an elegant solution, we should form an LLC immediately. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Tec Goblin
Tec Goblin's picture

I think still the base is fine for the number of dice we're talking about. If we don't have to starve the GM of danger points, I think the process of 'find combinations with sum 10, remove them from the pool, then find combinations with sum 11, remove them from the pool' etc can be easily modeled.

If we convince John just to remove the dependency of the danger points on the unused dice then we could quickly find a 'good enough' result.

 

Doctor
Doctor's picture

While changing John's mind is not impossible (I'm living proof), it's going to take a very good reason and I don't see him bending to "I can't model this well on a computer." I think we might be better off just producing a code which presents all the arrangements which yeild the highest number of raises and leave the selection to a human. For a roll of 8,5,1,1,1,1,1, it would present [8,1,1][5,1,1,1], [8,5][1,1,1,1,1], and [5,1,1,1,1,1][8] and the player can select the option which suits her best. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Bradley
Bradley's picture
I don't know about John, but I would take pride in designing a system that shows that humans are still clearly better about some math operations than computers.
Doctor
Doctor's picture

While I agree with that 100%, there is a less flattering implication: "I have created a system that is nearly impossible to model" means "It is on an extremely order of probability that I did not actually model it, which means I really only have best guesses as to how things like Rank Bonuses actually play out." I think John and JWP would actually appreciate fans crunching the numbers on their behalf. I am working up an email about the problem with the Cards system and how it might be fixed; they might ignore it, but they might not. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Tec Goblin
Tec Goblin's picture

No, humans are not better for calculating the raises. If you want to starve the GM of unspent dice, as a human you have to do thousands of tries as a computer, which makes it practically impossible. What you do is just abandon, and stop at a match which looks 'good enough'. But the computer can do that too.

BluSponge
BluSponge's picture

Ok, I'm going to ask again, why do you want to starve the GM of unspent dice? What real purpose does that serve?

Doctor
Doctor's picture

@BluSponge

Gaining Hero Points

• The GM buys any dice that aren’t part of a Raise. The GM gets one Danger Point per die bought in this fashion, but the player only gets one Hero Point.

- Quickstarter, pg 8

 

@TecGoblin

No, actually we don't, because the human brain naturally and efficiently eliminates unnecessary tests, dramatically shrinking the search space. 

https://www.youtube.com/watch?v=7sSDB_jLSTs

 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

Doc,

Once again, here I feel TG is playing to the letter and not the spirit of the rules. He's setting up an adversarial relationship with the GM when the focus should be on the scenario at hand. The GM isn't always obligated to buy up dice, so spending every roll trying to find the most optimal array of dice is a wasted effort.  At some point, you are going to roll badly and the GM is going to step in, collect his Danger Pool dice and give you a HP for your trouble. Therefore, the only time you have to worry about optimizing your arrays is when you roll POORLY. So this whole business of "starving the GM of dice" is counter productive. And, ill add that if I were running a game where the players made a huge issue of doing so, to the detriment of play, I'd house rule around it. Because as the GM, my job is to make the game challenging, entertaining, and memorable. Not play some half ass game of cat and mouse with you over how you make your 10s.

Doctor
Doctor's picture

My interest in optimal arrangements is predominantly academic: without a concern for optimal arrangements, the problem becomes fairly easy because I only need to find at least one arrangement which yeilds the highest number of raises instead of the best of all possible arrangements yeilding the same result. I can't speak for TG, but I can say that it's the issue of optimal arrangements that makes the problem interesting from a mathematical and computer science point of view. Finding a good answer as to how to efficiently solve it would be quite an achievement.

 

Ultimately, however, the importance of optimal arrangements will have more to do with GM's decisions about Hero/Danger Point economy than anything else.

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

I get the point of statistical modeling to a certain degree, though I suspect you are going to hit diminishing returns at some point.

And I'll admit, I could be misreading TG's intent. I'm only going by his comments in this thread. The relationship between himself and his GM may be different than the one I try to foster with my players. I have two players that would be good candidates for the level of intensive scrutiny of the meta game that TG espouses. I'm not interested in the meta-game being the focus of play. It's a tool that either makes the rest of the game fun or becomes a distraction.

Doctor
Doctor's picture

Part of the desire to solve the problem with computing, I think, is actually to eliminate the meta-game aspect entirely: if the computer automatically produces the most efficient arrangement, then there is no need for the player to think about it or expend any energy attempting to "game the system."

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

I've posted a couple of queries on the Roll20 forums to see if there are simple solutions to some of the issues I've outlined above.  I'll share once I have some answers.

BluSponge
BluSponge's picture

And got a nice little hack for rerolls that may/will work amazingly well when implimented.

OTOH, using the API to deal cards based on dice results isn't allowed.  So that aspect will still have to be handled manually.

Doctor
Doctor's picture

"I'm not sure why you guys are having such a tough time with the dice rolling code...Then it rolls that many d10s and divides the result by 10 and rounds to the nearest whole, which nets you roughly the number of Raises you receive.  The player needs to double check the result because it isn't 100% accurate, but its close enough to work as a guide."

 

The reasons for the tough time is the degree of difficulty in going from "close enough" to "correct." The issue is that for any total of X, the answer in Raises is either (X/10) or ((X/10)-1); determining which, and how many dice are left over is the hard part. It is so hard, in fact, that I am not sure a computer can efficiently do it compared to a human. While I disagree that it will grind things to a halt once people have some experience in the system, it would not surprise me if it slowed things down initially. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

Fair enough.

My experience with online tabletop is that if you manage to take the dice completely out of the players' hands, you remove something in the spirit of the game.  I'm not sure I can put my finger on why.  But leaving the player to do certain things instead of leaning entirely on the computer often nets improved play results. So, as far as I'm concerned, letting the players assemble their own raises is a good thing.  In fact, the only reason I kept the "X successes" in my macro is that getting rid of that is more trouble than its worth.

Doctor
Doctor's picture

My interest is in creating accurate models so I can tell what various changes to the system might do. My reasons for doing this are simple: I am pretty sure JWP did not model this system, which means I am pretty sure they have no idea how powerful the Rank Bonuses are. I'd like to figure that out, as well as a way to fix the Cards system, which right now yeilds significantly lower totals than using dice but could, I think, be amended to work out better, 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

BluSponge
BluSponge's picture

Doc, 

I assume you are familiar with this site.  The input code is too complex for me, but it should be able to help with a lot of the modelling.

Doctor
Doctor's picture

I am very familiar. The closest I have been able to come on Anydice is 38 million operations, which, obviously, times them out. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Tec Goblin
Tec Goblin's picture

I understand what you say, but in this case many players won't enjoy at all this process of calculating raises. This constant feeling that 'you could have done it better'. Either the whole group decides to switch to the card system, or those players will get some help ;).

 

But point taken, calculating raises should be optional in the program.

Doctor
Doctor's picture

The card system is in need of some fixing as well. See the "Dice Results" thread. 

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Cthulhu Netobvious
Cthulhu Netobvious's picture

Here is the "Dice Results" thread.

http://www.7thsea2e.com/port/forum/dice-results

TAJ-07: Technopriest And Justicar Of 7thSea2e

BluSponge
BluSponge's picture

Thanks, CN.

Doctor
Doctor's picture

Just updated that thread with a breakdown of the odds for two through seven card hands.

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Doctor
Doctor's picture

I may (emphasis on "may") have found a way to efficiently model the dice rolling for a standard roll. It all goes to dogs at the Rank 4 Bonus, but I think as long as a Raise is simply ≥ 10. When it becomes Raise =1 if Set ≥ 10 OR Raise = 2 if Set ≥ 15, then I am back in the same mess.  Will report when I have something concrete.

“Every normal man must be tempted at times to spit on his hands, hoist the black flag, and begin to slit throats.”
- H.L. Mencken

Tec Goblin
Tec Goblin's picture

I am ready :). You can test it here: http://7thsea.azurewebsites.net/

The core of the logic is at the Roller file. This is split in 3 parts:

  • The Roller.ts (that's the source Typescript file, pretty readable and quite easy to write).
  • Roller.js.map (this helps your browser's F12 developer tools understand the .ts file)
  • Roller. js (that's the actual file which the browser runs. It's plain javascript, without any libraries required. You can run it everywhere, and use it in Roll20).

The test app has of course also an .html page, as well as an app.js (backed also by an app.ts and an app.js.map) which allows any user test the Roller logic. There's also a 'test suite' which you can run to see how the algorithm behaves in various scenarios.

Technical Details

I'm pretty happy with how it turned up. If you spot a bug, please tell, but in general it's been tested and:

  • ​It covers all scenarios covered by the rules (exploding, increasing the target number, rerolling, double raises for skill 4 etc)
  • It is really fast. It takes 2ms for a 10-dice roll, and from that moment onwards it's practically O(n), adding around +1ms for every 50 extra dice. The trick is to sort the dice in an ordered structure as they're rolled. When OrderedResults[5] = 3 it means that I've rolled three 5s. As I'm looking for groups, it's really fast, because I start from 10, and I check 'which is the number I need to reach the target number? 5? Ok, do I have any 5s?-> that's super quickly to check if you have a lot of dice. Once few dice remain in the pool, then you need to start some heuristics 'ok, I don't have a 5, do I have a 4? Ok, then I'm looking also for a 1'. If there're not any more groups summing up to the target number (usually 10), then I look for groups of TN+1, TN+2 etc...
  • It has behaved pretty well with every crazy combination I threw at it... I've sorted out a few bugs in the process of course. I have not mathematically proven yet that it will find always the best number of raises, but I think it does. It does NOT try to minimise unused dice, though (for reasons I explained in other posts).
  • It respects the principle we discussed of separating rolls + raise calculation. If players prefers to do the second manually, they can still do.
  • It can run practically everywhere. Feel free to reuse the code. You can also use it on your phone - it doesn't look nice but it works. I might build a mobile-friendly website and/or wrap it up as a new version of my Goblin Dice Roller for windows store just to make it easier to access it offline. But even now, if you want to save the page for offline access, it will work.
Cthulhu Netobvious
Cthulhu Netobvious's picture

Excellent work, @TecGoblin. Nice to see the mechanics so well distilled in a reusable micro-app. cool

7thsea2e-raises-dice-roller-test-console-preview

TAJ-07: Technopriest And Justicar Of 7thSea2e

Tec Goblin
Tec Goblin's picture

Thanks for the kind words! This screenshot makes the app look cooler than it is ;)

Tec Goblin
Tec Goblin's picture

UPDATED with support for advantages giving +1 to all dice results (for some skills), as well as fate lash penalties (when the DM blocks you for using dice with value lower than the number of your fate lashes).

The latter was trivial, but the first one was a bit annoying to implement (having die results of '11' broke some things).

Tec Goblin
Tec Goblin's picture

UPDATED now it actually looks nice, even on mobile. It should work beautifully on 4,5'' screens and above, it might need some zooming on smaller screens.

Many minor usability improvements have been made. If someone's using a screen reader, please report any issues you find.

Cthulhu Netobvious
Cthulhu Netobvious's picture

Very nicely done. Just one observation, after you press [Roll] you need to press [Calculate Raises].

Is this preferred to automatically calculating the Raises?

I also created a permanent link to your wonderful app via Online Tools Thread,

http://www.7thsea2e.com/port/forum/7th-sea-dice-roller-app

TAJ-07: Technopriest And Justicar Of 7thSea2e

Tec Goblin
Tec Goblin's picture

Good news: it seems our feedback has been heard, and the new preview disassociates heroes' rolls from the danger pool. Thus we can have a quite simple and fast algorithm finding a 'good enough' set of raises :). I'll come back with the actual code one of those days...

Myridian
Myridian's picture

Page 177, 4th bulleted point under Gaining Hero Points.  Villains are still able to buy dice for the Danger Pool.

Personally I think the rule is great, as the GM I get more points and give more points building a strong Hero Point economy.

"...for it is the deeds of weak and mortal men that may tip the scales one way or the other..."

Pages

share buttons