Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

expected identifier when parsing expression got 'then'?

Asked by
Glvt102 11
3 years ago

So, im trying to make a gui, that appears after killing a certain enemy for a few seconds. I suck in scripting badly so uh... halp.

if game.Workspace.enemyleader1.Humanoid.Health.Value = < 0 then game.StarterGui.KILLALLENEMIES.Enabled = true wait (2) game.StarterGui.KILLALLENEMIES.Enabled = false end

1 answer

Log in to vote
0
Answered by 3 years ago
Edited 3 years ago

The issue is simple. In the first line, there should be no "=" sign:

if game.Workspace.enemyleader1.Humanoid.Health.Value < 0 then
game.StarterGui.KILLALLENEMIES.Enabled = true wait (2)
game.StarterGui.KILLALLENEMIES.Enabled = false end
0
Oh, i see, thanks! Glvt102 11 — 3y
0
there can be actually, they just did it in the wrong order: "<=" not "=<" mixgingengerina10 223 — 3y
Ad

Answer this question