2023-06-09 22:59:20 +08:00
|
|
|
import resource from '../../data/resource.json';
|
2023-06-14 19:20:24 +08:00
|
|
|
import { Resource, getTypeByResource } from './resource';
|
2023-06-09 22:59:20 +08:00
|
|
|
|
2023-06-14 19:20:24 +08:00
|
|
|
const info = resource;
|
2023-06-09 22:59:20 +08:00
|
|
|
|
|
|
|
export function readyAllResource() {
|
2023-06-15 12:35:43 +08:00
|
|
|
info.resource.forEach(v => {
|
2023-06-14 19:20:24 +08:00
|
|
|
const type = getTypeByResource(v);
|
|
|
|
if (type === 'zip') {
|
|
|
|
ancTe.zipResource.set(v, new Resource(v, 'zip'));
|
2023-06-09 22:59:20 +08:00
|
|
|
} else {
|
2023-06-14 19:20:24 +08:00
|
|
|
ancTe.resource.set(v, new Resource(v, type));
|
2023-06-09 22:59:20 +08:00
|
|
|
}
|
|
|
|
});
|
|
|
|
}
|