Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ------Made by personsadminlol--------
- -----Part 1------
- ------Protect you from hits----------
- easeinquad = function(t, b, c, d) -- y
- if t >= d then return c+b end -- guarantee hits : D
- t = t/d
- return c*t*t + b
- end
- easeincirc = function(t, b, c, d) -- x, z
- if t >= d then return c+b end -- guarantee hits : D
- t = t/d
- return -c * (math.sqrt(1 - t*t) - 1) + b
- end
- newpos = Vector3.new(easeincirc(tick()-currenttime, initialx, part.Position.X-initialx, duration), easeinquad(tick()-currenttime, initialy, part.Position.Y-initialy, duration), easeincirc(tick()-currenttime, initialz, part.Position.Z-initialz, rocket.CFrame = CFrame.new(newpos) * CFrame.Angles(CFrame.new(Vector3.new(), (part.Position - rocket.Position).unit):toEulerAnglesXYZ())
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement