瀏覽代碼

日常开发

林旭祥 3 周之前
父節點
當前提交
8e3fbdf4b9
共有 1 個文件被更改,包括 18 次插入9 次删除
  1. 18 9
      src/views/game/index.vue

+ 18 - 9
src/views/game/index.vue

@@ -195,9 +195,9 @@ const getInit = async () => {
       if (!currentGame.value) {
         return false;
       }
+      //传给预备窗口
+      actionConfirmRef.value.getInit(e);
       if (!start.value) {
-        //传给预备窗口
-        actionConfirmRef.value.getInit(e);
         return false;
       }
       let area = e.ctrl_name.replace('bodyposecontroller_', '');
@@ -279,9 +279,9 @@ const getExitGame = (data: any) => {
     })
     currentGame.value = "";
     start.value = false;
+    resumeGame.value = false;
   } else if (data.type == 2) {
     //游戏结束显示下一场
-
     let myIndex = areaStateList.value.findIndex((item: any) => {
       return item.area == data.area;
     })
@@ -294,6 +294,7 @@ const getExitGame = (data: any) => {
       })
       currentGame.value = "";
       start.value = false;
+      resumeGame.value = false;
     }).finally(() => {
     });
   }
@@ -304,8 +305,11 @@ const getExitGame = (data: any) => {
  */
 const getStartGame = (data: any) => {
   areaStateList.value = data;
-  start.value = true;
+  start.value = false;
   resumeGame.value = false;
+  setTimeout(()=>{
+    start.value = true;
+  })
 };
 
 /**
@@ -313,7 +317,7 @@ const getStartGame = (data: any) => {
  */
 const getResumeGame = () => {
   resumeGame.value = false;
-  start.value = false;
+  // start.value = false;
   actionConfirmRef.value.getOpen(currentGame.value, currentGameArea.value);
 };
 
@@ -519,21 +523,26 @@ $waiPadding: 6.51rem;
   margin-left: -1.6rem;
 }
 
-.resumeGame{
+.resumeGame {
   width: 10rem;
   height: 3.2rem;
   line-height: 3.2rem;
   font-size: 1.8rem;
-  color: #000000;
+  color: #1a293a;
   text-align: center;
-  background-color: rgba(216, 216, 216, 0.8);
   z-index: 991;
   position: fixed;
-  bottom: calc(35px + 3.2rem + 25px) ;
+  bottom: calc(35px + 3.2rem + 25px);
   left: 50%;
   margin-left: -5rem;
   cursor: pointer;
   border-radius: 8px;
+  background: radial-gradient(159% 126% at 5% 93%, #8effa9 0%, #07ffe7 100%);
+  box-shadow: 1px 1px 1px 1px rgba(0, 0, 0, 0.1874), inset 0px 1px 0px 1px rgba(255, 255, 255, 0.3);
+
+  &:hover {
+    background: #8effa9;
+  }
 }
 
 ::v-deep(.menu) {