public EOChatBubble(NPC following)
			: base(EOGame.Instance)
		{
			m_ref = following;
			m_isChar = false;
			DrawOrder = following.Index + (int)ControlDrawLayer.BaseLayer + 1; //use index for draw order
			_initLabel();
			Visible = false;
			EOGame.Instance.Components.Add(this);
		}
Example #2
0
		public static void Show(PacketAPI api, NPC shopKeeper)
		{
			if (Instance != null)
				return;

			Instance = new ShopDialog(api, shopKeeper.Data.ID);

			//request from server is based on the map index
			if (!api.RequestShop(shopKeeper.Index))
			{
				Instance.Close();
				Instance = null;
				EOGame.Instance.DoShowLostConnectionDialogAndReturnToMainMenu();
			}
		}
Example #3
0
		public void AddOtherNPC(NPCData data)
		{
			lock (_npcListLock)
			{
				NPC newNPC = new NPC(data);
				newNPC.Initialize();
				newNPC.Visible = true;
				npcList.Add(newNPC);
			}
		}
Example #4
0
		private void _renderSpellOnNPC(short spellID, NPC renderer)
		{
			if (spellID < 1) return;

			var spellInfo = World.Instance.ESF.GetSpellRecordByID(spellID);
			var effect = new EffectRenderer((EOGame)Game, renderer, delegate { });
			effect.SetEffectInfoTypeAndID(EffectType.Spell, spellInfo.Graphic);
			effect.ShowEffect();
		}
		public EONPCSpriteSheet(INativeGraphicsManager gfxManager, NPC npcToWatch)
		{
			_gfxManager = gfxManager;
			_npc = npcToWatch;
		}