Fixed buffer overflow problem, some neighbor issues