Changed some stuff around
Removed unnecessary functions