acleverpun / letsgoonanadventure

Adventure game prototype built from our skeleton
0 stars 0 forks source link

Cleanup Sprites, Entities, and Tiles #23

Closed rosshadden closed 9 years ago

rosshadden commented 9 years ago

Entity instances should create a Sprite. If the entity is marked as "visible" in the map, we will add the texture image as well, and make it render on the canvas. Otherwise, we will set as invisible (leaving physics enabled).

Also, in the loop where we create instances if the types are known, we should remove the check for "spawn". Since it's not a known type it won't be created, and thus there's no reason to explicitly blacklist it.

WarpTile instances should register a collision function that does the warping logic, instead of the crappy grid-based collision thing I implemented quickly.