SA-MP Forums Archive
Variable Scripting Problem - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Variable Scripting Problem (/showthread.php?tid=147378)



Variable Scripting Problem - aleancuervo - 11.05.2010

Well, whats my problem about.. I have a RP server.. On it i have a Medical Faction... Well, what i want to do is to can exctract blood to a patient, and then analize it... And it gives me a variable or random result.. For example: "Patient Patologies: Bacterium Streptococcus pneumoniae" or else any random bacterium of this list:

Streptococcus pneumoniae
Escherichia coli
Bacillus anthracis
Helicobacter pylori

Just that, i repeat, i want to do a random selection of a bacterium of these ones in a patient... Thanks!


Re: Variable Scripting Problem - aleancuervo - 12.05.2010

So, someone think that know?


Re: Variable Scripting Problem - cessil - 12.05.2010

well at the top of the script you'd create an enum containing all of the things and then use a random()


Re: Variable Scripting Problem - -Rebel Son- - 12.05.2010

Instead of a Enum, have you tryed a flat out variable?






Re: Variable Scripting Problem - aleancuervo - 20.05.2010

UP!