Need help with Prompts

Here it is so far...............

; Foraging Alchemy 2.ipt
; created 4/28/2021 10:49:14 PM

Prompt: People Searching
Prompt: Hours Searching
Prompt: Average Skill Tier {1|2|3|4|5|6} 1

Table:
[#{{{$Prompt1}+{$Prompt2}}*{$Prompt3}} Foraging]

Table:WhatKind
Shuffle: WhatKind
curative
reactive
poisonous
exotic

Table: Foraging
1-5: common, {2d4} [@WhatKind] and {2d4} [@WhatKind]
6-10: common, {2d4} [@WhatKind]\n uncommon, {2d4} [@WhatKind]
11-15: uncommon, {2d4} [@WhatKind] and {2d4} [@WhatKind]
16-20: uncommon, {2d4} [@WhatKind]\n rare, {2d4} [@WhatKind]
21-25: rare, {2d4} [@WhatKind]\n very rare, {2d4} [@WhatKind]
26-30: very rare, {2d4} [@WhatKind] and {2d4} [@WhatKind]
31-35: very rare, {2d4} [@WhatKind]\n legendary, {2d4} [@WhatKind]
36-40: legendary, {2d4} [@WhatKind] and {2d4} [@WhatKind]

;;I want to have the Hours Checked as the average time for the group searching. However, I also want the Alchemy skill to affect if they are able to find any. Maybe add a gathering skill with a sub set of different kinds that I might also look for foraged food, mined ores, and the likes if I make it into a mega gen.

Comments

  • Your first table doesn't have a name. IPP will run the first named table it finds, so it just runs WhatKind and stops.

    Your calculation goes a little overboard with the notation. Are you calculating the skill tier times the sum of people searching and hours searching? You can get that using:
    [#{(Prompt1+Prompt2)*Prompt3} Foraging]

    Your Foraging table doesn't cover every possible result. If you have 5 people at skill 6 searching for 3 hours, for example, your table comes up empty. There are various ways around that. You could use a default entry in the Foraging table. You could have the prompts offer a menu of choices for people and hours, and then you make sure the Foraging table covers all the possible results. You could handle the final entry in the Foraging table with something like 36-1000000 instead of 36-40. You could cap the results in a calculation, such as:
    {value==min(40,(Prompt1+Prompt2)*Prompt3)}&
    [#{value} Foraging]

    You can add a fourth prompt if you want to account for a gathering skill as well. IPP doesn't go beyond four prompts, so if you need more than that, you'd have to break it up into different files.

  • I think I may be explaining it wrong. The Average Skill Tier decides which number between 1-40 is picked. Typically I'm thinking it rolls 1d10 + 1d5 for each tier.
    The first two prompts decide how many finds there are.

    I think I meant for it to be something like this, (but it doesn't work like this.)

    Prompt: People Searching
    Prompt: Hours Searching
    Prompt: Average Skill Tier {1|2|3|4|5|6} 1

    Table: Primary
    [#{prompt1+prompt2} Forage]

    Table: Forage
    [#{prompt3} Foraging]

    Table:WhatKind
    Shuffle: WhatKind
    curative
    reactive
    poisonous
    exotic

    Table: Foraging
    {Roll={1d10+({$prompt3}d5)}}
    1-5: common, {2d4} [@WhatKind] and {2d4} [@WhatKind]
    6-10: common, {2d4} [@WhatKind]\n uncommon, {2d4} [@WhatKind]
    11-15: uncommon, {2d4} [@WhatKind] and {2d4} [@WhatKind]
    16-20: uncommon, {2d4} [@WhatKind]\n rare, {2d4} [@WhatKind]
    21-25: rare, {2d4} [@WhatKind]\n very rare, {2d4} [@WhatKind]
    26-30: very rare, {2d4} [@WhatKind] and {2d4} [@WhatKind]
    31-35: very rare, {2d4} [@WhatKind]\n legendary, {2d4} [@WhatKind]
    36-40: legendary, {2d4} [@WhatKind] and {2d4} [@WhatKind]

  • edited May 5

    Several very minor syntax errors in your generator above, both nothing too crazy to fix.

    The one thing that I came across was that the Roll: command in a table definition simply does not want to do a complex dice roll like Roll: {1d10+{$prompt3}d5}

    So, I moved that complex roll to Table: Forage (I found this table to be unnecessary, until I found the need to take that complex roll out of Table: Foraging).

    So, ultimately, the code below is rolling on Foraging a number of times equal to People + Hours. Each roll value on that lookup table is 1d10 + Skill.d.5, for a value of 2 to 40, depending on skill level.

    ; Test Foraging.ipt
    ; created 5/5/2021 12:26:23 PM
    Prompt: People Searching {} 1
    Prompt: Hours Searching {} 1
    Prompt: Average Skill Tier {1|2|3|4|5|6} 1
    
    Table: Primary
    [@{{$prompt1}+{$prompt2}} Forage]
    
    Table: Forage
    [#{1d10+{$prompt3}d5} Foraging]                  
    
    Table: WhatKind
    Shuffle: WhatKind
    curative
    reactive
    poisonous
    exotic
    
    Table: Foraging
    Type: Lookup
    1-5: common, {2d4} [@WhatKind] and {2d4} [@WhatKind]\n
    6-10: common, {2d4} [@WhatKind]\n uncommon, {2d4} [@WhatKind]\n
    11-15: uncommon, {2d4} [@WhatKind] and {2d4} [@WhatKind]\n
    16-20: uncommon, {2d4} [@WhatKind]\n rare, {2d4} [@WhatKind]\n
    21-25: rare, {2d4} [@WhatKind]\n very rare, {2d4} [@WhatKind]\n
    26-30: very rare, {2d4} [@WhatKind] and {2d4} [@WhatKind]\n
    31-35: very rare, {2d4} [@WhatKind]\n legendary, {2d4} [@WhatKind]\n
    36-40: legendary, {2d4} [@WhatKind] and {2d4} [@WhatKind]\n
    
  • Whoa, you make it look totally easy.

    Thanks for the help, by the way. If you need help bouncing ideas hit me up, I'll contact you faster if you email my extra email: yumikoriofthecherokee (at) Gmail is how to typically contact me for a fast reply. If you need any help let me know and I'll give it my best shot, even if it is just bouncing ideas to put in the gen. I can't promise I'll be good at the programming part.

Leave a Comment