Profile Picture

HIR0

Reputation: 0 [rate]

Joined: Dec, 2023

Last online:

Etc

Send Message

Threads List
Possible Alts

Activity Feed

Created a new thread : Opening doors by fireing the touch interest STRUGLE


Hey so I'm pretty new to all the coding and try to learn with youtube etc. but I don't really find somthing that can help me with this.

 

So I try to open doors by fireing touch interest with my head, it works but just only one time (have to reset for it to work again).
script:

local playerHead = game.Players.LocalPlayer.Character.Head

for i, v in pairs(game:GetService("Workspace").Doors:GetDescendants()) do
    if v.Name == "TouchInterest" and v.Parent then
        firetouchinterest(playerHead, v.Parent, 0)
    end
end

 

But if i ad

firetouchinterest(playerHead, v.Parent, 1)

 

it crash the game.

Someone that can help me fix this? And knows how to loop this aswel?

 

Thank you :)