Fix segfault
Fix fps
Remove useless variables
Fix segfault
Improve fps
Improve fps again