Igneo
|
  |
| Joined: 24 Apr 2011 |
| Total Posts: 75 |
|
|
| 28 Jul 2011 09:31 PM |
mode = true width = 2 height = 2
function onButton1Down(mouse) print(mode) Hit = mouse.hit if Hit==nil then return end
if mode == true then posx = mouse.hit.p.x posy = mouse.hit.p.y posz = mouse.hit.p.z else posx2 = mouse.hit.p.x posy2 = mouse.hit.p.y posz2 = mouse.hit.p.z p = Instance.new("Part") p.BrickColor = BrickColor.new("Dark stone grey") p.Material = Enum.Material.Slate p.TopSurface = 0 p.BottomSurface = 0 p.Name = "MountainPart" p.formFactor = 3 p.Anchored = true p.Parent = game.Workspace p.Size = Vector3.new(width,height,(Vector3.new(posx,posy,posz) - mouse.hit.p).magnitude) p.CFrame = CFrame.new(Vector3.new((posx+posx2)/2,(posy+posy2)/2,(posz+posz2)/2))
p.CFrame = CFrame.new(p.Position, mouse.hit.p) end
mode = not mode end
function onS(mouse) mouse.Button1Down:connect(function() onButton1Down(mouse) end) end script.Parent.Selected:connect(onS)
When I click I want it so its streams rocks instead of clicking once-one I need it so it does like 30. |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2011 09:33 PM |
mode = true width = 2 height = 2
function onButton1Down(mouse) print(mode) Hit = mouse.hit if Hit==nil then return end --Its because of this part.
if mode == true then posx = mouse.hit.p.x posy = mouse.hit.p.y posz = mouse.hit.p.z else --And this part. posx2 = mouse.hit.p.x posy2 = mouse.hit.p.y posz2 = mouse.hit.p.z p = Instance.new("Part") p.BrickColor = BrickColor.new("Dark stone grey") p.Material = Enum.Material.Slate p.TopSurface = 0 p.BottomSurface = 0 p.Name = "MountainPart" p.formFactor = 3 p.Anchored = true p.Parent = game.Workspace p.Size = Vector3.new(width,height,(Vector3.new(posx,posy,posz) - mouse.hit.p).magnitude) p.CFrame = CFrame.new(Vector3.new((posx+posx2)/2,(posy+posy2)/2,(posz+posz2)/2))
p.CFrame = CFrame.new(p.Position, mouse.hit.p) end
mode = not mode end
function onS(mouse) mouse.Button1Down:connect(function() onButton1Down(mouse) end) end script.Parent.Selected:connect(onS)
I'm not sure what its suppose to do, but you need to change those two. |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2011 09:36 PM |
mode = true width = 2 height = 2
function onButton1Down(mouse) print(mode) Hit = mouse.hit if Hit==nil then return end
if mode == true then posx = mouse.hit.p.x posy = mouse.hit.p.y posz = mouse.hit.p.z else --This part posx2 = mouse.hit.p.x posy2 = mouse.hit.p.y posz2 = mouse.hit.p.z p = Instance.new("Part") p.BrickColor = BrickColor.new("Dark stone grey") p.Material = Enum.Material.Slate p.TopSurface = 0 p.BottomSurface = 0 p.Name = "MountainPart" p.formFactor = 3 p.Anchored = true p.Parent = game.Workspace p.Size = Vector3.new(width,height,(Vector3.new(posx,posy,posz) - mouse.hit.p).magnitude) p.CFrame = CFrame.new(Vector3.new((posx+posx2)/2,(posy+posy2)/2,(posz+posz2)/2))
p.CFrame = CFrame.new(p.Position, mouse.hit.p) end
mode = not mode end
function onS(mouse) mouse.Button1Down:connect(function() onButton1Down(mouse) end) end script.Parent.Selected:connect(onS)
Scratch the top post, it meant to put just the else. |
|
|
| Report Abuse |
|
|
Igneo
|
  |
| Joined: 24 Apr 2011 |
| Total Posts: 75 |
|
|
| 28 Jul 2011 09:36 PM |
| I know that it's just I don't know how. |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2011 09:37 PM |
| Then you will have to figure out how, sorry. :( |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2011 09:38 PM |
for i = 1,30 do --part stuff end |
|
|
| Report Abuse |
|
|
Igneo
|
  |
| Joined: 24 Apr 2011 |
| Total Posts: 75 |
|
| |
|
8Bawl
|
  |
| Joined: 24 Jun 2011 |
| Total Posts: 544 |
|
| |
|