Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

Assigning random values from 1-2, not working? Why?

Asked by 9 years ago

I have this:

MapData.Value = math.random(1,2)
        wait(1)
        if MapData.Value == 1 then

& this

MapData = script.MapData

The MapData is an Integer Value that is a sub or like merged inside the script if you get my drift and why is it not assigning a random value? It is breaking. What is going on?

0
There! HexC3D 830 — 9y
0
Done it your way :) HexC3D 830 — 9y
0
We don't have enough context to know why it's breaking. Provide more of your script. This fragment isn't enough. TaslemGuy 211 — 9y

1 answer

Log in to vote
-1
Answered by
KAAK82 16
9 years ago

intergers aren't supposed to work with math.random, u can however try using tostring() or something, I'm confused a lil though... :/

Ad

Answer this question