This commit is contained in:
2025-11-24 16:01:45 +08:00
parent aa160793e7
commit 46c975591b
45 changed files with 1311 additions and 559 deletions

View File

@@ -106,7 +106,6 @@
<!-- 底部操作栏 -->
<view class="bottom-actions" v-if="!showKeyboard">
<button class="action-btn" type="default" @click="nextRound">下一局</button>
<button class="action-btn primary" type="primary" @click="endGame">结束对局</button>
</view>
</view>
@@ -472,6 +471,17 @@ onMounted(() => {
if (savedSound !== '') {
soundEnabled.value = savedSound
}
// 检查是否有选中的玩家索引(用于分数编辑)
const selectedIndex = uni.getStorageSync('selectedPlayerIndex')
if (selectedIndex !== '' && players.value.length > 0) {
// 延迟执行,确保玩家数据已加载
setTimeout(() => {
selectPlayer(parseInt(selectedIndex))
// 清除临时存储的选中玩家索引
uni.removeStorageSync('selectedPlayerIndex')
}, 100)
}
})
onUnmounted(() => {