ok i need to know how to make a baby system & a husband/wife boyfriend/girlfriend system, well id like it where the wife/husband can like have sex and if they dont wear a condum (sorry for the explicit content) well boyfriend/girlfriend can do that too, but see its a charmed game and i want it where if the parents of the baby has like special skills the baby gets 2 skills randomly from each parent, then they can still go and become a witch of a different type.
example: Piper's son Wyatt takes his dad's whitelighter skills, while i still believe he can go and get other witch or whatever skills.
ID:165206
Feb 6 2007, 3:13 pm
|
|
Feb 7 2007, 2:13 am
|
|
You 'need to know how' or 'need someone to make it for you', huh? For the former, well, read more from the Resources panel on the left including the DM Guide. Not much more to it, if you don't know even how to begin.
|
If you are looking for the equations and formulas, maybe design philosophy would be a better area to look for idea.
if you are asking how to code it, it would be best to have the equations/formulas/etc. first, so you know what you are building. but on what you asked, to randomly take a skill from the parents, throw what skills they have into a list and use the pick proc. As to getting pregnant, it's a simple probability check. Set the percentage as you want, make wearing a condom reduce the percent by 75%. anymore than that, and I'll be writing your code for you. |
In response to Kaioken
|
|
well i know how to begin and i know what i want it to do, but i dont know how to code percentages
|
In response to VolksBlade
|
|
Look up the prob() proc.
|
In response to Kaioken
|
|
Either...
if(prob(50)) //gives a 50 percent chance. OR if(rand(1,50)==1) //gives a 1/50 chance. [EDIT: Ah, forgot the ==1 part. Sorry!] |
In response to Flame Sage
|
|
...The latter will obviously ALWAYS return true and pass the if() check. :P
What you want is, if already, if(!rand(0,49)) |