Author Topic: Chance Events  (Read 373 times)

Soo liike. onAcivate,self,chance1/4,contentStart
Somthing along the lines of that...
so the chance is 1 in 4


Create a 1x4 brick named "chance". Place four 1x1 bricks on top of it, and another one as a switch somewhere else.

Switch:
onActivate -> <Named Brick: chance> -> spawnProjectile ["0 0 10", "Radio Wave", "0 0 0", 1.0]

1x1 bricks
onProjectileHit -> ....Events with 1 in 4 chance here....

Use different sized bricks for different ratios.

Does radio wave sometimes go through bricks or something?

Radio waves pass through players and vehicles so they won't get blocked, and do no brick damage so the 1x1 bricks won't die. You can use any projectile, really.

but as I understand it, projectiles travel .... nvm. Figured it out. Wouldn't it work with a 1x2x1?

Yes. Works on any size brick. In the first post he wanted a 1 in 4 chance so I gave an example for that.