So I have a script inside of a Monster NPC that does stuff when it dies. (it's health get lowered when it touches a block called 'IceCube'. It worked in a different place, and when I tried it out in 'Run' mode it also worked. I even named a part 'IceCube' and killed him with that and everything worked
Then when I went to 'play solo' and used the water bucket, It still did damage and killed him, it's just the script didn't work
2 errors came up only on 'play solo':
17:17:16.946 - Torso is not a valid member of Part 17:17:16.947 - Script 'Workspace.Lava Monster.Head.DeathSound', Line 3 17:17:16.948 - Stack End 17:17:16.948 - Disconnected event because of exception 17:17:18.134 - Humanoid is not a valid member of Model 17:17:18.135 - Script 'Workspace.Lava Monster.Monster', Line 41 17:17:18.135 - Stack End
Here's the script:
script.Parent.Parent:WaitForChild("Humanoid").Died:connect(function()
script.Parent.Parent.Torso.BrickColor = BrickColor.new("Really black")
script.Parent.Parent["Left Arm"].BrickColor = BrickColor.new("Really black")
script.Parent.Parent["Left Leg"].BrickColor = BrickColor.new("Really black")
script.Parent.Parent["Right Arm"].BrickColor = BrickColor.new("Really black")
script.Parent.Parent["Right Leg"].BrickColor = BrickColor.new("Really black")
script.Parent.Parent.Monster:Destroy()
script.Parent.Roar:Play()
wait(1.5)
game.Workspace.Crumble:Play()
script.Parent.Parent.Torso.Fire.Enabled = false
script.Parent.Parent.Torso.Smoke.Enabled = true
wait(4)
script.Parent.Parent.Torso.Smoke.Enabled = false
end)

1 comment
Thank you so much! I've been working on this update for the past 3 days and It's finally coming to a close thanks to you! I was about to say "I don't think that's the problem because I removed the ragdoll script and it worked (then the same error happened again :P) but now I realize what that error message means and I can learn from this greatly! Thanks!