Reorganize code in tanks prototype