BROKEN: Found holes in resource management system.

Gonna have to think about it some more.
Probably have to do a rewrite of every resource cache...