Error Help - Expected indentifier when parsing method name, got 'local'

Hello All,

I have this frustrating error and from what I’ve been searching up it seems to be a syntax error of some sort but I have no clue what the error is! What’s funny is this error only appears when I run the game on Roblox but it works completely fine in studio!

This is the local script lines 7-13:

local HumanoidRootPart = game.Players.LocalPlayer.Character:WaitForChild("HumanoidRootPart")

local idleAnim = script:WaitForChild("Idle")   -- Error on this line (line 9)
local idleAnimTrack = Humanoid.Animator:LoadAnimation(idleAnim)

local moveAnim = script:WaitForChild("Move")
local moveAnimTrack = Humanoid.Animator:LoadAnimation(moveAnim)

I appreciate any help

local Player = game:GetService("Players").LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()

local HumanoidRootPart = Character:WaitForChild("HumanoidRootPart")

Anim = script:WaitForChild("Idle")   -- Error on this line (line 9)
local idleAnimTrack = Humanoid.Animator:LoadAnimation(idleAnim)

local moveAnim = script:WaitForChild("Move")
local moveAnimTrack = Humanoid.Animator:LoadAnimation(moveAnim)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.