I am working on making a keyboard hero arena basic copy and I have a script which checks if the player chatted a certain word or not and it not working(the error was "expected 'then' near '=') and this is my script:
game.Players.PlayerAdded:connect(function(player)
player.Chatted:connect(function(msg)
if msg = script.Parent.Name then
script.Parent.Zombie.Health = 0
end
end)
end)
this is in a normal script, is in the enemy that you need to eliminate and the error is on line 3.

1 comment
Lowercase the if ;)