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 .
×
Create a free account

How do I make a handout that does math?

I am in a game where players have a business and record profits/losses to a hand out. Is there a way to make it so I can simply plug in the numbers and the handout calculates the total profit/loss for me then add it to the balance? Having to do math is slowing our games down.
1463584528

Edited 1463584871
Ziechael
Forum Champion
Sheet Author
API Scripter
If you want to have something that you can quickly +/- values from I would recommend setting the business up with a journal entry. That way you can set up some attributes (they don't have to be from the character sheet you are using) that you can then also link to a token, that way, using the bubbles on the token, you can quickly amend the values using mathematical expressions. You can then also use roll templates coupled with @{...|...} attribute calls to output to chat, either in full or as a whisper, the stats of the business anytime the players need to reference it rather than having to open the handout each time... set that up as a global macro and you are laughing all the way to the bank :) Bear in mind, when using the bubbles to do maths, if you want to use anything beyond + and - you will need to put the base value in first: eg. if your starting value is 10; typing +5 into the bubble and pressing enter will get you 15, likewise -5 would give you a result of 5. To multiply or divide you'd need to type the full sum into your bubble, 10*5 or 10/5 and press enter to get 50 or 2 respectively.
In my game they have a link to a spreadsheet on google docs, they all have a link and fairly complicated  results are there in a flash.
1463592940
Ziechael
Forum Champion
Sheet Author
API Scripter
al e. said: In my game they have a link to a spreadsheet on google docs, they all have a link and fairly complicated  results are there in a flash. That is exactly how my players stronghold/island management business went in the end, I started with a journal but then ended up with a spreadsheet for all those juicy formulas :)
1463612139

Edited 1463672000
This is literally a board game where we add/subtract money every turn. Every player just has a 10 turn hand out sheet to do their book keeping. I want to keep  everything in the roll20 room if possible.
1463612522
The Aaron
Pro
API Scripter
Can you give some more detailed examples?  What is the board game?
1463648848
Ziechael
Forum Champion
Sheet Author
API Scripter
Kristopher R. said: This is literally a board game where we add/subtract money every turn .  In that case I would certainly have character journals set up for each business with tokens on the tabletop, then by linking attributes to the bubbles you can very easily +/- from the values.
The Aaron said: Can you give some more detailed examples?  What is the board game? Hansactica. It is a board game invented by the Blue Bug Bear collective and being play tested on roll20. In it each player is a merchant that has caravans travel Europe buying/selling goods and buying up towns in a bid to control the market. The player with the most gold/assets after the final turn is the victor. Currently the game is 20 turns with two 10 sheet hand outs per player. Right now each sheet and token is assigned by color. Each player starts with 1 caravan and can buy more after requirements are met. So the game has the player fill out columns every turn on the hand out doing the profit/loss math by hand and updating their balances. There is a sort of drag in play time because of the book work. I was hoping to add a simple script to a hand out that did the math for the player. Every session is a new game with different players.
1463672925
The Aaron
Pro
API Scripter
I can't think of a way of doing this without either custom character sheets or the API. How much variation is there in the amount you area adjusting by?  Can you post an example of one of the completed sheets?  Maybe we can come up with a clever way of at least making the math fast...
1463673632

Edited 1463673640
Ziechael
Forum Champion
Sheet Author
API Scripter
The math can be done in the chat pane easily enough with inline 'rolls'... consider it an in-game calculator?
Year Trading Profits Trading Investments Caravans in Play: 1 Hanserstaats Controlled Tribute Other Losses Balance: 200 1 0 7 copper for 42 1 0 0 0 158 Notes: 2 0 0 1 0 0 0 158 Notes: 3 0 0 1 0 0 0 158 Notes: 4 0 0 1 0 0 0 158 Notes: 5 0 0 2 0 0 0 108 Notes: 6 Notes: 7 Notes: 8 Notes: 9 Notes: 10 Notes: That is the current character handout. He made it a handout so all players can see each other's logs. You can't really see the mechanics on another person's character sheets.
Ziechael said: The math can be done in the chat pane easily enough with inline 'rolls'... consider it an in-game calculator? How do you do that exactly?
1463674149

