fixed a lot of direct pointesr that could fuck up and other things