public void Initialise(SlideInCharacterInfo inInfo) { yPos = inInfo.yPos; for (int i = 0; i < 2; i++) { (commentLine[i]).SetFont(Globals.g_world.font); (commentLine[i]).SetLineAtlas(Globals.g_world.GetAtlas(AtlasType.kAtlas_FontLines)); (commentLine[i]).SetColourAtlas(Globals.g_world.GetAtlas(AtlasType.kAtlas_FontColours)); } Zobject.ZobjectInfo zInfo = new Zobject.ZobjectInfo(); zInfo.position = Utilities.CGPointMake(160, inInfo.yPos); zInfo.texture = (Globals.g_world.game).GetTexture((TextureType)TextureType.kTexture_PiggySpeechBubble); zInfo.startState = ZobjectState.kZobjectHidden; zInfo.isMapObject = false; speechBubble.Initialise(zInfo); speechBubble.SetShowStyle((int)ZobjectShowStyle.kZobjectShow_SlideInTop); speechBubble.SetHideStyle((int)ZobjectHideStyle.kZobjectHide_SlideToTop); speechBubble.SetShowScale(1.1f); if (inInfo.side == (int)SlideInSide.eLeft) { zInfo.position = Utilities.CGPointMake(55, inInfo.yPos + 80.0f); } else { zInfo.position = Utilities.CGPointMake(260, inInfo.yPos + 80.0f); } if (inInfo.whichCharacter == (int)PlayerType.kPlayerPig) { zInfo.texture = (Globals.g_world.game).GetTexture((TextureType)TextureType.kTexture_PiggyHeadFE); } else { zInfo.texture = (Globals.g_world.game).GetTexture((TextureType)TextureType.kTexture_SheepyHead); } zInfo.startState = ZobjectState.kZobjectHidden; zInfo.isMapObject = false; character.Initialise(zInfo); if (inInfo.side == (int)SlideInSide.eLeft) { character.SetShowStyle((int)ZobjectShowStyle.kZobjectShow_SlideInLeft); character.SetHideStyle((int)ZobjectHideStyle.kZobjectHide_SlideToLeft); } else { character.SetShowStyle((int)ZobjectShowStyle.kZobjectShow_SlideInRight); character.SetHideStyle((int)ZobjectHideStyle.kZobjectHide_SlideToRight); } character.SetShowScale(0.6f); if (inInfo.side == (int)SlideInSide.eLeft) { speechBubble.SetHorizontallyFlipped(true); } else { speechBubble.SetHorizontallyFlipped(false); } }