Working solution. Will gut and use frameworks!
First functioning version. Will probably gut to use python