Hello Developers, I’ve been recently working on a Football Game.
As I was testing with the other developers on my team, we realized that catching the football almost all the time was either Inconsistent or would look like it “teleported” to the character before it would touch the character. This is my first time dealing with a so called “bug” like this and I don’t know how I could go about fixing this.
How can I make catching in my game look more rich and more accurate supposed to teleporting and not even being able to catch the ball in some cases?
– Catching Server Side
-- Constants {Character & Player} --
local Character = BasePart.Parent
local LocalPlayer = PlayerService:GetPlayerFromCharacter(Character)
-- Check {For Local Player} --
if LocalPlayer then
if Football.Parent == workspace then
-- Check {If Catch Is Needed} --
if _Football.CatchNeeded == true and Character.CustomProperties.CanAttemptCatch.Value == true and _Football.JustThrown == false then
if not Character:FindFirstChild('Football') then
-- Check {Positions Magnitude} --
if (Football.Position - BasePart.Position).Magnitude <= 11 then
-- Send Over {Completed Catch & Extra Stuff} --
_Football.CatchNeeded = false
_Football:UpdateFootball(Football,Character)
self:Highlight(BasePart.Parent,Color3.fromRGB(85,255,0))
----
-- Check {Catchers Team {For Turnovers}} --
if PlayerService[Football.Properties.Thrower.Value.Name].Team ~= LocalPlayer.Team then
_Interface:Message(LocalPlayer.Team,'Interception')
-- Update {Team Possession} --
self.HomePossession = not self.HomePossession
else
_Interface:Message(LocalPlayer.Team,'Complete')
end
end
end
end
end
end