Added factory for GameObjects.