Lurker News

Comments (235) 72 threads

Show all comments

Showing thread 7 of 72

th0br02 replies#
You should reinit the map though, otherwise doing this on level 2 causes funny bugs (and makes the game rather easy ;)

    maze.create = function() {};
    var tmp = map.placeObject;
    map.placeObject = function(x, y, t) {
    	if(t == 'exit') tmp(x,y,t);
    };
untitaker_4 replies#
level 2 can be solved by using the two "unlocked" lines to comment out the whole maze.create call, too.
matsemann#
That's kinda the point, though. Read the comments for that file. ;)
mt3ck#
thanks for the help ;)
randunel#
you don't need 2 lines, you only need the one below to overwrite the map function, and leave an open dot :D

map.placeObject(7,4,'exit');var a = {map: {placeObject:function(){}}};a.

zenojevski#
Related: things like these do not work, because of implementation.

    if (false) // <- inserted by me
    for (var ...) { // <- existing code
        ...code...
    }
Too bad, because extra `for`s could be fun...
alnis#
If you reload the game, the map should now re-init on every level.

PS. I'm really enjoying all the creative solutions you guys are coming up with!