Fixes for cache system, beginnings of new features