01 | local question = script.Parent.Parent |
02 | local fr 2 = script.Parent.Parent.Parent.Parent.Frame 2 |
03 | script.Parent.MouseButton 1 Click:connect( function () |
04 | script.Parent.Parent.Parent.Visible = false |
05 | wait( 1 ) |
06 | local Response = math.random( 5 ) |
07 | wait( 1 ) |
08 | if Response = = 1 then |
09 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with Yes." |
10 | if Response = = 2 then |
11 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with No." |
12 | if Response = = 3 then |
13 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with Maybe." |
14 | if Response = = 4 then |
15 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with Probably." |
No errors Local Script
01 | local question = script.Parent.Parent |
02 | local fr 2 = script.Parent.Parent.Parent.Parent.Frame 2 |
03 | script.Parent.MouseButton 1 Click:Connect( function () |
04 | script.Parent.Parent.Parent.Visible = false |
05 | wait( 1 ) |
06 | local Response = math.random( 5 ) |
07 | wait( 1 ) |
08 | if Response = = 1 then |
09 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with Yes." |
10 | end |
11 |
12 | if Response = = 2 then |
13 | fr 2. X.Text = "You asked " ..question.Text.. " and it replied with No." |
14 | end |
15 | if Response = = 3 then |
You had every if condition within one another, so if response == 1 then if response == 2. That's how your's was.