Skip to content

Deaths not properly counted in ToA for return messageΒ #6779

@themrrobert

Description

@themrrobert

πŸ› Bug Report

When a trip of ToA containing multiple quantities returns, it shows 0 deaths, even if there were deaths.

Like you might see one unique, and nothing else, on a 2 kc trip.

This is causing extra KC that you shouldn't be getting, and confuses players.

Looks like it comes down to this:

detaileldUsers[x].deaths is an array.....

			for (const { id, points, deaths } of detailedUsers[x]) {
				const currentUser = raidResults.get(id)!;
				currentUser.points += points;
				currentUser.deaths += deaths.length;

Now, because earlier in the code, raidResults is initialized thusly....

		for (const user of allUsers) {
			raidResults.set(user.id, {
				mUser: user,
				points: 0,
				deaths: 0,
				kc: await user.fetchMinigameScore('tombs_of_amascut')
			});
		}

most likely that first code should be updating the user in the raidResults set += detailedUsers[x][i].deaths.length.
*where x is the raid number out of quantity , and i is the iterated user.

currently its doing an array + integer.

and i'm not even sure what its trying to use later, but yea, its definitely broken. and i dont have the time to fix right now, so this is to let people know about the bug..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions