don't create invalid objrefs for game object prototypes

Fixes trello#26.
Merge pull request #30 from yelworc/trello#26

don't create invalid objrefs for game object prototypes