UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:05 PM |
I want to make a NON ray casting gun, something like the rocket launcher
But there are so many variables in it I don't really understand how it makes the rocket go to the place the player pointed
Help? |
|
|
| Report Abuse |
|
|
btft
|
  |
| Joined: 19 Feb 2011 |
| Total Posts: 1512 |
|
| |
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:08 PM |
@Btft I know, but that doesn't help me make the bullet go to it |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:10 PM |
| You could use any of the BodyMovement objects. I've been using BodyVelocity lately for my guns, but you do what you want. |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:11 PM |
@Roy I tried all of them, they either don't move (Maybe I don't know how to use them) or go different speeds depending on how far you click or make a artch not go straight to it, or always fire one way, not to the pointing place |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:16 PM |
local cframe = CFrame.new(tool.Handle.Position,mouse.hit.p)
local speed = INTSPEEDHERE
local wahtUwant = tool.Handle.Position+(cframe.lookVector*speed) |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:27 PM |
local wahtUwant = tool.Handle.Position+(cframe.lookVector*speed)
Wut |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:30 PM |
| What you no understand? Plug dat crap in for velocity and make maxTorque really high k? |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:30 PM |
For what?
Body positon?
Body force?
I DUN'T KNUW |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:32 PM |
| oh sorry my bad k? bodyvelocity is what i use |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:40 PM |
r u trolin me?
It makes them fly not go to the place you aim
script.Parent.Equipped:connect(function(Mouse) Mouse.Button1Down:connect(function() Bullet = Instance.new("Part") Force = Instance.new("BodyVelocity")
local cframe = CFrame.new(script.Parent.Handle.Position,Mouse.hit.p)
local speed = 1
local wahtUwant = script.Parent.Handle.Position+(cframe.lookVector*speed)
Force.velocity = wahtUwant
Force.Parent = Bullet Bullet.CFrame = script.Parent.Handle.CFrame Bullet.FormFactor = "Custom" Bullet.Size = Vector3.new(1,1,1) Bullet.Parent = Workspace
end) end)
|
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:44 PM |
| Make teh speed like 100 and make the max property liek Vector3.new(120000,12000,12000) and btw no trolls i promise |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:47 PM |
| It kinda works, is there a way to make it fire a little more straight? |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:48 PM |
| plox what? it should fire straight.... which way is it going? up/down? right/left? |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
| |
|
|
| 11 Apr 2013 06:51 PM |
| idk why that would happen, maybe uneven max property... the x y and z props need to be equal to go even. it works for me, it might be an illusion. |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 06:53 PM |
Try it
script.Parent.Equipped:connect(function(Mouse) Mouse.Button1Down:connect(function() Bullet = Instance.new("Part") Force = Instance.new("BodyVelocity")
local wahtUwant = script.Parent.Handle.Position+(CFrame.new(script.Parent.Handle.Position,Mouse.hit.p).lookVector*100)
Force.velocity = wahtUwant Force.maxForce = Vector3.new(120000,12000,12000)
Force.Parent = Bullet Bullet.CFrame = script.Parent.Handle.CFrame Bullet.FormFactor = "Custom" Bullet.Size = Vector3.new(1,1,1) Bullet.Parent = Workspace
end) end) |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 06:54 PM |
LOL sorry bro dats all my fawlt! change dis
Force.maxForce = Vector3.new(120000,12000,12000)
to dis
Force.maxForce = Vector3.new(120000,120000,120000)
k tanks bai???? |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
| |
|
|
| 11 Apr 2013 07:00 PM |
| still goes toooooooooo left? dats weird, sorry idk whats wrong |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 07:01 PM |
| LOL its fun to shoot the base and watch dem bounce :3 |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 07:02 PM |
| dats prolly a problem. im sorry to say but there is no way to fix that evar and if somebody tells you to change the CanCollide prop to false tell them you will not let them corrupt you and then just delete your script k? |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 07:11 PM |
| nuuu have it remove teh bullet on touch nob |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 07:12 PM |
bullet.Touched:connect(function() bullet:Destroy() end) |
|
|
| Report Abuse |
|
|
UnBuild
|
  |
| Joined: 22 Mar 2013 |
| Total Posts: 3233 |
|
|
| 11 Apr 2013 07:14 PM |
| I know how lol I was just saying that was how to fix it |
|
|
| Report Abuse |
|
|