In the level shrapnel every time i want to write code specifically the word throw

Welcome to the forum @Julian_Nicolas_Mende! :partying_face: This is a friendly place where you can ask help on levels, report bugs, or just chat with other coders! Don’t forget to read the guidelines if you haven’t yet. Have a great time!

So for your level, you need to add an if-statement, checking if the distance is less than 15 as you see in the comments on line 11.

if (the distance from the hero to the enemy is less than 15){
     execute the method throw
}
1 Like

We currently have issues in C++ where the throw keyword can’t also be used as a method name and are going to have to come up with some way to rename or alias it.

In the meantime, I’d suggest either doing that level in another language (not C++), or working on levels that don’t require the throw method.

1 Like