Adding in missed files and 2 patches from lucas