修复泰伦母舰变形无动画bug:phase在变形开始即+1,op2/op3改为mp优先驱动(甲壳滑开/触手伸出/眼渐显/嘴展开全部连续渐变)

This commit is contained in:
JOJO 2026-08-06 01:31:47 +08:00
parent 7629cdf877
commit 3b4e9d35a0

View File

@ -140,10 +140,10 @@ function drawBoss(){
circ(0,0,4.5,"#0a2418");circ(0,0,3,fl||"#5cff9d");circ(0,0,1.3,"#d6ffe8"); // 亚空间核心 circ(0,0,4.5,"#0a2418");circ(0,0,3,fl||"#5cff9d");circ(0,0,1.3,"#d6ffe8"); // 亚空间核心
ctx.restore(); ctx.restore();
}else if(b.idx===9){ // 泰伦母舰锥形生物舰头下尾上P2头背甲壳裂开露眼+伸出触手P3触手间展开环齿嘴 }else if(b.idx===9){ // 泰伦母舰锥形生物舰头下尾上P2头背甲壳裂开露眼+伸出触手P3触手间展开环齿嘴
let op2,op3; let op2,op3; // 变形期 mp=0→1 连续驱动phase在变形开始即+1故mp优先于ph2
if(ph2===0){op2=mp!==null?mp:0;op3=0;} if(ph2===0){op2=0;op3=0;} // P1甲壳闭合
else if(ph2===1){op2=1;op3=mp!==null?mp:0;} else if(ph2===1){op2=mp!==null?mp:1;op3=0;} // P1→P2变形甲壳滑开+触手伸出+眼渐显
else{op2=1;op3=1;} else{op2=1;op3=mp!==null?mp:1;} // P2→P3变形甲壳翻开+嘴展开+触手加粗
ctx.save();ctx.scale(1,1+Math.sin(t*0.05)*0.015); // 呼吸起伏 ctx.save();ctx.scale(1,1+Math.sin(t*0.05)*0.015); // 呼吸起伏
for(const sd of[-1,0,1]){const sw=Math.sin(t*0.055+sd*1.8)*3; // 尾须缓摆 for(const sd of[-1,0,1]){const sw=Math.sin(t*0.055+sd*1.8)*3; // 尾须缓摆
poly([sd*8-2.5,-36,sd*8+2.5,-36,sd*11+sw,-52,sd*9+sw-1.5,-52],"#3d2f4a"); poly([sd*8-2.5,-36,sd*8+2.5,-36,sd*11+sw,-52,sd*9+sw-1.5,-52],"#3d2f4a");