public void Dispose()
{
int cnt = _items.Count;
for (int i = 0; i < cnt; i++)
{
PackageItem pi = _items[i];
if (pi.texture != null)
{
if (pi.texture.alphaTexture != null)
{
Object.Destroy(pi.texture.alphaTexture);
}
pi.texture.Dispose();
}
else if (pi.audioClip != null)
{
Object.Destroy(pi.audioClip);
}
else if (pi.bitmapFont != null)
{
FontManager.UnregisterFont(pi.bitmapFont);
}
}
if (_resBundle != null)
{
_resBundle.Unload(true);
}
}