Skip to content

Commit

Permalink
Add debug for another way to detect end of fight
Browse files Browse the repository at this point in the history
  • Loading branch information
Gl0 committed Dec 23, 2016
1 parent c95f8c4 commit 5b0ce2c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
3 changes: 2 additions & 1 deletion DamageMeter.Core/PacketProcessingFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ public static void UpdateAbnormalityTracker()
{ typeof(Tera.Game.Messages.SPlayerChangeMp) , new Action<Tera.Game.Messages.SPlayerChangeMp>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
{ typeof(Tera.Game.Messages.SPartyMemberChangeHp) , new Action<Tera.Game.Messages.SPartyMemberChangeHp>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
{ typeof(Tera.Game.Messages.SDespawnUser) , Helpers.Contructor<Func<Tera.Game.Messages.SDespawnUser , S_DESPAWN_USER>>()},
{ typeof(Tera.Game.Messages.SNpcStatus) , new Action<Tera.Game.Messages.SNpcStatus>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
{ typeof(Tera.Game.Messages.SNpcStatus) , new Action<Tera.Game.Messages.SNpcStatus>((x)=>NotifyProcessor.Instance.SNpcStatus(x)) },
// { typeof(Tera.Game.Messages.SNpcStatus) , new Action<Tera.Game.Messages.SNpcStatus>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
{ typeof(Tera.Game.Messages.S_PARTY_MEMBER_STAT_UPDATE) , new Action<Tera.Game.Messages.S_PARTY_MEMBER_STAT_UPDATE>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
{ typeof(Tera.Game.Messages.S_PLAYER_STAT_UPDATE) , new Action<Tera.Game.Messages.S_PLAYER_STAT_UPDATE>((x)=>NetworkController.Instance.AbnormalityTracker.Update(x)) },
};
Expand Down
10 changes: 10 additions & 0 deletions DamageMeter.Core/Processing/NotifyProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -505,5 +505,15 @@ internal void UpdateCredits(Tera.Game.Messages.S_UPDATE_NPCGUILD message)
UpdateCredits(message.Type, message.Credits);
}

internal void SNpcStatus(Tera.Game.Messages.SNpcStatus message)
{
NetworkController.Instance.AbnormalityTracker.Update(message);
if (message.Defeated)
{
var boss = NetworkController.Instance.EntityTracker.GetOrPlaceholder(message.Npc) as NpcEntity;
if (boss?.Info.Boss==true && boss.Info.HuntingZoneId==950)
BasicTeraData.LogError("Retreat test: "+ boss.Info.HuntingZoneId+":"+ boss.Info.TemplateId + (_lastBossMeterUser==message.Npc?" actual boss": " other boss"), false, true);
}
}
}
}
2 changes: 1 addition & 1 deletion TeraCommon

0 comments on commit 5b0ce2c

Please sign in to comment.