public void gift_loaded_callback(AssetBundle aBundle, string aBundleName) { mLoader = new CharacterLoader(); mLoader.complete_load_character(aBundle, aBundleName); //mManager.mCharacterBundleManager.add_bundle_to_unload(aBundle); IsLoaded = true; }
public void sunset_loaded_callback(AssetBundle aBundle, string aBundleName) { mLoader = new CharacterLoader(); mLoader.complete_load_character(aBundle, aBundleName); mBackground = new FlatElementImage(mLoader.Images.background1, mLoader.Sizes.mBackSize, 0); mBackground.HardPosition = mFlatCamera.get_point(0, 0); mStubbyHairyGrass = construct_flat_image("BG-1", 2); mElement.Add(mBackground); mElement.Add(mStubbyHairyGrass); var sun = mManager.mCharacterBundleManager.get_image("SUN"); mSun = new FlatElementImage(sun.Image, sun.Data.Size, 1); var light = mManager.mCharacterBundleManager.get_image("SHINE"); mLightRay = new FlatElementImage(light.Image, light.Data.Size, 1); mLightRay.HardPosition = mFlatCamera.get_point(0, -10000); mElement.Add(mSun); mElement.Add(mLightRay); //mManager.mCharacterBundleManager.add_bundle_to_unload(aBundle); IsLoaded = true; //prep the sky for fetus set_sun(-1, true); set_sky_color(0); }
public void start_screen_loaded_callback(AssetBundle aBundle, string aBundleName) { mBundle = aBundle; CharacterLoader loader = new CharacterLoader(); loader.complete_load_character(aBundle, aBundleName); mLoader = loader; //create background mElement.Add(construct_flat_image("BACKGROUND", 0)); mElement.Add(construct_flat_image("FG-1", 30)); for (int i = 2; i < 30; i++) { var img = construct_flat_image("BG-" + i, 30 - i); mElement.Add(img); } set_start_screen_character_transparency(); NewMenuReferenceBehaviour refs = mManager.mNewRef; //kinect required image if (!GameConstants.ALLOW_NO_KINECT && mManager.mZigManager.is_reader_connected() == 0) { //TODO put up a KINECT REQUIRED message mKinectRequiredImage = construct_flat_image("FG-1", 1000); mKinectRequiredImage.SoftPosition += new Vector3(0, -400, 0); mElement.Add(mKinectRequiredImage); } //mMenuBackground; //mMenuSelector; //mResume; //mRestart; //???? mMessageText = new FlatElementText(refs.genericFont, 60, "", 1); mMessageText.HardPosition = mRTCamera.get_point(Vector3.zero) + new Vector3(0, 400, 0); mElement.Add(mMessageText); start_configuration_display(); IsInitialized = true; }
public void scene_loaded_callback(AssetBundle aBundle, string aBundleName) { //Debug.Log("loading character in CharacterLoader " + aBundleName); //TODo don't do this serial CharacterLoader loader = new CharacterLoader(); loader.complete_load_character(aBundle, aBundleName); if (mManager.mGameManager.character_changed_listener(loader)) { aBundle.Unload(false); } else { mUnloadAtEnd.Add(aBundle); } }