+
diff --git a/src/pages/Game.vue b/src/pages/Game.vue
index 6d25944..08072a7 100644
--- a/src/pages/Game.vue
+++ b/src/pages/Game.vue
@@ -3,6 +3,14 @@ import { computed, onMounted, ref, useTemplateRef, type Ref } from 'vue';
import assets from '../assets';
import AniEle from '../components/AniEle.vue';
+const shootNotice = useTemplateRef('shoot-notice');
+
+defineExpose({
+ init: () => {
+ shootNotice.value?.jumpTo('蓄力');
+ }
+})
+
const props = defineProps<{
userdata: {
@@ -596,12 +604,43 @@ async function gameEnd() {
}
const leaderBoard = ref([
- { name: '始祖鸟', time: 50, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
- { name: '始祖鸟', time: 60, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
- { name: '始祖鸟', time: 70, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
- { name: '始祖鸟', time: 80, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
- { name: '始祖鸟', time: 90, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
- { name: '始祖鸟', time: 100, region: '奥莱北区', store: "上海始祖鸟阿尔法中心" },
+ {
+ "name": "测试用户",
+ "time": 1.7116000000000005,
+ "region": "奥莱",
+ "store": "北京斯普瑞斯"
+ },
+ {
+ "name": "阿迪斯",
+ "time": 1.9645,
+ "region": "奥莱",
+ "store": "北京斯普瑞斯"
+ },
+ {
+ "name": "Mike",
+ "time": 45.5,
+ "region": "大北区",
+ "store": "大连恒隆广场"
+ },
+ {
+ "name": "小白",
+ "time": 83.2,
+ "region": "大西区",
+ "store": "太原万象城"
+ },
+ {
+ "name": "小明",
+ "time": 98.2,
+ "region": "大西区",
+ "store": "太原万象城"
+ },
+ {
+ "name": "Elena",
+ "time": 122.2,
+ "region": "大南区",
+ "store": "深圳湾万象城"
+ }
+
])
const fmtTime = (time: number) => {
@@ -648,12 +687,16 @@ async function finishCollect() {
fill: 'forwards',
}).finished
await sunEndEle.value?.jumpToSoftly('落下');
- document.querySelector('.bar-container')?.animate([
+ await document.querySelector('.bar-container')?.animate([
{ transform: 'translateY(300%)' }], {
duration: 500,
easing: 'ease-in-out',
fill: 'forwards',
- })
+ }).finished
+ //@ts-ignore
+ document.querySelector('.lines').style.display = 'none';
+ //@ts-ignore
+ document.querySelector('.bar-container').style.display = 'none';
showLastPage.value = true;
@@ -661,6 +704,10 @@ async function finishCollect() {
// 重置游戏状态的函数
function resetGame() {
+ console.log(1);
+
+ emit('restart');
+
return
// 重置所有响应式状态到初始值
gPos.value = 'center';
@@ -715,7 +762,7 @@ function resetGame() {

-
-
+

@@ -778,7 +825,7 @@ function resetGame() {
+ style="z-index: 2; inset: 0; height: 100%; width: 100%;pointer-events: none;">
![]()
+ style="bottom: 8%;left: 33%;width: 34vw;animation: scale-in 0.3s ease-out;pointer-events: all;">
@@ -857,10 +904,10 @@ function resetGame() {
style="width: 66vw;bottom: -19%;left: 17%;">

+ style="width: 34vw;bottom: -19%;left: 15%;animation: last-btn-in 0.3s ease-out forwards; cursor: pointer; pointer-events: all;">

+ style="width: 34vw;bottom: -19%;left: 51%;animation: last-btn-in 0.3s ease-out forwards; cursor: pointer; animation-delay: 200ms; pointer-events: all;">
@@ -874,7 +921,7 @@ function resetGame() {
+ style="font-size: 10vw;animation: line-in 0.5s ease-out 0.8s forwards;transform: translateX(-210%);">
{{ fmtTime(timeSpent / 1000) }}
@@ -882,9 +929,9 @@ function resetGame() {
style="left: 10%; top:30%;width: 24%;height: 10%;gap:2vw; display: flex;animation: line-in 0.5s ease-out 0.4s forwards;transform: translateX(-210%);
align-items: center; flex-direction: column;justify-content: center;">
+ style="width: 20vw; background-color: white;font-size: 3vw;text-align: center;height: 5.2vw;line-height: 5.2vw; border-radius: 4.5vw;">
{{ userdata.region }}
-
{{
+
{{
userdata.store }}
@@ -1068,24 +1115,26 @@ function resetGame() {
.rank {
// italic
font-style: italic;
- flex-grow: 1;
+ flex: 1;
font-size: 4vw;
text-align: center;
color: #7EA0CA;
}
.name {
- flex-grow: 2;
+ flex: 2;
text-align: center;
+ border-right: .35vw solid black;
}
.time {
- flex-grow: 2;
+ flex: 2;
text-align: center;
+ border-right: .35vw solid black;
}
.region {
- flex-grow: 2;
+ flex: 2;
color: gray;
text-align: center;
}
diff --git a/src/pages/Page1.vue b/src/pages/Page1.vue
index cff506b..d6b7dba 100644
--- a/src/pages/Page1.vue
+++ b/src/pages/Page1.vue
@@ -110,6 +110,14 @@ async function startExploration() {
noticeToInputName.value = true;
return;
}
+
+ emit('startExploration', {
+ region: selectedRegion.value,
+ store: selectedStores.value[selectedStoreIndex.value].店铺,
+ username: nameInput.value
+ });
+
+ await new Promise(resolve => setTimeout(resolve, 400)); // 等待动画结束
startExplorationRules.value[0].reverse = true;
// 2. 将放大的气泡恢复原状
@@ -121,11 +129,7 @@ async function startExploration() {
document.querySelector('.sun-wrap')?.classList.add('fade-out');
- emit('startExploration', {
- region: selectedRegion.value,
- store: selectedStores.value[selectedStoreIndex.value].店铺,
- username: nameInput.value
- });
+
}
@@ -593,7 +597,7 @@ img {
.input-container {
position: relative;
- width: 80%;
+ width: 55%;
margin: 0 auto;
}
diff --git a/todo.md b/todo.md
index d17705d..44df1ff 100644
--- a/todo.md
+++ b/todo.md
@@ -17,7 +17,7 @@
游戏结算:
1. 动画卡轴不正确,小太阳收脚的那一下应该是落在蹦床上的时间点,收脚是落地缓冲,现在节奏点不对; @solved
-2. 在没有点击收集完成的时候,小太阳应该是在排行榜上来回跳,循环,现在是一个循环后直接跳回下部;
+2. 在没有点击收集完成的时候,小太阳应该是在排行榜上来回跳,循环,现在是一个循环后直接跳回下部; @solved
164 左上
230
@@ -28,4 +28,4 @@
33: 263 - end
-1. 排行榜后台是不是还没完成?
\ No newline at end of file
+1. 排行榜后台是不是还没完成? @solved
\ No newline at end of file