game: refactored to use components

This is still very preliminary support, but it works
and keeps logic separated