fixing up missing sprite code and removing legacy, unused ones