olistic / warriorjs

🏰 An exciting game of programming and Artificial Intelligence
https://warriorjs.com
MIT License
9.41k stars 489 forks source link

Look ability not working #167

Closed wizeowl closed 6 years ago

wizeowl commented 6 years ago

Warrior js version: 0.4.2 When I invoke warrior.look() I get the following error

Invalid Player code: warrior.look is not a function

Finally thank you for the great game and keep the good work (y)

olistic commented 6 years ago

Hello @wizeowl, thanks for your interest in the project!

What level are you at? Does the README in your profile say you have warrior.look() available?

wizeowl commented 6 years ago

I'm at the beginner tower. I took the README as indication and didn't think the list of sense was exclusive Now I understand why getLocation always returns [1,0]

Also thanks for the fast feedback :+1:

bbugh commented 6 years ago

Hi, I'm at "baby steps level 6" and it's telling me that look is not a function. It is listed in the README and has worked previously. I'm in the web client, if that matters.

shiar commented 5 years ago

I encountered the same warning halfway through Baby Steps level 4 from one run to the next. Also going back to previous levels had previously successful code stop working. The level readme retained warrior.look() as an ability.

After restarting my browser, the ability disappeared from the readme as intended. So the actual bug is that future abilities were available in the first place.

olistic commented 5 years ago

@shiar Do you recall when was it that you experienced that problem? The reason I asked is because I deployed a fix for that issue last Friday, if it was later then I'll need to revisit the issue.

@bbugh sorry, I completely missed your comment!

shiar commented 5 years ago

It was in fact last Friday when this occurred IIRC, so it might have been your fix which broke things for me :) Thanks! Consider it solved.