protected override void ExecuteImp(BaseGame game, long tick) { if (!m_isSent) { m_isSent = true; game.SendLivingFall(m_living, m_toX, m_toY, m_fallSpeed, m_action, m_type); } if (m_toY > m_living.Y + m_fallSpeed) { m_living.SetXY(m_toX, m_living.Y + m_fallSpeed); } else { m_living.SetXY(m_toX, m_toY); if (game.Map.IsOutMap(m_toX, m_toY)) { m_living.SyncAtTime = false; m_living.Die(); Console.WriteLine("掉落Fall" + m_living.IsLiving.ToString()); } if (m_callback != null) { //m_living.RunLuaFunction(m_callback); m_living.CallFuction(m_callback, 0); } Finish(tick); } }
private void player_BeginFitting(Living living) { this.m_turn--; if (this.m_turn < 0) { this.Stop(); } else { living.AddBlood(-this.m_count, 1); if (living.Blood <= 0) { living.Die(); if (this.m_player != null && this.m_player is Player) { (this.m_player as Player).PlayerDetail.OnKillingLiving(this.m_player.Game, 2, living.Id, living.IsLiving, this.m_count, (this.m_player as Player).PlayerDetail.IsArea); } } } }
protected override void ExecuteImp(BaseGame game, long tick) { m_living.Die(); Finish(tick); }