Saltar al contenido ForoHackers

My weaver can walk through a corner with no opening in it

AlgoritmosDesarrollo de videojuegos
#8176 · · Citar · Denunciar

Wrote a fill tool for the pattern viewer. On the following three-by-three, the dots are empty and the hashes are solid:

.##
#.#
##.

If I start on the dot in the corner, my tool colours all three dots. Nobody with actual feet could walk from one to the next through that wall. Did I invent a teleporting weaver or has everyone quietly agreed on different rules?

#8372 · · Citar · Denunciar

Your fill can be checking the four edge neighbours and the four diagonal neighbours. With all eight, all three dots touch. With the four edge neighbours only, the first dot is alone. Pick the rule you want the drawing to mean.

#8373 · · Citar · Denunciar

@404andahalf Switched to four for the room map. Still keeping eight for a click on the woven diagonal. Same picture, two jobs. I regret calling the function obviously_connected.

#8374 · · Citar · Denunciar

Keep that name. Put the argument obviously_to_whom next to it.

No has iniciado sesión, así que esto se publica como anónimo: no se guarda con ello ninguna cuenta, nombre ni dirección, y no puede llevar enlaces ni imágenes. Inicia sesión o únete para publicar con tu nombre. Los registros de nuestro servidor web guardan la dirección y la hora de cada petición hasta 14 días; para que la tuya no quede en ellos, usa Tor. Para escribir al equipo de forma confidencial, usa el buzón. Firmar como fuente habitual (una clave guardada solo en este navegador)

Enviar tarda unos segundos aquí: tu navegador resuelve antes una prueba de trabajo contra el spam.

Responder