bug修复
This commit is contained in:
@@ -189,6 +189,7 @@ watch(
|
|||||||
position: relative;
|
position: relative;
|
||||||
background-color: #00000038;
|
background-color: #00000038;
|
||||||
width: 100rpx;
|
width: 100rpx;
|
||||||
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.rank-tag-progress {
|
.rank-tag-progress {
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ function exit() {
|
|||||||
}
|
}
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
const battleInfo = uni.getStorageSync("last-battle");
|
const battleInfo = uni.getStorageSync("last-battle");
|
||||||
// console.log("----battleInfo", battleInfo);
|
console.log("----battleInfo", battleInfo);
|
||||||
data.value = battleInfo;
|
data.value = battleInfo;
|
||||||
const mine = battleInfo.playerStats.find((p) => p.id === user.value.id);
|
const mine = battleInfo.playerStats.find((p) => p.id === user.value.id);
|
||||||
rank.value =
|
rank.value =
|
||||||
@@ -52,8 +52,8 @@ onMounted(async () => {
|
|||||||
totalPoints.value = mine.totalScore;
|
totalPoints.value = mine.totalScore;
|
||||||
ifWin.value = battleInfo.mode === 1 && mine.team === battleInfo.winner;
|
ifWin.value = battleInfo.mode === 1 && mine.team === battleInfo.winner;
|
||||||
}
|
}
|
||||||
// const result = await getHomeData();
|
const result = await getHomeData();
|
||||||
// if (result.user) updateUser(result.user);
|
if (result.user) updateUser(result.user);
|
||||||
});
|
});
|
||||||
|
|
||||||
const checkBowData = () => {
|
const checkBowData = () => {
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ const playersSorted = ref([]);
|
|||||||
const currentRound = ref(1);
|
const currentRound = ref(1);
|
||||||
const totalRounds = ref(0);
|
const totalRounds = ref(0);
|
||||||
const start = ref(false);
|
const start = ref(false);
|
||||||
const startCount = ref(false);
|
const startCount = ref(true);
|
||||||
const power = ref(0);
|
const power = ref(0);
|
||||||
const scores = ref([]);
|
const scores = ref([]);
|
||||||
const blueScores = ref([]);
|
const blueScores = ref([]);
|
||||||
@@ -75,7 +75,7 @@ watch(
|
|||||||
onLoad(async (options) => {
|
onLoad(async (options) => {
|
||||||
if (options.battleId) {
|
if (options.battleId) {
|
||||||
const battleInfo = uni.getStorageSync("current-battle");
|
const battleInfo = uni.getStorageSync("current-battle");
|
||||||
// console.log("----battleInfo", battleInfo);
|
console.log("----battleInfo", battleInfo);
|
||||||
if (battleInfo) {
|
if (battleInfo) {
|
||||||
battleId.value = battleInfo.id;
|
battleId.value = battleInfo.id;
|
||||||
battleType.value = battleInfo.config.mode;
|
battleType.value = battleInfo.config.mode;
|
||||||
@@ -245,7 +245,6 @@ async function onReceiveMessage(messages = []) {
|
|||||||
// 这里会掉多次;
|
// 这里会掉多次;
|
||||||
timerSeq.value += 1;
|
timerSeq.value += 1;
|
||||||
battleId.value = msg.id;
|
battleId.value = msg.id;
|
||||||
startCount.value = true;
|
|
||||||
step.value = 2;
|
step.value = 2;
|
||||||
if (battleType.value === 1) {
|
if (battleType.value === 1) {
|
||||||
redTeam.value = msg.groupUserStatus.redTeam;
|
redTeam.value = msg.groupUserStatus.redTeam;
|
||||||
@@ -336,6 +335,7 @@ async function onReceiveMessage(messages = []) {
|
|||||||
}
|
}
|
||||||
if (msg.constructor === MESSAGETYPES.MeleeAllReady) {
|
if (msg.constructor === MESSAGETYPES.MeleeAllReady) {
|
||||||
start.value = true;
|
start.value = true;
|
||||||
|
startCount.value = true;
|
||||||
step.value = 3;
|
step.value = 3;
|
||||||
seq.value += 1;
|
seq.value += 1;
|
||||||
timerSeq.value = 0;
|
timerSeq.value = 0;
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ const { user } = storeToRefs(store);
|
|||||||
const gameType = ref(0);
|
const gameType = ref(0);
|
||||||
const teamSize = ref(0);
|
const teamSize = ref(0);
|
||||||
const start = ref(false);
|
const start = ref(false);
|
||||||
const startCount = ref(false);
|
const startCount = ref(true);
|
||||||
const battleId = ref("");
|
const battleId = ref("");
|
||||||
const currentRound = ref(1);
|
const currentRound = ref(1);
|
||||||
const power = ref(0);
|
const power = ref(0);
|
||||||
@@ -117,7 +117,6 @@ async function onReceiveMessage(messages = []) {
|
|||||||
// 这里会掉多次;
|
// 这里会掉多次;
|
||||||
timerSeq.value += 1;
|
timerSeq.value += 1;
|
||||||
battleId.value = msg.id;
|
battleId.value = msg.id;
|
||||||
startCount.value = true;
|
|
||||||
players.value = [
|
players.value = [
|
||||||
...msg.groupUserStatus.redTeam,
|
...msg.groupUserStatus.redTeam,
|
||||||
...msg.groupUserStatus.blueTeam,
|
...msg.groupUserStatus.blueTeam,
|
||||||
@@ -131,6 +130,7 @@ async function onReceiveMessage(messages = []) {
|
|||||||
if (msg.id !== battleId.value) return;
|
if (msg.id !== battleId.value) return;
|
||||||
if (msg.constructor === MESSAGETYPES.MeleeAllReady) {
|
if (msg.constructor === MESSAGETYPES.MeleeAllReady) {
|
||||||
start.value = true;
|
start.value = true;
|
||||||
|
startCount.value = true;
|
||||||
seq.value += 1;
|
seq.value += 1;
|
||||||
timerSeq.value = 0;
|
timerSeq.value = 0;
|
||||||
tips.value = "请连续射出6支箭";
|
tips.value = "请连续射出6支箭";
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ const isFinalShoot = ref(false);
|
|||||||
onLoad(async (options) => {
|
onLoad(async (options) => {
|
||||||
if (options.battleId) {
|
if (options.battleId) {
|
||||||
const battleInfo = uni.getStorageSync("current-battle");
|
const battleInfo = uni.getStorageSync("current-battle");
|
||||||
// console.log("----battleInfo", battleInfo);
|
console.log("----battleInfo", battleInfo);
|
||||||
if (battleInfo) {
|
if (battleInfo) {
|
||||||
battleId.value = battleInfo.id;
|
battleId.value = battleInfo.id;
|
||||||
start.value = true;
|
start.value = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user