Script doesn't see a model in my Player. Can someone help me?
Hello. I am making a script that plays an animation (sword is auto equipped without a tool.) Apparently, the script says there is no model called "Blade" in workspace.luvumilo (luvumilo is my username.)
Here is the code
01 | local chr = script.Parent.Parent.Parent.Parent.Character |
03 | scissorblade = chr [ "Blade" ] |
04 | dmg = scissorblade.dmg.Script |
07 | button.MouseButton 1 Down:Connect( function () |
08 | if Animationplay = = true then |
09 | local attack = chr.Humanoid:LoadAnimation(script.Attack) |
13 | chr.Humanoid.WalkSpeed = 0 |
16 | chr.Humanoid.WalkSpeed = 60 |
Output says that on line 3, "Blade is not a valid member of Model "Workspace.luvumilo".
I've tried changing the code over and over again, but nothing has worked. If anybody knows how to fix this problem, please answer or comment.
Extra info: Script is in a TextButton inside of a ScreenGui inside of StarterGui (which goes inside the LocalPlayer when server is launched)