Quicksort and other hidden levels


#1

If you check the level editor, there are some older levels such as quicksort-the-spiral that are not in the current campaign. I also recall seeing a page with levels from older campaigns but I can’t find it anymore.
These levels have the same art style but they don’t use our current heroes and have a few other differences. For example, in quicksort there is a button that expands the editor, making it fill the screen, which can be useful. However, there were no error messages for incorrect code.

Anyway, these levels are interesting and they cover useful concepts. Why aren’t they in the current campaign? Will they be added?

Another thing, swapping items in quicksort sometimes made the ogres fly off the screen and not return. And are we supposed to sort them in order from smallest on the left to biggest on the right?


#2

If I recall right Nick mentioned something about shutting the older levels down due to changes in the CodeCombat-Codebase, effectively rendering the old levels unplayable.
I’ll poke him about it.


Some of the ideas of these levels will apparently be implemented in the future as course-type levels while the other ones are still loadable in the editor. In theory one can load them there, update them (especially in the referee) and migrate to a modern level type.

In their current state they are rarely played and full of bugs so support for them has discontinued.


#3

I also think ogres of hanoi would be great to have as a fully-playable level.
I managed to pass it yesterday but not using the proper method. Instead, I just wrote out each individual move. I then searched up and studied the recursive method and might have understood it. Unfortunately, I couldn’t get say() to work for some reason.

I took a look at the level in the editor but couldn’t find anything resembling a referee. The say() causing the ogres to move reminded me of the level decoy drill, a level in the current campaign, but I couldn’t find any ref code other than the part for spawning coins.

A remake of ogres of hanoi should have stacks at least 6 high to make writing out each individual move less viable.


#4

Would be thrilled to have any help migrating those or remaking them with all the latest tools. (Back then, we didn’t even have Referees–we just wrote out the code in JavaScript in the chooseAction and hear methods of each unit with custom behavior, and debugging was terrible because you had to reload the page all the time.)


#5

I checked the levels and the extra code was indeed located in those methods for each unit. Even Decoy Drill had custom behaviour for the hear method written in JavaScript. Since that level is in the middle of the current campaign, the transition to CoffeeScript and referees must have happened later than I thought.
Migrating those levels would be tricky so that’s a task for a veteran level builder.

Possibility: Instead of custom hear behaviour for each ogre, why not just make one referee that does the hearing and moving?


#6

Wow. It’s really nice to see people are still interested in my old levels. I will to make some time to update them this summer so they are playable again. :smiley:


#7

A benefit of being able to try these algorithms in CodeCombat is the visual representation which can make them easier to conceptualise. It was nice to see each swap and comparison in quicksort happening in order. Plus, they cover more difficult topics and CodeCombat needs more of those.
Maybe in the future there could be levels about graph theory and more.


#8

Please migrate those levels to the current campaign! That would be lovely! :heart: