of     1   

Raildex
#182499924Wednesday, January 27, 2016 1:49 PM GMT

local car1 = game:GetService("ReplicatedStorage")["Car"] local backup = car1:clone() local car2 = game:GetService("ReplicatedStorage")["Van"] local backup = car1:clone() local car3 = game:GetService("ReplicatedStorage")["Off-Roader"] local backup = car1:clone() carN = script.Parent.Parent.carValue local carV cooldown = false function Regen() if(carN.Value == 1) then carV = car1 print("set to Sedan") end if(carN.Value == 2) then carV = car2 print("set to Van") end if(carN.Value == 3) then carV = car3 print("set to Jeep") end if(cooldown == false) then carV = backup:clone() carV.Parent = game.Workspace carV:makeJoints() carV:SetPrimaryPartCFrame (script.objectValue.Value.CFrame+Vector3.new(0,5,0)) carV:SetPrimaryPartCFrame (car1.PrimaryPart.CFrame * CFrame.Angles(0,math.rad(180), 0)) print(carV.PrimaryPart) cooldown = true script.Parent.Text = "On Cooldown" wait(12) cooldown = false script.Parent.Text = "Build" end end script.Parent.MouseButton1Down:connect(Regen) Can someone look at this and tell me if im referencing/setting variables correctly
Thane_1
#182501004Wednesday, January 27, 2016 2:38 PM GMT

You have this repeat 3 times: local backup = car1:clone() For 2 and 3, it should be: local backup2 = car2:clone() and local backup3 = car3:clone() ~ Who's awesome, you're awesome

    of     1