Major change of logic, some refactoring

Turned game logic around, simpler now (no more differential equations).

Also some refactoring to make code more robust and flexible.