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 » Scripters
Home Search
 

I got this weird glitch to do with the physics.

Previous Thread :: Next Thread 
awsumpwner27 is not online. awsumpwner27
Joined: 03 Sep 2011
Total Posts: 4389
10 Sep 2012 06:57 PM
http://www.roblox.com/Odd-glitch-item?id=92458574

The script allows players to fire rockets in the direction of a click, but something can happen that causes the rockets to not move. They aren't Anchored, they have a BodyVelocity with the velocity's magnitude at 30. The part's velocity is at 0, but changing it doesn't make it move. It still responds to Touched events, and sometimes it make begin moving, but it often doesn't.

Explain this nonsense.
Report Abuse
RenderSettings is not online. RenderSettings
Joined: 16 Aug 2010
Total Posts: 2560
10 Sep 2012 06:59 PM
I assume that you are creating the BodyVelocity with a localscript? If so, then there is the problem. I encountered this bug quite a while ago, in that the BV will fire for a fraction of a second, and then stop replicating. Easy solve is to clone a part with a bodyv from the script and parent it in workspace, or somehow parent from a normal script.
Report Abuse
awsumpwner27 is not online. awsumpwner27
Joined: 03 Sep 2011
Total Posts: 4389
10 Sep 2012 07:49 PM
This was in Play Solo (no server replication), and it's in an ordinary Script object.
Report Abuse
veerstrong is not online. veerstrong
Joined: 23 Jun 2009
Total Posts: 2450
10 Sep 2012 09:02 PM
I ain't sure, but maybe with this line?
v.velocity = p.CFrame.lookVector*30

I've never seen somebody change velocity, using that method...
Or either I am really stupid.
Report Abuse
3543 is not online. 3543
Joined: 03 Dec 2011
Total Posts: 121
10 Sep 2012 09:06 PM

@veer: That's how I change it almost all the time. It's not abnormal to use that. It's probably the client stuffz. Make sure you aren't doing anything weird to the part and use a sever-script if you can.
Report Abuse
awsumpwner27 is not online. awsumpwner27
Joined: 03 Sep 2011
Total Posts: 4389
10 Sep 2012 09:54 PM
Here's the entire script, it goes in the Workspace:

Game.Players.PlayerAdded:connect(function(plyr)
   plyr:GetMouse().Button1Down:connect(function()
      local p = Instance.new("Part", Game.Workspace)
      p.BrickColor = BrickColor.new("Bright blue")
      p.FormFactor = "Brick"
      p.Size = Vector3.new(1,1.2,4)
      p.CFrame = CFrame.new(plyr.Character.Head.Position + (plyr:GetMouse().Hit.p - plyr.Character.Head.Position).unit*7.5, plyr:GetMouse().Hit.p)
      local v = Instance.new("BodyVelocity", p)
      v.velocity = p.CFrame.lookVector*30
      script.Swoosh:clone().Parent = p --Sound, this line and below line not needed
      p.Swoosh:play()
      p.Touched:connect(function(hit)
         local e = Instance.new("Explosion", Game.Workspace)
         e.Position = p.Position
         script.Explosion:clone().Parent = p --Sound, this line and below line not needed
         p.Explosion:play()
         p:Destroy()
      end)
      wait(60)
      p:Destroy()
   end)
end)
Report Abuse
Veldahar is not online. Veldahar
Joined: 12 May 2012
Total Posts: 143
11 Sep 2012 07:47 AM
The BodyForce seems to be broken.

My jumppads stopped working, too
Report Abuse
awsumpwner27 is not online. awsumpwner27
Joined: 03 Sep 2011
Total Posts: 4389
11 Sep 2012 05:19 PM
Guys, seriously, this is a real issue.
Report Abuse
Sorcus is not online. Sorcus
Forum Moderator
Joined: 29 Nov 2010
Total Posts: 3775
11 Sep 2012 07:07 PM
Kay, seems to be a problem with setting the parent Instance.new itself. This fixes it,

plyr:GetMouse().Button1Down:connect(function()
local p = Instance.new("Part")
p.BrickColor = BrickColor.new("Bright blue")
p.FormFactor = "Brick"
p.Size = Vector3.new(1,1.2,4)
p.CFrame = CFrame.new(plyr.Character.Head.Position + (plyr:GetMouse().Hit.p - plyr.Character.Head.Position).unit*7.5, plyr:GetMouse().Hit.p)


local v = Instance.new("BodyVelocity")
v.velocity = plyr.Character.Torso.CFrame.lookVector * 40.0
v.maxForce = Vector3.new(50000, 50000, 50000)
v.Parent = p

p.Parent = game.Workspace

p.Touched:connect(function(hit)
local e = Instance.new("Explosion", Game.Workspace)
e.Position = p.Position
p:Destroy()
end)
wait(60)
p:Destroy()
end)

but still this is annoying and will be fixed.
Report Abuse
belial52 is not online. belial52
Joined: 10 Oct 2009
Total Posts: 8074
11 Sep 2012 07:53 PM
Wait, we can get a player's mouse with a server script? :o
Report Abuse
Sorcus is not online. Sorcus
Forum Moderator
Joined: 29 Nov 2010
Total Posts: 3775
11 Sep 2012 08:11 PM
All scripts are run locally in Play solo. Otherwise his script won't work. I was assuming that he knew this. Otherwise, time to learn!

~Sorcus
Report Abuse
Tasha5266 is not online. Tasha5266
Joined: 23 Jun 2012
Total Posts: 9077
11 Sep 2012 09:52 PM
@sorus, wanna be friends? ololo.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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