I legit cant figure out how to do this. I have asked others and they don’t know it either. I tried about everything I could think of. This is what I have so far
loop:
self.moveRight()
self.moveUp()
self.findNearestEnemy()
“enemy” = “This”
“enemy” self.attack = ('This")
self.attack(“This”)
I was messing around at the bottom and it’s prob not neeeded but PLEASE help me with this. Thanks.
This is also in Python
This is only the first part, but perhaps it can give you a hint:
loop:
self.moveRight()
self.moveUp()
enemy = self.findNearestEnemy()
self.attack(enemy)
self.attack(enemy)
# Add more movement commands here to finish the level.
Hope this helps!
I typed in the code and it worked! Thx man
lol
guards kiled themselfs off w spikes
NEED HELP WITH FINAL KITHMAZE. Been stuck for a week
I’m also stuck here. It says I am successful but never sends me to the next level. I am stuck repeating this level over and over … even when it’s right. I must be missing something.
i have the MAHOGANY GLASSES
loop:
self.moveRight()
self.moveUp()
enemies = self.findEnemies()
for enemy in enemies:
self.attack(enemy)
self.attack(enemy)
self.attack(enemy)
self.moveRight()
self.moveDown()
self.moveDown()
self.moveUp()
I have javascript and I can not find a way to pass the level.
I tried every code on this page.
It won’t even let me use “.self”!
Please help
self
is Python; in JavaScript, you use this
:
loop {
this.moveRight();
this.moveUp();
var enemy = self.findNearestEnemy();
this.attack(enemy);
this.attack(enemy);
// Add more movement commands here to finish the level.
}
This still does not work
Well, what did you put in the “// Add more movement commands here to finish the level.” section that doesn’t do what you expect…???..
Thanks!! Good job
I use Pythic Your using Javascript if it says this.moveup for some reason
I’m having a problem with this level not counting my statements correct (I think).
It tells me that this code is more than 10 statements:
loop {
this.moveRight();
this.moveUp();
while (this.findNearestEnemy() !== null)
this.attack(this.findNearestEnemy());
this.moveRight();
this.moveDown(2);
this.moveUp();
}
Any hints as to what I’m missing? I’ve tried this using
loop {
this.moveRight();
this.moveUp();
var enemy = this.findNearestEnemy();
this.attack(enemy);
this.attack(enemy);
this.moveRight();
this.moveDown(2);
this.moveUp();
}
as well and that gives the same problem with too many statements as well.
It appears that on line 10 you have !== null. Is this intentional?
Hi,
There was a brief time between last night and today where the goals for this level were incorrect. Within the last 4 or so hours, I believe I’ve fixed this issue.
Retry it and see if the problem was fixed.
Sorry!
In Javascript that’s a valid operator.
Oh ok
Currently I have this issue while doing the Python version of CodeCombat and can’t get past the level. It says that i’m not using level than 10 statements in my code.
Here’s a picture: http://puu.sh/lQ7XM/74698bf15b.png