Quantcast
Channel: GameSalad 101 — GameSalad Forums
Viewing all articles
Browse latest Browse all 8931

Coding Help ..spawning actors based on random attribute

$
0
0

Hey guys
if anyone can help with this dilemma
I have spawning actor that every 5 seconds will spawn one of four different actors ( A,B,C and D ) ..based on a random spawning attribute ( SA ) this attribute changes every 5 sec with random value ( 1,4)
so if the SA=1 spawn actor A, if SA=2 spawn B, if 3 spawn C and 4 to spawn actor D.
now how can I make the actor spawn the actors B and D and skip C and A . as the random rule will only include min and max value in the range .. but i want to exclude value in the middle of that range any ideas ?


Viewing all articles
Browse latest Browse all 8931

Trending Articles