Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: [SOLVED] Randomized Selections.
[SOLVED] Randomized Selections.
Jun 20 2011, 7:40 pm
By: Psynergy  

Jun 20 2011, 7:40 pm Psynergy Post #1



I'm trying to set up a system where say I have 1-6 Variables to pick from, So say the player fill the condition of a trigger, I want the game to pick from 1-6 Variables(Not at same time just pick one of the 6 options) as a response to the player fulfilling the trigger conditions.

Anyone know how I can get around to setting this up?

Post has been edited 1 time(s), last time on Jun 22 2011, 5:09 pm by Psynergy.



None.

Jun 20 2011, 8:08 pm Ahli Post #2

I do stuff and thingies... Try widening and reducing the number of small nooks and crannies to correct the problem.

http://www.staredit.net/?p=oldwiki&s=66

You will have option 7 and 8 possible during the computation. You might just try it again in the next trigger cycle (-> do not falsify the random output conditions).




Jun 20 2011, 8:18 pm rockz Post #3

ᴄʜᴇᴇsᴇ ɪᴛ!

Another way to speed up the process if it doesn't happen instantly is to pre-calculate the result.

Randomize the 3 switches whenever DC "Randomize" is 1.
if the DC you store it is 6 or 7, redo it (don't set any DC)
If the DC is 0-5, set DC "randomize" to 0.
Then, when you call the random number, do the action, then reset the "randomize" for the next time you'll use it.

It should be instantaneous unless you run the trigger constantly.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Jun 20 2011, 8:26 pm Psynergy Post #4



Thank you Alhi And Rockz, Very helpful information :).



None.

Jun 20 2011, 9:26 pm JaFF Post #5



You can also generate a random number from 1 to, say, 1024 and then divide the result into 6 segments as equally as you can.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[04:57 am]
O)FaRTy1billion[MM] -- my name is mud
[04:35 am]
Ultraviolet -- mud, meet my friend, the stick
[10:07 pm]
lil-Inferno -- nah
[08:36 pm]
Ultraviolet -- Inf, we've got a job for you. ASUS has been very naughty and we need our lil guy to go do their mom's to teach them if they fuck around, they gon' find out
[05:25 pm]
NudeRaider -- there he is, right on time! Go UV! :D
[05:24 pm]
lil-Inferno -- poopoo
[05:14 pm]
UndeadStar -- I wonder if that's what happened to me. A returned product (screen) was "officially lost" for a while before being found and refunded. Maybe it would have remained "lost" if I didn't communicate?
[03:36 pm]
NudeRaider -- :lol:
[2024-5-16. : 3:02 am]
Ultraviolet -- I'm gonna send inf to have sex with their moms
[2024-5-16. : 3:02 am]
Ultraviolet -- fuck those motherfuckers
Please log in to shout.


Members Online: 6adrianc4923fc3