mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-11-18 09:45:28 +00:00
fix(skill): a start with a skill handle still in progress is dropped, as the client
LWOSkillComponent::msgStartSkill (0x00d45cb0) logs and ignores a StartSkill whose skill handle is still waiting on behavior syncs. The server ran it a second time: the hits, the imagination cost and the mission progress twice. Live captures hold 22 byte-identical StartSkill resends with the same handle a few packets apart. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -137,6 +137,10 @@ namespace GameMessages {
|
||||
Entity* entity = &entityRef;
|
||||
if (skillID == 1561 || skillID == 1562 || skillID == 1541) return;
|
||||
|
||||
// LWOSkillComponent::msgStartSkill (0x00d45cb0): a start with a skill handle still in progress is dropped
|
||||
const auto* const castingSkills = entity->GetComponent<SkillComponent>();
|
||||
if (castingSkills && castingSkills->IsSkillPending(uiSkillHandle)) return;
|
||||
|
||||
MissionComponent* comp = entity->GetComponent<MissionComponent>();
|
||||
if (comp) {
|
||||
comp->Progress(eMissionTaskType::USE_SKILL, skillID);
|
||||
|
||||
Reference in New Issue
Block a user