Play Home Contribute Github Join Us! Discourse Staff Members Github Contribution Guides Team

(SOLVED) JS: Syntax problem on the "Agrip protection" level

Hello.

I have a problem with game syntax understanding. I cant use “else if”, “elif”, “&&”. Its a game restriction or what?

And what about VAR, I red that it`s an old syntax.

Pls check the pic. The simple code isn`t work. What is wrong?

Hi Victor, welcome to the CodeCombat discourse.
I’m not sure about the other commands but this one has an error because you have an extra pair of brackets () around the hero.attack(enemy). You only need one.
Danny

1 Like

Yes, Y are right.
Sometimes we need some rest…

I’m glad to hear that. Please could you not post the solution though.
Thanks,
Danny