Compare commits
1 Commits
a2674aae5b
...
developmen
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
75c7df0e9c |
@@ -48,7 +48,7 @@ const onOver = async () => {
|
|||||||
|
|
||||||
async function onReceiveMessage(messages = []) {
|
async function onReceiveMessage(messages = []) {
|
||||||
messages.forEach((msg) => {
|
messages.forEach((msg) => {
|
||||||
if (msg.constructor === MESSAGETYPES.ShootSyncMeArrowID) {
|
if (msg.constructor === MESSAGETYPES.ShootSyncMeArrowID && start.value) {
|
||||||
if (scores.value.length < total) {
|
if (scores.value.length < total) {
|
||||||
scores.value.push(msg.target);
|
scores.value.push(msg.target);
|
||||||
currentRound.value += 1;
|
currentRound.value += 1;
|
||||||
@@ -109,7 +109,11 @@ onBeforeUnmount(() => {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<Container :bgType="1" title="个人单组练习" :showBottom="!start && !scores.length">
|
<Container
|
||||||
|
:bgType="1"
|
||||||
|
title="个人单组练习"
|
||||||
|
:showBottom="!start && !scores.length"
|
||||||
|
>
|
||||||
<view>
|
<view>
|
||||||
<TestDistance v-if="!practiseId" />
|
<TestDistance v-if="!practiseId" />
|
||||||
<block v-if="practiseId">
|
<block v-if="practiseId">
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ const onOver = async () => {
|
|||||||
|
|
||||||
async function onReceiveMessage(messages = []) {
|
async function onReceiveMessage(messages = []) {
|
||||||
messages.forEach((msg) => {
|
messages.forEach((msg) => {
|
||||||
if (msg.constructor === MESSAGETYPES.ShootSyncMeArrowID) {
|
if (msg.constructor === MESSAGETYPES.ShootSyncMeArrowID && start.value) {
|
||||||
if (scores.value.length < total) {
|
if (scores.value.length < total) {
|
||||||
scores.value.push(msg.target);
|
scores.value.push(msg.target);
|
||||||
if (practiseId && scores.value.length === total / 2) {
|
if (practiseId && scores.value.length === total / 2) {
|
||||||
@@ -109,7 +109,7 @@ onBeforeUnmount(() => {
|
|||||||
<ShootProgress
|
<ShootProgress
|
||||||
:tips="`请连续射${total}支箭`"
|
:tips="`请连续射${total}支箭`"
|
||||||
:start="start"
|
:start="start"
|
||||||
:total="360"
|
:total="0"
|
||||||
:onStop="onOver"
|
:onStop="onOver"
|
||||||
/>
|
/>
|
||||||
<view class="user-row">
|
<view class="user-row">
|
||||||
|
|||||||
Reference in New Issue
Block a user