Adding some function but not all tested

adding beam of light and trying double buffering (not functional yet)