-
What do you want to achieve? Fixing this aim bug.
-
What is the issue? Well, this aim bug. Goes in the wrong direction.
robloxapp-20221231-0024032.wmv (3.8 MB) -
What solutions have you tried so far? Tried changing the positioning, nope. It works but doesn’t work at the same time.
local Tool = script.Parent
local Effects = Tool.Effects
local ServerEvent = Tool.ServerEvent
local Players = game.Players or game:GetService("Players")
--Player = nil
Humanoid = nil
RootPart = nil
Character = nil
Cooldown = false
local Animation = Tool["Blast Animation"]
ServerEvent.OnServerEvent:Connect(function(Player, Hit)
if Tool:FindFirstAncestorOfClass("Model") then
Character = Tool.Parent
if Character ~= nil and Character:FindFirstChild("Humanoid") and Character:FindFirstChild("HumanoidRootPart") and Cooldown == false then
Cooldown = true
Humanoid = Character.Humanoid
RootPart = Character.HumanoidRootPart
local Bomb = Instance.new("Part", workspace)
local Particles = Effects:GetChildren()
for i, v in pairs(Particles) do
if v ~= nil and v.ClassName == "ParticleEmitter" then
local NewParticles = v:Clone()
NewParticles.Parent = Bomb
NewParticles.Enabled = true
end
end
Bomb.Shape = Enum.PartType.Ball
Bomb.Size = Vector3.new(4, 4, 4)
Bomb.Transparency = 1
Bomb.Anchored = false
Bomb.CanCollide = true
Bomb.CFrame = RootPart.CFrame+Vector3.new(0, 1, 0)
Bomb.AssemblyLinearVelocity = Vector3.new(Hit.Position.X, 0, Hit.Position.Z)
Cooldown = false
end
end
end)
Please help me, any advice helps. Also, if this is simple please do not complicate it. I’m still kind of a newbie when it comes to this. The problem is that the bomb goes in the wrong direction of the pointer/Mouse.Hit.Position.