示例#1
0
    public override IEnumerator PerformFirstPass()
    {
        GameObject              go = Service.Get <GameObject>();
        ManifestContentKey      zoneDefinitionManifestContentKey = StaticGameDataUtils.GetManifestContentKey(typeof(ZoneDefinition));
        AssetRequest <Manifest> assetZoneRequest = Content.LoadAsync(zoneDefinitionManifestContentKey);
        ManifestContentKey      worldDefinitionManifestContentKey = StaticGameDataUtils.GetManifestContentKey(typeof(WorldDefinition));
        AssetRequest <Manifest> assetWorldRequest = Content.LoadAsync(worldDefinitionManifestContentKey);

        yield return(assetZoneRequest);

        yield return(assetWorldRequest);

        ZoneTransitionService service = go.AddComponent <ZoneTransitionService>();

        service.SetIglooSplashScreenKey(IglooSplashScreen);
        service.SetZonesFromManifest(assetZoneRequest.Asset);
        service.SetWorldsFromManifest(assetWorldRequest.Asset);
        Service.Set(service);
    }