|
| 06 Apr 2014 03:46 PM |
| I need help. I made a Gui, and it teleport to one brick. I want it to teleport to random brick. Please help me! |
|
|
| Report Abuse |
|
|
NeonRiver
|
  |
| Joined: 12 Feb 2013 |
| Total Posts: 4936 |
|
| |
|
|
| 06 Apr 2014 03:48 PM |
local bricks = {} for i,v in pairs(workspace:GetChildren()) do if v:IsA("BasePart") then table.insert(bricks, v) end end local randomBrick = bricks[math.random(1, #bricks)] -- teleport player to randomBrick |
|
|
| Report Abuse |
|
|
| |
|
| |
|
|
| 06 Apr 2014 03:59 PM |
| I simply replace the script i had before that teleport to one brick with the script you have given me. I press the gui and it does not teleport to a random brick i have place everywhere. Please help! |
|
|
| Report Abuse |
|
|
|
| 06 Apr 2014 04:07 PM |
| Any suggestions like giving me instructions with the script to put in the gui? |
|
|
| Report Abuse |
|
|