#### Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

# To increase numbers by %

edited December 2015
I'm getting more and more ambitious with my random NPC generator and I was wondering how I could go about adding a third prompt labeled "Difficulty Level" and when selected it would add increments of five or ten percent to the attributes. I'm able to do it with a Class table with an added + [#n {\$Class}Bonus])} where n = the number on the table.
```Table: Human
Set: Skills =&#91;@{\$Class}Skills&;#93;
Set: ST ={! ({1d3+8} + &#91;#1 {\$Class}Bonus&#93;)}
set: DX ={! ({1d3+8} + &#91;#2 {\$Class}Bonus&#93;)}
set: IQ ={! ({1d3+8} + &#91;#3 {\$Class}Bonus&#93;)}
set: HT ={! ({1d3+8} + &#91;#4 {\$Class}Bonus&#93;)}
set: HP ={! ({\$ST} + &#91;#5 {\$Class}Bonus&#93;)}
set: Speed ={! (({\$HT} + {\$DX}) /4) + &#91;#6 {\$Class}Bonus&#93;}
set: Will ={! ({\$IQ} + &#91;#7 {\$Class}Bonus&#93;)}
set: Move ={! floor(({\$HT} + {\$DX}) /4) + &#91;#8 {\$Class}Bonus&#93;}
set: Per ={! {\$IQ} + &#91;#9 {\$Class}Bonus&#93;}
set: FP ={! {\$HT} + &#91;#10 {\$Class}Bonus&#93;}
set: Dodge = {! floor({\$Speed})+3}
set: Parry = {! floor({\$DX} /2)+3}
```

I'm just starting to toy with the idea. Would I just do something like this

Set: ST ={! ({1d3+8} + [#1 {\$Class}Bonus] + {DifficultyLevel} }

So this also means i need to add something like this

Set:DifficultyLevel=[when]{\$prompt3}=Random[do][@Difficulty][else][{\$prompt3}][end]

But how to do it throughout? So if select "Rabid" and I want Rabid to add 10% rounded up how do I get it to add it to each and every one?

Can % be used as a math expression? I'm not seeing it in the Help file.

• On a second thought is there anyway to get the selection of a first prompting to change the options of the second prompting?

So let us say I have three prompts 1, 2, and 3.

You select Prompt 1 option E, now Prompt 2 gives the options of a, b, c, d.

However if you select Prompt 1 option B, now Prompt 2 gives Options 1, 2, 3, 4 instead.

If the above is not attainable then can the following be done.

I have say 20 different generators. Each generator has 3 prompts.

I now make a new Generator that when prompted can now either randomly select from the 20 different generators or you can prompt it to. Would the fact that the generators selected from have prompts make it come up as invalid expression?
• I can't answer the question about prompts. However, the easy way to add 10% is to multiply by 1.1. I have not tested this, and I'm still learning IPP myself, but I would think something like:
Set: ST = {{{1d3+8} + [#1 {\$Class}Bonus]} * {1 + {{DifficultyLevel}/10}}}

I think that will add 10% if DifficultyLevel = 1, 20% if it = 2, etc.