Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why doesn't my part's .Touched not register the touch at all?

Asked by 5 years ago

I'm making a Kamehameha from DBZ, it works perfectly but when it touches an enemy it doesn't register the touch This is only the part of the script that involves my problem and might help fix the problem. Tell me if you need more of the script.

local Kame = Instance.new("Part",Character)

        Kame.Anchored = true

        Kame.CanCollide = false

        Kame.Shape = "Cylinder"

        Kame.Material = "Neon"

        Kame.BrickColor = BrickColor.new("Cyan")

        Kame.Size = Vector3.new(.1,3,3)

        Kame.CFrame = StartKame.CFrame

        Kame.Orientation = StartKame.Orientation + Vector3.new(0,90,StartKame.Orientation.X)

            local FireSound = game.ReplicatedStorage.Sounds.KamehamehaFire:Clone()

    FireSound.Parent = StartKame

    FireSound:Play()

local TweenService = game:GetService("TweenService")

    local TI = TweenInfo.new(.2,Enum.EasingStyle.Linear,Enum.EasingDirection.Out,0,false,0)

local properties = {

        Size = Vector3.new(200,3,3),

        CFrame = Kame.CFrame + Kame.CFrame.rightVector*100

}

local Tween = TweenService:Create(Kame,TI,properties)

    Tween:Play()

    Kame.Touched:Connect(function()

        print("Touched")

    end)

wait(3)

    local TI2 = TweenInfo.new(1,Enum.EasingStyle.Linear,Enum.EasingDirection.Out,0,false,0)

    local properties2 = {

        Size = Vector3.new(100,.1,.1),

        Transparency = 1

}

local Tween2 = TweenService:Create(Kame,TI2,properties2)

    Tween2:Play()

local TI3 = TweenInfo.new(1,Enum.EasingStyle.Linear,Enum.EasingDirection.Out,0,false,0)

    local properties3 = {

        Size = Vector3.new(.1,.1,.1),

        Transparency = 1

}

local Tween3 =          TweenService:Create(StartKame,TI3,properties3)

Tween3:Play()
0
What kind of script is it? DeceptiveCaster 3761 — 5y
0
It's a normal server script Undevitt 17 — 5y
0
I would use RemoteEvents. DeceptiveCaster 3761 — 5y
0
That's what I did and this is the part of the script that I want for it to get .touched Undevitt 17 — 5y

Answer this question