|
@@ -8,6 +8,7 @@ namespace VEngine
|
|
|
public class Asset : Loadable, IEnumerator
|
|
|
{
|
|
|
public static readonly Dictionary<string, Asset> Cache = new Dictionary<string, Asset>();
|
|
|
+ public static readonly Dictionary<string, int> CacheCount = new Dictionary<string, int>();
|
|
|
|
|
|
public static readonly List<Asset> Unused = new List<Asset>();
|
|
|
|
|
@@ -78,6 +79,15 @@ namespace VEngine
|
|
|
{
|
|
|
item = Versions.CreateAsset(path, type);
|
|
|
Cache.Add(path, item);
|
|
|
+
|
|
|
+ }
|
|
|
+ if (CacheCount.ContainsKey(path))
|
|
|
+ {
|
|
|
+ CacheCount[path] = CacheCount[path] + 1;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ CacheCount.Add(path, 0);
|
|
|
}
|
|
|
|
|
|
if (completed != null) item.completed += completed;
|