"attempt to index nil with 'Value' " error


the line I’m on is the line that is giving me the error

image
and here’s the error message

I’ve already tried looking it up on YouTube and the Dev hub so this is my last resort ig
does anyone know how to fix it and why is it erroring.

The error means that the Kills ValueBase doesn’t exist when the script gets to that line. (Or the creator ValueBase)

So do you know a way to fix it?

Check if tag exists first, before assigning the killer variable it’s value

I think it is because it hasn’t loaded yet when the code runs there, you could use :WaitForChild() to wait for the value to load.