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: Offset of BlockMesh

Previous Thread :: Next Thread 
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:09 AM
As you know, the Offset property is used to simulate the movement of the brick while the actual brick stays stationary. This reduces the lag. Crazyman32 told me that is how he moves his missiles. What I was wondering is if that is what he uses to simulate the movement, the actual brick could still trigger the touch event. How does he by pass that.
Report Abuse
Ozzypig is not online. Ozzypig
Joined: 27 Mar 2008
Total Posts: 4906
21 Jul 2011 10:14 AM
I think he's lying when he says he uses *just* the offset position. Now the mesh itself, that might be attached to a larger brick which is moving.

Again, it would be plain inefficient to have to check for collision yourself.

~Ozzy
Report Abuse
bl5eebryce is not online. bl5eebryce
Joined: 03 Aug 2009
Total Posts: 387
21 Jul 2011 10:16 AM
With complicated scripts. My guess is that he would find the position of the target, find how fast the missile is traveling, and do some math to figure out how long it would take to get there. Then he would put that into a wait() command then create an explosion at the position of the target.
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:17 AM
@Ozzy
What way would you suggest that I project a missile
All the Body... are glitchy and sometimes cause the missile to explode it's own plane. That ain't cool.
Report Abuse
Ozzypig is not online. Ozzypig
Joined: 27 Mar 2008
Total Posts: 4906
21 Jul 2011 10:21 AM
BodyVelocities and BodyGyros aren't glitchy at all; you're just using them wrong.

I remember there was a RocketPropulsion object that made it easier to make a missile.

~Ozzy
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:22 AM
@Ozzy
There is absolutely no way to use BodyVelocity wrong. RocketPropulsion is long since broken. What BodyVelocity does is cause the missile to come back to the place it was shot from. THe plane by that time is already on that position. This causes the plane to go kaboom
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:24 AM
Bawmp
Report Abuse
Ozzypig is not online. Ozzypig
Joined: 27 Mar 2008
Total Posts: 4906
21 Jul 2011 10:25 AM
BUT I LIKED ROCKETPROPULSION! D:
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:43 AM
So did I! But roblox messed it up :(
Wouldn't it have been so easy to make a homing missile with RocketPropulsion?
D:
Well, now help me with projecting a missile please :(
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:44 AM
o_O this is what I have so far:


function onFire(gun)
local ray = Ray.new(gun.Position, gun.CFrame.lookVector * 999)
local Part, Pos = Workspace:FindPartOnRay(ray, gun)
local ra = Ray.new(Pos, gun.CFrame.lookVector * 350)
local part, pos = Workspace:FindPartOnRay(ray, gun)
local b = Instance.new("Part")
b.Parent = game.Workspace
b.Position = gun.Position:Lerp(pos, 0.05)
b.formFactor = 0
b.Size = Vector3.new(1,.4,1)
b.BrickColor = BrickColor.new(194)
b.Name = "Rocket"
b.Velocity = gun.CFrame.lookVector * 800
local force = Instance.new("BodyForce")
force.force = Vector3.new(0, 196*b:GetMass(), 0) --anti-grav it
force.Parent = b
local bg = Instance.new("BodyGyro")
bg.cframe = CFrame.new(b.Position, pos)
bg.Parent = b
local s = script.Parent.Rocket:Clone()
s.Disabled = false
s.Parent = b
local M = script.Parent.Rockett:Clone()
M.Parent = b
local K = Instance.new("Smoke")
K.Parent = b
K.RiseVelocity = 10
local creator_tag = Instance.new("ObjectValue")
creator_tag.Value = script.Parent.Parent.Parent
creator_tag.Name = "creator"
creator_tag.Parent = b
end
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:49 AM
Oh yeah the anti-grav part was taken of the roblox FreezeRay. Help ozzypig :P
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 10:54 AM
Ozzypig? Are you there? Come on help please@!
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 11:05 AM
Bawmp
Report Abuse
SkullsNCandy is not online. SkullsNCandy
Joined: 27 Dec 2009
Total Posts: 3730
21 Jul 2011 11:12 AM
You could make it without any of those though.
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 11:16 AM
How?
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 11:52 AM
tHEN HOW?
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 11:59 AM
No help again?
Report Abuse
alexmach1 is not online. alexmach1
Joined: 02 May 2008
Total Posts: 1977
21 Jul 2011 12:07 PM
well, in place of rocket propulsion, you could use this script that does almost the exact same thing. just make sure the rocket is anchored, so it doesnt move down before the script activates.


script.Parent.Anchored=false
while true do
script.Parent.Velocity=script.Parent.CFrame.lookVector*50
wait()
end
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 12:09 PM
Velocity does the same thing as BodyVelocity. It causes the missile to lag and crash into it's own plane.
Report Abuse
alexmach1 is not online. alexmach1
Joined: 02 May 2008
Total Posts: 1977
21 Jul 2011 12:12 PM
actually, this script improves the missile with a much easier way to set its speed and direction. it also prevents dipping that was present in the previous script.


aka use this script in place of rocketpropulsion




local Factor = 196.2
local Gravity = Instance.new("BodyForce")
Gravity.Parent = script.Parent
Gravity.force = Vector3.new(0,Factor * script.Parent:GetMass(),0)


while true do
script.Parent.Velocity=script.Parent.CFrame.lookVector*50
wait()
script.Parent.Velocity=script.Parent.CFrame.lookVector*50
end
Report Abuse
darkkiller5555 is not online. darkkiller5555
Joined: 22 Nov 2009
Total Posts: 6359
21 Jul 2011 12:18 PM
City, use BodyForce to counter the mass of the missile, making it fly smoothly. Thus, making it so the missile doesn't lagg and make the plane go boom.
Report Abuse
alexmach1 is not online. alexmach1
Joined: 02 May 2008
Total Posts: 1977
21 Jul 2011 12:27 PM
@darkkiller you mean like the script above your post XD
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 12:42 PM
So wait a sec, the while loop, can I use a different script for that?
Report Abuse
citymaster22 is not online. citymaster22
Joined: 10 Jan 2010
Total Posts: 4993
21 Jul 2011 12:47 PM
Won't work =/
Report Abuse
alexmach1 is not online. alexmach1
Joined: 02 May 2008
Total Posts: 1977
21 Jul 2011 12:51 PM
what do you mean.
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