generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: learning bodyvelocity

Previous Thread :: Next Thread 
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 06:42 PM
looked up how to use body velocity buuuut, when i spawn the brick it spawns into the center of the baseplate and does shoot forward like how I want it to. it's suppose to be a fireball.

Player = script.Parent.Parent
mouse = Player:GetMouse()

function onKeyDown(key)
key = key:lower()
if key == "f" then
local fball = Instance.new("Part", game.Workspace)
fball.Anchored = true
fball.BrickColor = BrickColor.new("Really red")
fball.Transparency = .5
fball.CanCollide = false
fball.Shape = "Ball"
fball.TopSurface = "Smooth"
fball.BottomSurface = "Smooth"
fball.Size = Vector3.new(4, 1, 4)
local v = Instance.new("BodyVelocity")
v.Parent = fball
v.maxForce = Vector3.new(math.huge, math.huge, math.huge)
v.velocity = Player.Character.Torso.CFrame.lookVector*80
local ffx = Instance.new("Fire",fball)
ffx.Size = 12
ffx.Heat = 0
game.Debris:AddItem(fball, 6)
end
end

mouse.KeyDown:connect(onKeyDown)
Report Abuse
eLunate is not online. eLunate
Joined: 29 Jul 2014
Total Posts: 13268
15 Nov 2014 06:45 PM
YoU KnOw iT HeLpS To bE SeTtInG ThE PaRt's pOsItIoN BeFoRe wOnDeRiNg wHy iT Is iN ThE MiDdLe oF ThE BaSePlAtE
Report Abuse
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 06:50 PM
i don't think that's the problem because in the video the guy didnt even do that.
Report Abuse
thermonuklear is not online. thermonuklear
Joined: 19 Oct 2014
Total Posts: 484
15 Nov 2014 06:52 PM
I watch Friaza too.
Report Abuse
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 06:53 PM
yeah lol does anyone know a solution?
Report Abuse
Fedorakid is not online. Fedorakid
Joined: 17 Jul 2010
Total Posts: 7079
15 Nov 2014 06:54 PM
i dont like friaza

#hateclub
Report Abuse
eLunate is not online. eLunate
Joined: 29 Jul 2014
Total Posts: 13268
15 Nov 2014 06:58 PM
1 DON'T W4TCH YOUTUB3 V1D3OS TO L34RN, 4ND 1T S33MS TH4T 1'M B3TT3R OFF 4S 4 SCR1PT3R TH4N YOU. :3
Report Abuse
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 07:00 PM
I'm a visual learner. that's how i learn best :-p
Report Abuse
Nenzio is not online. Nenzio
Joined: 08 Jun 2013
Total Posts: 76
15 Nov 2014 07:11 PM
You're missing

x.CFrame = Player.Character.Toso.CFRame*CFrame.new(0,0,-10)

After the ffx.Heat = 0

(That's the position)
Report Abuse
Nenzio is not online. Nenzio
Joined: 08 Jun 2013
Total Posts: 76
15 Nov 2014 07:35 PM
Sorry it's torso not toso.
Report Abuse
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 07:36 PM
its not that...it gives me an error
Report Abuse
Nenzio is not online. Nenzio
Joined: 08 Jun 2013
Total Posts: 76
15 Nov 2014 07:39 PM
Also, be sure to remove the "game.Debris:AddItem(fball, 6)" line because of the removal of
the "Debris" Section.
Report Abuse
sidekick601 is not online. sidekick601
Joined: 27 Feb 2012
Total Posts: 8734
15 Nov 2014 07:42 PM
It works but it does not move forward it just spawns a few studs in front but doesnt actually move
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image