Added proxies and fixed some crashes.

Fixed BOP crashes, and an entity rendering crash. However, the tile
renderer crash has still not been solved.