diff --git a/hud/hud.js b/hud/hud.js index bb5e34c..79f1f7d 100644 --- a/hud/hud.js +++ b/hud/hud.js @@ -133,7 +133,7 @@ const HUD = { existingBars.forEach(bar => existingIds.add(parseInt(bar.dataset.taskId))); // Get current task IDs - const currentIds = new Set(this.tasks.map(t => t.ID)); + const currentIds = new Set(this.tasks.map(t => t.TaskID)); // Remove bars for tasks that no longer exist existingBars.forEach(bar => { @@ -210,7 +210,7 @@ const HUD = { const bars = document.querySelectorAll('.task-bar'); bars.forEach(bar => { const taskId = parseInt(bar.dataset.taskId); - const task = this.tasks.find(t => t.ID === taskId); + const task = this.tasks.find(t => t.TaskID === taskId); if (task) { this.updateTaskBar(bar, task); } @@ -330,7 +330,7 @@ const HUD = { if (data.OK) { // Remove from local list immediately - this.tasks = this.tasks.filter(t => t.ID !== task.TaskID); + this.tasks = this.tasks.filter(t => t.TaskID !== task.TaskID); this.renderTasks(); this.showFeedback('Task accepted!', 'success'); } else {