|
| 25 Jun 2014 03:34 PM |
Is there a way to make a script decide whether to continue randomly?
Script: ~~~~~~~~ ~~~~~~~~ ~~~~~~~~ (randomly decide if the next line will run, or if script will end) ~~~~~~~~
That way, the very last line may or may not run. |
|
|
| Report Abuse |
|
|
| 25 Jun 2014 03:35 PM |
if math.random() < 0.5 then --CONTINUE else --TERMINATE end |
|
|
| Report Abuse |
|
|
| 25 Jun 2014 03:36 PM |
Add
~~~~~~~~~~~ local x = math.random(1,2) if x ~= 1 then ~~~~~~~~~~~
i think it'd work....
|
|
|
| Report Abuse |
|