fixed buggs, managed to get it working, sortof