Page 1 of 1

Dice Roll Simulator

PostPosted: Fri Dec 08, 2006 12:38 pm
by WidowMakers
I was playing a game yesterday and was wondering how many armies it would take to get a specific territory. I did not want to just try and fail. I needed to see what the chances were I would win. I looked on google for a program that would simulate d6 dice rolls (3 attacker against 2 defender) until one of them loses. I could not find any. So, I made one.

The link below is an excel file at allows you to simulate attacking and defending with any number of armies. I uses a few macros. Not overly complex. Just thought I would share this with anyone who wanted it. Feel free to give input on possible improvements to it.

http://jmhooton.iweb.bsu.edu/joel/diceroller.xls

PostPosted: Fri Dec 08, 2006 1:46 pm
by tals
I use excel 2003 - when I run it I get undefined variable ?name appearing in all the spots. Any thoughts?

Otherwise - nice idea!

PostPosted: Fri Dec 08, 2006 9:06 pm
by WidowMakers
I just downloaded the 2003 trial. You need to install the analysis toolpack in the Tools> Add-ins section. That enables some of the functions that I used. Let me know if this works. Also I noticed that Microsoft had an update for excel 2003 related to the randbetween function i used.

http://www.microsoft.com/downloads/deta ... laylang=en

Excel 2003 Update: KB834691

Let me know if that works

i have problems

PostPosted: Fri Dec 08, 2006 9:10 pm
by cricket
i have excel 2000. dont know if that works. i opened the thing and when i set the number of armies and pressed roll dice, i got #NAME in all the cells.

Any ideas why?

PostPosted: Fri Dec 08, 2006 9:15 pm
by qeee1
This : http://bartell.org/cgi-bin/risk.cgi provides a similar function.

PostPosted: Fri Dec 08, 2006 9:23 pm
by Evil Semp
Where do you get your dice rolls from? Wouldn't you have to get them from the same place CC does to get accurate results?

PostPosted: Fri Dec 08, 2006 9:33 pm
by WidowMakers
1 (Error) If it does not work you need to make sure the Analysis Toolpack is installed. Under Tools>Add-ins.

2 (Random #'s) I just used the randbetween function in Excel. I don't know how to get the rand info from the site that CC uses.

3 (Why) Again I was bored and had an hour to kill. I just wanted to see if I could make it. If anyone wants it then here you go.

PostPosted: Fri Dec 08, 2006 9:34 pm
by Evil Semp
The reason I asked is it seems that the defensive dice at times are real strong.

PostPosted: Mon Dec 11, 2006 7:38 am
by JTKALLTHEWAY
wow, you guys are nerds, lol

PostPosted: Mon Dec 11, 2006 9:09 am
by Nikolai
It's not supposed to tell you whether you'll win or lose - it just tells you what the odds are. And it can, and probably will, be wrong a fair amount of the time - odds, after all, deal with chance.

Dice Simulator using Random.org data

PostPosted: Mon Dec 11, 2006 9:36 pm
by WidowMakers
I added the Random.org data to the excel program. The file takes requests data from random.org for 3 attacking dice and 2 defending. Then it determines the number of dice each player can roll. It the sorts tem highest to lowest and determines the winner.

There are two versions because excel apparently changed the way they sort data between the two versions.

Excel 2000
http://jmhooton.iweb.bsu.edu/joel/dicer ... 202000.xls
Excel 2003
http://jmhooton.iweb.bsu.edu/joel/dicer ... 202003.xls

Make sure your Tool>Add-Ons>Analysis Pack is checked on