Page 1 of 1
Electronic random table
Posted: Thu Jan 26, 2017 11:29 pm
by RainbowDevil
Hey folks,
Has anyone ever discovered a way to make random rolls on tables, but electronically, ideally even an app? What I'm looking for is a way to take the random animal table from the TMNT games and get the programme to choose a random result. The problem is you can't just use normal random number generators, since you have to roll on several tables. Obviously, it's pretty easy to just do with dice rolls, but then the main purpose of it is to have a random animal generator without having to detract from the gaming session. At this stage I tend to roll up the animals I'll use in advance so it doesn't slow down the gaming, but when the PCs do something unexpected, it'd be nice to just say, "And you come across a mutant... (*presses button on app*) ...platypus!"
Regards,
RD
Re: Electronic random table
Posted: Thu Jan 26, 2017 11:45 pm
by Glistam
I've built stuff in MS Excel using the vlookup and randbetween formula functions. I used those to build a functional random monster generator from the tables in the original Rifts main book.
Re: Electronic random table
Posted: Thu Jan 26, 2017 11:57 pm
by RainbowDevil
Thanks for that, Glistam. I'd better go and study Excel properly then! I haven't used it for over 10 years
Re: Electronic random table
Posted: Fri Jan 27, 2017 8:54 am
by ShadowLogan
I never did TMNT/HU/ATB mutant animals, but I did do a Rifts Oni Generator (WB8) and a Rifts Monster (RMB) in Visual Basic for Applications (w/n MS Access to a form so its not stand-alone) both of which where migrated from Qbasic (which could run alone or via QBasic), both of which where randomly generated results. IIRC I also did the town/city generator, and I know I did an SQL one for random (RT2E) IMUs (it only works properly in Access 2000, I haven't gotten it to work properly in LibreOffice Base).
What you are asking for should be possible. It stands a good chance of being highly complex since those tables aren't setup for random results so you need to work out a selection mechanism (to spend BIO-E, or ditch BIO-E and work out your own table break down for size, powers, degree of mutation, background, etc but this has the chance of introducing non-RAW results since BIO-E expenditure could come out more than is possible). You'd also need to work out if you want to have a look up table(s) for the animals to allow for easy changes (say you get a new book with mutant animals, you could add them in by adding to the table, or you don't like the RAW stats and go with your own, etc) versus hard coding each entry into the code (which means you need to go into and edit the source code if you need to make changes).
Re: Electronic random table
Posted: Mon Jan 30, 2017 4:03 am
by RainbowDevil
Thanks for that, ShadowLogan. I'm not looking for anything so complicated - purely something that works out the animal type.
Re: Electronic random table
Posted: Mon Jan 30, 2017 4:04 am
by RainbowDevil
I'm not after something that also calculates its BIO-E, stats, etc.
Re: Electronic random table
Posted: Mon Jan 30, 2017 9:23 am
by ShadowLogan
RainbowDevil wrote:Thanks for that, ShadowLogan. I'm not looking for anything so complicated - purely something that works out the animal type.
If it is just the animal type and you are not worried about what mutations it has, that is A LOT SIMPLER to execute.
EDIT
I wouldn't necessarily go with Excel (or spreadsheet). However, with MS Office Access (or LibreOffice's Base, or likely any SQL ready database) you could create a table, and then use a query to do the work. The nice thing about the query is that you can add to the underlying table and the query will adapt without any changes, unless you decide you need more information (ex. you expand the number of fields at a later date to provide information on).
Here is what the SQL would look like assuming you just have one field ("Mutant Animal Type") in Table (Animals):
SELECT "Mutant Animal Type", RAND( ) "Exp1" FROM "Animals" ORDER BY "Exp1" DESC LIMIT 1
You can add more Fields if necessary and even filter the available pool by adjusting the SQL. This should work with any SQL capable database (such as Access or Base), though there is a chance some slight adjustments to the SQL might be needed (ex. I did an SQL quick random IMU generator for 2E RT, the code worked as intended in Access, but not Base when I tried to do a complicated query in one pass, the individual parts in Base worked, but when doing them with together it failed to operate as intended using the exact same syntax)
Re: Electronic random table
Posted: Mon Feb 27, 2017 5:23 am
by Natasha
RainbowDevil wrote:Hey folks,
Has anyone ever discovered a way to make random rolls on tables, but electronically, ideally even an app? What I'm looking for is a way to take the random animal table from the TMNT games and get the programme to choose a random result. The problem is you can't just use normal random number generators, since you have to roll on several tables. Obviously, it's pretty easy to just do with dice rolls, but then the main purpose of it is to have a random animal generator without having to detract from the gaming session. At this stage I tend to roll up the animals I'll use in advance so it doesn't slow down the gaming, but when the PCs do something unexpected, it'd be nice to just say, "And you come across a mutant... (*presses button on app*) ...platypus!"
Regards,
RD
For selecting an animal randomly I have written a quick example here
https://jsfiddle.net/november_kilo/oLfeLqmo/ This is the random animal selection table from the TMNT book. Adding other categories of animals (or just a catch all category) would not take much work. Is this what you were looking for?
Re: Electronic random table
Posted: Fri Mar 03, 2017 1:59 am
by Natasha
At a request I have made the example randomly select a category and then randomly select an animal from that category by default, which is how it works in the book.
While I was doing that I made it so the selected animals are remembered.