This commit is contained in:
kron
2025-09-10 15:56:57 +08:00
parent 65548e6c6a
commit eca11715d5
3 changed files with 13 additions and 9 deletions

View File

@@ -295,17 +295,16 @@ export const getGameAPI = async (battleId) => {
};
});
});
const totalRounds = Object.keys(data.roundsData).length;
(goldenRoundRecords || []).forEach((item, index) => {
item.arrowHistory.forEach((arrow) => {
if (!data.roundsData[playerStats.length + index + 1]) {
data.roundsData[playerStats.length + index + 1] = {};
if (!data.roundsData[totalRounds + index + 1]) {
data.roundsData[totalRounds + index + 1] = {};
}
if (!data.roundsData[playerStats.length + index + 1][arrow.playerId]) {
data.roundsData[playerStats.length + index + 1][arrow.playerId] = [];
if (!data.roundsData[totalRounds + index + 1][arrow.playerId]) {
data.roundsData[totalRounds + index + 1][arrow.playerId] = [];
}
data.roundsData[playerStats.length + index + 1][arrow.playerId].push(
arrow
);
data.roundsData[totalRounds + index + 1][arrow.playerId].push(arrow);
});
});

View File

@@ -212,7 +212,9 @@ onMounted(() => {
}
.target {
position: relative;
padding: 10px;
margin: 10px;
width: calc(100% - 20px);
height: calc(100% - 20px);
}
.e-value {
position: absolute;
@@ -244,6 +246,7 @@ onMounted(() => {
}
.target > image:last-child {
width: 100%;
height: 100%;
}
.hit {
position: absolute;
@@ -261,6 +264,7 @@ onMounted(() => {
display: flex;
justify-content: center;
align-items: center;
/* transform: translate(-50%, -50%); */
}
.hit > text {
transform: scaleX(0.7) translateY(-0.5px);

View File

@@ -18,7 +18,7 @@ const data = ref({
onLoad(async (options) => {
if (options.battleId) {
const result = await getGameAPI(
options.battleId || "BATTLE-1755484626207409508-955"
options.battleId || "BATTLE-1756453741433684760-512"
);
data.value = result;
Object.values(result.bluePlayers).forEach((p, index) => {
@@ -150,6 +150,7 @@ const onClickTab = (index) => {
</view>
<view
v-if="
selected > 0 &&
selected >= data.goldenRounds.length &&
selected <= data.goldenRounds.length
"