Edited 1463674229
Ziechael
Forum Champion
Sheet Author
API Scripter
Any standard mathematical expressions you need can be done in the chat using inline rolls, eg. [[(100*74)/3]] would output as 2466.6666666666665 in chat, this could be prefixed with text if needed too for a result like 'Player A's Profit: 2466.6666666666665'. Do you have an example of the kind of sums that are slowing your players down? With examples we may even be able to suggest universal macros that could be put in place to make the math super quick so that the slowest part would be updating the handouts? 
1463674240
Gold
Forum Champion
Kristopher R. said: Ziechael said: The math can be done in the chat pane easily enough with inline 'rolls'... consider it an in-game calculator? How do you do that exactly? Here is the Roll20 wiki doc for "Math-only rolls" in the chat-room, <a href="https://wiki.roll20.net/Dice_Reference#Math-Only_R" rel="nofollow">https://wiki.roll20.net/Dice_Reference#Math-Only_R</a>... This may help with your quicker calculations, but unfortunately it wouldn't be automated to your game or handout, so you would still be inputting the money numbers into the calculator to do the math.
You must add trading profit subtract trading investment add tribute then subtract other investments and apply the result to previous balance to get the new balance. The math is simple enough, but when you are gaming with 7 people and each one has to stop to update the books every turn it slows things down. My idea was to have the computer do the math and speed up the game as a whole.
Gold said: Kristopher R. said: Ziechael said: The math can be done in the chat pane easily enough with inline 'rolls'... consider it an in-game calculator? How do you do that exactly? Here is the Roll20 wiki doc for "Math-only rolls" in the chat-room, <a href="https://wiki.roll20.net/Dice_Reference#Math-Only_R" rel="nofollow">https://wiki.roll20.net/Dice_Reference#Math-Only_R</a>... This may help with your quicker calculations, but unfortunately it wouldn't be automated to your game or handout, so you would still be inputting the money numbers into the calculator to do the math. Well that is all i really need. Thank you.
1463674841
Ziechael
Forum Champion
Sheet Author
API Scripter
Easy enough with a macro then, quicker with attributes set in a sheet ;) Option 1: [[?{Profit|0} + ?{Tribute|0} - ?{Investment|0} - ?{Additional Investments|0} + ?{Balance|0}]] Option 2 (with a sheet holding some attributes): [[?{Profit|0} + @{player 1|tribute} - @{player 1|investment} - @{player 1|additional investments} + @{player 1|Balance}]]
1463676715
Gold
Forum Champion
Yes, that would be more elegant with Attributes (Player B's Investment, Player B's Balance) and/or Queries (a pop up that asks what your Investment for this turn will be, and enters your numerical answer like a variable into the pre-defined calculator), like the way Z has suggested.
So instead of a handout give each player a character sheet? Is there a way to have it so all players can veiw the sheet?
1463693763
Pat S.
Forum Champion
Sheet Author
Character sheets can been assigned to everyone or just a few in the manner of who can see it and who can edit & control it. Open the sheet and up in the right top corner is the edit button, click on it then choose view and edit as to who can do what.
I tried that in other games and the only time players could see my attributes is if they were set to edit. They could not see them if just set to view. The game maker wants it so player A can just look at Player B's score card and see where player be is wothout being able to edit player be.
1463759984

Edited 1463760151
If a player cannot Edit & Control a Character, the only part of the Character Window that they are able to view is the Bio & Info Tab . However, players can&nbsp;pull information off Character Sheets by using Attribute calls with the 'target' keyword on Tokens that Represent Characters . So, you could set up macros for your players which pulls a bunch of information from their sheet (and outputs it to the text chat, whispered to themselves). e.g. /w "@{selected|character_name}" &{template:default} {{name=@{target|character_name}'s Records}} {{Year 1 investments: @{target|invest1} etc.}}
Considering I have to make brand new score sheets every session and assign them to players, this is just too much work. But thank you for answering my question.
1463934494
Pat S.
Forum Champion
Sheet Author
There is an API script that let's everyone in the game create blank character sheets that are assigned to that person. You could setup a macro to have that so the players could create their own sheets and pull the needed info to fill out the sheet on their own.