Hello guys, I am currently using Shapecast as my hitbox for a melee combat that I have.
The issue with this is that when I am up close to a target, for some reason the hitbox does not work.
However, when I am in a reasonable distance away from the target, it works.
Here is my code and an example of the hitbox.
Any response will be heavily appreciated!
local function castHitbox(params, char)
local hrp = char.HumanoidRootPart
local size = Vector3.new(7,5,10);
local direction = hrp.CFrame.LookVector;
local result = workspace:Blockcast(hrp.CFrame, size, direction, params);
Visualiser:Blockcast(hrp.CFrame, size, direction, params);
if result then
print("Hello!")
end
end
local function HitboxOnAnim(CurrentCombo, plr)
local params = RaycastParams.new();
params.FilterDescendantsInstances = {plr.Character};
params.FilterType = Enum.RaycastFilterType.Exclude;
castHitbox(params, plr.Character)
end