From d85f3432f8d7800874273d1a52d47f65921d15b2 Mon Sep 17 00:00:00 2001 From: Takkkom <76614532+Takkkom@users.noreply.github.com> Date: Thu, 16 Nov 2023 19:04:57 +0900 Subject: [PATCH] =?UTF-8?q?=E8=B8=8A=E3=82=8A=E5=AD=90=E3=81=A8Mob?= =?UTF-8?q?=E3=82=92=E5=BC=B7=E5=8C=96=20(#526)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 踊り子とMobを強化 * バグ修正 --- .../Graphics/5_Game/3_Mob/0/Mob.png | Bin 0 -> 9354 bytes .../Graphics/5_Game/3_Mob/0/Script.lua | 96 +++++++++ .../Graphics/5_Game/3_Mob/0/Mob.png | Bin 0 -> 9354 bytes .../Graphics/5_Game/3_Mob/0/Script.lua | 96 +++++++++ .../Graphics/5_Game/7_Gauge/Clear.png | Bin 0 -> 6531 bytes .../Graphics/5_Game/7_Gauge/Clear_2PGauge.png | Bin 0 -> 6544 bytes .../Graphics/5_Game/7_Gauge/Clear_4PGauge.png | Bin 0 -> 609 bytes .../src/Stages/07.Game/CStage演奏画面共通.cs | 5 + .../07.Game/Taiko/CAct演奏DrumsDancer.cs | 190 ++++++++++++++++-- .../Stages/07.Game/Taiko/CAct演奏DrumsMob.cs | 23 ++- .../src/Stages/07.Game/Taiko/ScriptBG.cs | 18 ++ 11 files changed, 400 insertions(+), 28 deletions(-) create mode 100644 OpenTaiko/System/SimpleStyle (1080p)/Graphics/5_Game/3_Mob/0/Mob.png create mode 100644 OpenTaiko/System/SimpleStyle (1080p)/Graphics/5_Game/3_Mob/0/Script.lua create mode 100644 OpenTaiko/System/SimpleStyle/Graphics/5_Game/3_Mob/0/Mob.png create mode 100644 OpenTaiko/System/SimpleStyle/Graphics/5_Game/3_Mob/0/Script.lua create mode 100644 OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear.png create mode 100644 OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear_2PGauge.png create mode 100644 OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear_4PGauge.png diff --git a/OpenTaiko/System/SimpleStyle (1080p)/Graphics/5_Game/3_Mob/0/Mob.png b/OpenTaiko/System/SimpleStyle (1080p)/Graphics/5_Game/3_Mob/0/Mob.png new file mode 100644 index 0000000000000000000000000000000000000000..642757e7b9ce87bb5c539b732a1fa1b97b7d791b GIT binary patch literal 9354 zcmeHL4QvzV8NMWxq)q}UVWn!5aW!pH0_Xd;eYZG}*$H+RhcuWFmbCEQpK~MjIrcer zQksOHZVV_RWos*jq9$qA4LYi=Wvpd%r3E_5erU%)rJG=|AE9lKN*h5!lznF>!O<#B z(V&{Dvt;@1{oeQa-skz=_xpVJ&4&6Vg_e6Q2!a&)yq-n`$?Zds?B=}b(6V9l+C2Dk zv^&tOH-ZEjiE4`4E~9!^L`LPLsvt=6OsJt{#ydpbwcpI|+}L;QZ_bNn9zJkr+oD;U zPBy(d+udZj2kocw)sn??QLr)wIA2bX^Dp&jLcipLKA&b_-oc=W65 zYp-r-?{E6U+?TzNzN(YEwK+dIaN@A_^f&r%3DqO zKQ<)-Ujjv&pW0tHaJEr@{P7R0&&@0vqR>;w(dxx3)|CYhdc8YeI<}F0+V-cj19!hY zGiT09{K{1wQp|c%b-NpUZudAN$Ya+N{Vwl2i%X8IYS}l0Svre4e$h~R*j91Ad3W=) z{1<l>`un)~kc zWa4ti=!_A2MIHIZP~Xtb?usuK|M>Oghi+`{DHzHv&fEOU6SFQJDQJE7w5xLM!7U>T zM`OL)p5NuT=iFVJhU!K6>j&yk*CgzT>5>gVy(1Su+3VTm>S>v&NM*?^=8vMm{kz}iEQ%0%i8R3K;2qYMj0DpBe0sJ+DTcfENEp^Quszs?HB~Sb6MMTJ;LL7B9X8qXqy%d z;v~m$I6>hQg+UK2))m%45(~%X84zgygh z?I}8vh|BGA2)f4LtmLFAm-ze*6A^|4K{XUfMM1GAdFrZiQ>;n386zn=nTf#g3EWBE zA=vFbPxndIvgZzcRD#|MtqYT zjlo(pP)Wi@GpTT6VR%RfN(+oig#al#WW&3oGSIbXK-1b?RwF6Yh@2Sq!-kT84m?1Y zAt*u7JW2ATJwUQN%km_>fZ%u{!(WqBrR%?W8|{NurWf6-#^C&2DO0+qmdPFIyYy|l znrbE#O|=CN#59E%=#-^Yo)9ZNB({NYP=@=*Siz3l)lVq~jt~Tq6iJL_U{Nsut|h0i z5+;!%!EjEFWbNE!^q8jT2@sX5gHT7P6)ez{R_H@xOErJ8f1*t`)&WX}5q6AX0wl!~ z6wi=W{Pxqc(~{_r?667f1c5PxLSjzAPQd~NK%y0ra7gKPnGo-Pp~t~K2v7u1GCb?} zEa(9{CDQ_>V3eqE7z4W(1Cm|A6iS4|MPRoxVDf6*5_(RavVRuz96+QLh9)r@Rw3N% zNDAWw0q#^zf?+w)$ubgq%jl6LmeJ4S^eS=VI2&)pO8h^XHSLgb{=uS7+u*qhk7<13 zoF1!oSZTNOGqy?G&M8pToMcM+nsS+PO-X?%Ih)mG$~7egrsQl^*DaIFa`Q=F4#U6a z3HTh34z~RWz5|#pd}WCTxf3ZyJl|bky%$>UjCfbZ5G23Y_+}wHcijVxxw_9^ll#~F zqUnx8OK=H}Aa{Mo=cx`P&;0#RRu**V+y2Qbm-394UFOGBz*N9gz*N9gz*N9gz*N9g zz*N9gz*N9gz*OLKtw7&L8**kD46ARf8l4yTTyy=uBv+N)6h*Si_AKu)((~2Sd-i^L H_4 2 then + -- if mob_state == 0 then + -- mobIn() + -- else + -- mobOut() + -- end + -- debug_counter = 0 + --end + + mob_counter = mob_counter + (bpm[0] * deltaTime / 60.0) + if mob_counter > 1 then + mob_counter = 0 + end + + mob_y = 1080 + ((1.0 - math.sin(mob_counter * math.pi)) * 105) + + + + if mob_state == 3 and gauge[0] == 100 then + mobOut() + end + + if mob_state == 0 then + + if gauge[0] == 100 then + mobIn() + end + + elseif mob_state == 1 then + + mob_in_counter = mob_in_counter + (5 * deltaTime) + if mob_in_counter > 1 then + mob_state = 3 + end + + mob_y = mob_y + (540 * (1.0 - math.sin(mob_in_counter * math.pi / 2))) + + + + elseif mob_state == 2 then + + mob_out_counter = mob_out_counter + (5 * deltaTime) + if mob_out_counter > 1 then + mob_state = 0 + end + + mob_y = mob_y + (540 * (1 - math.cos(mob_out_counter * math.pi))) + + elseif mob_state == 3 then + end +end + +function draw() + if mob_state == 0 then + else + func:DrawGraph(mob_x, mob_y - mob_height, "Mob.png") + end +end diff --git a/OpenTaiko/System/SimpleStyle/Graphics/5_Game/3_Mob/0/Mob.png b/OpenTaiko/System/SimpleStyle/Graphics/5_Game/3_Mob/0/Mob.png new file mode 100644 index 0000000000000000000000000000000000000000..642757e7b9ce87bb5c539b732a1fa1b97b7d791b GIT binary patch literal 9354 zcmeHL4QvzV8NMWxq)q}UVWn!5aW!pH0_Xd;eYZG}*$H+RhcuWFmbCEQpK~MjIrcer zQksOHZVV_RWos*jq9$qA4LYi=Wvpd%r3E_5erU%)rJG=|AE9lKN*h5!lznF>!O<#B z(V&{Dvt;@1{oeQa-skz=_xpVJ&4&6Vg_e6Q2!a&)yq-n`$?Zds?B=}b(6V9l+C2Dk zv^&tOH-ZEjiE4`4E~9!^L`LPLsvt=6OsJt{#ydpbwcpI|+}L;QZ_bNn9zJkr+oD;U zPBy(d+udZj2kocw)sn??QLr)wIA2bX^Dp&jLcipLKA&b_-oc=W65 zYp-r-?{E6U+?TzNzN(YEwK+dIaN@A_^f&r%3DqO zKQ<)-Ujjv&pW0tHaJEr@{P7R0&&@0vqR>;w(dxx3)|CYhdc8YeI<}F0+V-cj19!hY zGiT09{K{1wQp|c%b-NpUZudAN$Ya+N{Vwl2i%X8IYS}l0Svre4e$h~R*j91Ad3W=) z{1<l>`un)~kc zWa4ti=!_A2MIHIZP~Xtb?usuK|M>Oghi+`{DHzHv&fEOU6SFQJDQJE7w5xLM!7U>T zM`OL)p5NuT=iFVJhU!K6>j&yk*CgzT>5>gVy(1Su+3VTm>S>v&NM*?^=8vMm{kz}iEQ%0%i8R3K;2qYMj0DpBe0sJ+DTcfENEp^Quszs?HB~Sb6MMTJ;LL7B9X8qXqy%d z;v~m$I6>hQg+UK2))m%45(~%X84zgygh z?I}8vh|BGA2)f4LtmLFAm-ze*6A^|4K{XUfMM1GAdFrZiQ>;n386zn=nTf#g3EWBE zA=vFbPxndIvgZzcRD#|MtqYT zjlo(pP)Wi@GpTT6VR%RfN(+oig#al#WW&3oGSIbXK-1b?RwF6Yh@2Sq!-kT84m?1Y zAt*u7JW2ATJwUQN%km_>fZ%u{!(WqBrR%?W8|{NurWf6-#^C&2DO0+qmdPFIyYy|l znrbE#O|=CN#59E%=#-^Yo)9ZNB({NYP=@=*Siz3l)lVq~jt~Tq6iJL_U{Nsut|h0i z5+;!%!EjEFWbNE!^q8jT2@sX5gHT7P6)ez{R_H@xOErJ8f1*t`)&WX}5q6AX0wl!~ z6wi=W{Pxqc(~{_r?667f1c5PxLSjzAPQd~NK%y0ra7gKPnGo-Pp~t~K2v7u1GCb?} zEa(9{CDQ_>V3eqE7z4W(1Cm|A6iS4|MPRoxVDf6*5_(RavVRuz96+QLh9)r@Rw3N% zNDAWw0q#^zf?+w)$ubgq%jl6LmeJ4S^eS=VI2&)pO8h^XHSLgb{=uS7+u*qhk7<13 zoF1!oSZTNOGqy?G&M8pToMcM+nsS+PO-X?%Ih)mG$~7egrsQl^*DaIFa`Q=F4#U6a z3HTh34z~RWz5|#pd}WCTxf3ZyJl|bky%$>UjCfbZ5G23Y_+}wHcijVxxw_9^ll#~F zqUnx8OK=H}Aa{Mo=cx`P&;0#RRu**V+y2Qbm-394UFOGBz*N9gz*N9gz*N9gz*N9g zz*N9gz*N9gz*OLKtw7&L8**kD46ARf8l4yTTyy=uBv+N)6h*Si_AKu)((~2Sd-i^L H_4 2 then + -- if mob_state == 0 then + -- mobIn() + -- else + -- mobOut() + -- end + -- debug_counter = 0 + --end + + mob_counter = mob_counter + (bpm[0] * deltaTime / 60.0) + if mob_counter > 1 then + mob_counter = 0 + end + + mob_y = 720 + ((1.0 - math.sin(mob_counter * math.pi)) * 70) + + + + if mob_state == 3 and gauge[0] == 100 then + mobOut() + end + + if mob_state == 0 then + + if gauge[0] == 100 then + mobIn() + end + + elseif mob_state == 1 then + + mob_in_counter = mob_in_counter + (5 * deltaTime) + if mob_in_counter > 1 then + mob_state = 3 + end + + mob_y = mob_y + (360 * (1.0 - math.sin(mob_in_counter * math.pi / 2))) + + + + elseif mob_state == 2 then + + mob_out_counter = mob_out_counter + (5 * deltaTime) + if mob_out_counter > 1 then + mob_state = 0 + end + + mob_y = mob_y + (360 * (1 - math.cos(mob_out_counter * math.pi))) + + elseif mob_state == 3 then + end +end + +function draw() + if mob_state == 0 then + else + func:DrawGraph(mob_x, mob_y - mob_height, "Mob.png") + end +end diff --git a/OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear.png b/OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear.png new file mode 100644 index 0000000000000000000000000000000000000000..040eee3dc30ea93aab9fc623ae7613061784ab1e GIT binary patch literal 6531 zcmeHMeRLGn6(15lLc&)yG#s@sEZ_k>vpX|8o6L^cd~QgBEUqC4K|tQlyh*0n-C1TQ z*-exW6SNX2;Ul00gaZO<4ft~NSg=sFMhexwnf=NVl;nWz zKgl_}JM->+zkBcR-Fx4g$s*^Z!hy*TC1V&iu(-%xf?)~!(X~CPFZ$-&E)GXOAJ&#m zQ%gVq_bIX{xgoCB_#h60l89l!GahH|pu~|$`)@X6_4-BW3ro*_`sjahH$0a*@$Xw# zlKADMg;&0s_tMdvhDX?`g8$3rVp(+XR5pF4Ndb*kk^+0=ehbBEl*=2XooQI|jP{i~_d4+njJZ49&z z4_w3KH$F&x9~^J zeredUulgotCd_G)_7(5X&1{x_xvqUt{kG8`AHH;WB{y@~x67}rI3%xIoc?@`=sdpp z;-dP)dAsVj3=+r89JzkvppP0R-1uzUA^H;WhY4FgoZjAM8qjuX6?0lzI%?^d(aRQM z{Vh#TzqlxA`(x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>mL*QA8Bv@;PNVrI}*jB3r5LOmK$OD!nfhC^P|Nmm&W5^cK zWlk4GNI=TW6N~@^bpC)M!B}a5VXYJ+3h+lmE=0#JeG|G{5z}UZLc3aQFN&np?cKL? zj}5n7d#HVmN3BucT=XLjhpwc4NZFT9KYlqPVz$4IyM?V+oOu5K~VE#;o<>Y=M!40KDm zC%f(&UCFWcrqGKX-~#BaXyt~&Bj}B4U)Pg`cIDt6P?ETcF6SbtwpnIFSa9@IX) zur=$3p}~G?v7?~hrIf)KIbvVM+Oz1jd2X>iw={U>i`I<;F?>Kl%j%tjZ#K5rkDTAR zd9T0qomn4YSjDF5rlH4%)*Sd%F^27Wvb-)08`7LK3tcZh*Qe8E&eb|Jde~TZx;M6< zwcvUJ_R7rOrp}kHG&G7={|xJMw1N{TFP) BnK=Le literal 0 HcmV?d00001 diff --git a/OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear_2PGauge.png b/OpenTaiko/System/SimpleStyle/Graphics/5_Game/7_Gauge/Clear_2PGauge.png new file mode 100644 index 0000000000000000000000000000000000000000..93587516211ab904d26f3d0e2b3399e0341c3eff GIT binary patch literal 6544 zcmeHMYj6|S6<+f&#x}$goWRf))`Boen3eV=S-V((v5akEfoep+fJs)nckPWOtyrxs znesO66et)QLJ~rlm{*dHLvb4#2rx0R327TbphH6-WSHW?w2&cf2&M@WdUy4*zzy~Q z{bkKaTHSNbch33lx#!+pt#(c?7?L_N6+w_8MTPbf1nGAOUfWZW;V0jIX%zfAy2v$0 zE#ZQwUy()015mZb4^R-2L<9+)^*ZMb?Vpu$t25KqkG#pQKX-oI;oQ3CGK>GYdn1ls zPFZ#3o29=zh7=5Ln06d1FDcykVOj08Url5hinm#}wQW29@7%W0&AVS8Ro(RY;`uep z_Ab6Ua@Xj_@2-E)JbcTtmT$+kkLFZ*(S))$4`iH4Jvs2bb@>NQ|9)Nd$@MQhp4@om zi)Y%GZr*-w!p3n&7H6&8l+>Jzrze%AEmTgeUA4QpSZ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Eait%&|+5kpNsGHbXX!$BlGpX&0%*stdI_W^J;Pc&fDFSw0CS9tP7zbK)|X6{-0&5!z=Qwe&|--~_OF3gA>=hi{0D6IKi- zFv8-(tt@R}X=<*H6;qTImn?g11}zy>%ONIqz_urFDi=i}DV88u!tBBsmS$KI9}h1g zp=ofiY$dVgUfNodLv!MV>jELQn5%&->XL8+oCy|&e}#W~B)#*YXxvOUna+7(j(Hxy zDSFfp`3?;YJ*r{qB_w)r#h!~R|8TK()5Y3DJ;%>6X)QaNK~B6Cvv;JL14(l@*g`3w z%1TWSvez3i%kklg5`ZFAgYYtfiHC)LPJx`LkWHI`mwnYhQGtMpitI&W>kCz7l=J&N z60g^$soEz*c8(Z%hVHpa3?RVW<({wLeB}V{wUM3~4NK~#-SoIe#F7ihq8j8BkXsJd zmCcZ=?fa-Rx)GxAc&3#*`ebAwKNX#`aM-~L0M}u7L6|X|a^W!v7;fP#7$E6vjB`^WW?@L0q5*|l7%`F42VLL2pX~cg znde2)YBdWOtZ^Kpt!{XN;4C6WxCI7elWsR>{_&Ix;IT{JgzmM7NeUz2t`^^mq9t`_ z_r1HvM%u1D+&-tm)~IhT`Vp0d$Ew&t3!3)sFavuqJh!slHM^d#{4j=mzlSTmn}x~f zayJ1tneZ6AOMy2%rr2FiWNUgi@BIg5_`n|->@O@0AV}IU z?VW^d**XFa4pNI8`GY#r9zlpqx-sx5d~80W$e!y8o&D-e^N6e<{lWU=~jKhhSldrFYqjnPb-`rIsj|=o#u6_p1C&XJBBw z@9E+gQW5v|+QCj110I%xXYF@)XZZVP&tx%~vd|#wLj3&q-?928F*tNf zFfuG~?O|ZJpybBDkRhndz_6tQXl>LH4h9BY3YBdbP0l+XkKw)4Gi literal 0 HcmV?d00001 diff --git a/OpenTaiko/src/Stages/07.Game/CStage演奏画面共通.cs b/OpenTaiko/src/Stages/07.Game/CStage演奏画面共通.cs index 4d0d1160..9beb7944 100644 --- a/OpenTaiko/src/Stages/07.Game/CStage演奏画面共通.cs +++ b/OpenTaiko/src/Stages/07.Game/CStage演奏画面共通.cs @@ -5321,6 +5321,11 @@ namespace TJAPlayer3 this.actPanel.t歌詞テクスチャを削除する(); for (int i = 0; i < 5; i++) { + if (bIsAlreadyCleared[i]) + { + TJAPlayer3.stage演奏ドラム画面.actBackground.ClearOut(i); + } + this.t演奏位置の変更(0, i); this.actPlayInfo.NowMeasure[i] = 0; JPOSCROLLX[i] = 0; diff --git a/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsDancer.cs b/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsDancer.cs index d8d53bc4..79b088b6 100644 --- a/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsDancer.cs +++ b/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsDancer.cs @@ -28,7 +28,15 @@ namespace TJAPlayer3 var preset = HScenePreset.GetBGPreset(); Random random = new Random(); + + Dancer_In = new CTexture[5][]; + Dancer_Out = new CTexture[5][]; Dancer = new CTexture[5][]; + DancerStates = new int[5]; + nNowDancerInCounter = new float[5]; + nNowDancerOutCounter = new float[5]; + + var dancerOrigindir = CSkin.Path($"{TextureLoader.BASE}{TextureLoader.GAME}{TextureLoader.DANCER}"); if (System.IO.Directory.Exists($@"{dancerOrigindir}")) @@ -43,10 +51,43 @@ namespace TJAPlayer3 LoadDancerConifg(path); + Dancer_In = new CTexture[nDancerCount][]; + Dancer_Out = new CTexture[nDancerCount][]; + Dancer = new CTexture[nDancerCount][]; + DancerStates = new int[nDancerCount]; + nNowDancerInCounter = new float[nDancerCount]; + nNowDancerOutCounter = new float[nDancerCount]; + + nDancerInPtn = TJAPlayer3.t連番画像の枚数を数える($@"{path}{Path.DirectorySeparatorChar}1_In{Path.DirectorySeparatorChar}"); + if (nDancerInPtn != 0) + { + for (int i = 0; i < nDancerCount; i++) + { + Dancer_In[i] = new CTexture[nDancerInPtn]; + for (int p = 0; p < nDancerInPtn; p++) + { + Dancer_In[i][p] = TJAPlayer3.tテクスチャの生成($@"{path}{Path.DirectorySeparatorChar}{(i + 1)}_In{Path.DirectorySeparatorChar}{p}.png"); + } + } + } + + nDancerOutPtn = TJAPlayer3.t連番画像の枚数を数える($@"{path}{Path.DirectorySeparatorChar}1_Out{Path.DirectorySeparatorChar}"); + if (nDancerOutPtn != 0) + { + for (int i = 0; i < nDancerCount; i++) + { + Dancer_Out[i] = new CTexture[nDancerOutPtn]; + for (int p = 0; p < nDancerOutPtn; p++) + { + Dancer_Out[i][p] = TJAPlayer3.tテクスチャの生成($@"{path}{Path.DirectorySeparatorChar}{(i + 1)}_Out{Path.DirectorySeparatorChar}{p}.png"); + } + } + } + nDancerPtn = TJAPlayer3.t連番画像の枚数を数える($@"{path}{Path.DirectorySeparatorChar}1{Path.DirectorySeparatorChar}"); if (nDancerPtn != 0) { - for (int i = 0; i < 5; i++) + for (int i = 0; i < nDancerCount; i++) { Dancer[i] = new CTexture[nDancerPtn]; for (int p = 0; p < nDancerPtn; p++) @@ -58,6 +99,12 @@ namespace TJAPlayer3 } } + arMotionArray_In = CConversion.StringToIntArray(Game_Dancer_In_Motion); + if(this.arMotionArray_In == null) arMotionArray_In = CConversion.StringToIntArray("0,0"); + + arMotionArray_Out = CConversion.StringToIntArray(Game_Dancer_Out_Motion); + if(this.arMotionArray_Out == null) arMotionArray_Out = CConversion.StringToIntArray("0,0"); + this.ar踊り子モーション番号 = CConversion.StringToIntArray(TJAPlayer3.Skin.Game_Dancer_Motion); if(this.ar踊り子モーション番号 == null) ar踊り子モーション番号 = CConversion.StringToIntArray("0,0"); @@ -74,8 +121,10 @@ namespace TJAPlayer3 //this.ct踊り子モーション = null; - for (int i = 0; i < 5; i++) + for (int i = 0; i < nDancerCount; i++) { + TJAPlayer3.t安全にDisposeする(ref Dancer_In[i]); + TJAPlayer3.t安全にDisposeする(ref Dancer_Out[i]); TJAPlayer3.t安全にDisposeする(ref Dancer[i]); } @@ -103,22 +152,91 @@ namespace TJAPlayer3 { if (TJAPlayer3.ConfigIni.ShowDancer && (this.ar踊り子モーション番号.Length - 1) != 0) { - if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) nNowDancerCounter += (Math.Abs((float)TJAPlayer3.stage演奏ドラム画面.actPlayInfo.dbBPM[0] / 60.0f) * (float)TJAPlayer3.FPS.DeltaTime) * (this.ar踊り子モーション番号.Length - 1) / nDancerBeat; - nNowDancerFrame = (int)nNowDancerCounter; - nNowDancerFrame = Math.Min(nNowDancerFrame, (this.ar踊り子モーション番号.Length - 1)); - bool endAnime = nNowDancerFrame >= (this.ar踊り子モーション番号.Length - 1) - 1; - - if (endAnime) + if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) nNowDancerCounter += Math.Abs((float)TJAPlayer3.stage演奏ドラム画面.actPlayInfo.dbBPM[0] / 60.0f) * (float)TJAPlayer3.FPS.DeltaTime / nDancerBeat; + if (nNowDancerCounter >= 1) { nNowDancerCounter = 0; - nNowDancerFrame = 0; } - for (int i = 0; i < 5; i++) + nNowDancerFrame = (int)(nNowDancerCounter * (this.ar踊り子モーション番号.Length - 1)); + + for (int i = 0; i < nDancerCount; i++) { - if (this.Dancer[i] != null && this.Dancer[i][this.ar踊り子モーション番号[nNowDancerFrame]] != null) + if ((int)TJAPlayer3.stage演奏ドラム画面.actGauge.db現在のゲージ値[0] >= TJAPlayer3.Skin.Game_Dancer_Gauge[i]) { - if ((int)TJAPlayer3.stage演奏ドラム画面.actGauge.db現在のゲージ値[0] >= TJAPlayer3.Skin.Game_Dancer_Gauge[i]) + if (DancerStates[i] == 0) + { + DancerStates[i] = 1; + nNowDancerInCounter[i] = 0; + } + } + else + { + if (DancerStates[i] == 3) + { + DancerStates[i] = 2; + nNowDancerOutCounter[i] = 0; + } + } + + switch(DancerStates[i]) + { + case 0: + break; + case 1: + { + if (nDancerInInterval == 0) + { + DancerStates[i] = 3; + } + else + { + if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) nNowDancerInCounter[i] += Math.Abs((float)TJAPlayer3.stage演奏ドラム画面.actPlayInfo.dbBPM[0] / nDancerInInterval) * (float)TJAPlayer3.FPS.DeltaTime; + + if (nNowDancerInCounter[i] >= 1) + { + nNowDancerInCounter[i] = 1; + DancerStates[i] = 3; + } + + int frame = (int)(nNowDancerInCounter[i] * (this.arMotionArray_In.Length - 1)); + if (this.Dancer_In[i] != null && this.Dancer_In[i].Length > 0 && this.Dancer_In[i][this.arMotionArray_In[frame]] != null) + { + this.Dancer_In[i][this.arMotionArray_In[frame]].t2D中心基準描画(TJAPlayer3.Skin.Game_Dancer_X[i], TJAPlayer3.Skin.Game_Dancer_Y[i]); + } + } + + } + break; + case 2: + { + if (nDancerOutInterval == 0) + { + DancerStates[i] = 0; + } + else + { + if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) nNowDancerOutCounter[i] += Math.Abs((float)TJAPlayer3.stage演奏ドラム画面.actPlayInfo.dbBPM[0] / nDancerOutInterval) * (float)TJAPlayer3.FPS.DeltaTime; + + if (nNowDancerOutCounter[i] >= 1) + { + nNowDancerOutCounter[i] = 1; + DancerStates[i] = 0; + } + + int frame = (int)(nNowDancerOutCounter[i] * (this.arMotionArray_Out.Length - 1)); + if (this.Dancer_Out[i] != null && this.Dancer_Out[i].Length > 0 && this.Dancer_Out[i][this.arMotionArray_Out[frame]] != null) + { + this.Dancer_Out[i][this.arMotionArray_Out[frame]].t2D中心基準描画(TJAPlayer3.Skin.Game_Dancer_X[i], TJAPlayer3.Skin.Game_Dancer_Y[i]); + } + } + } + break; + case 3: + if (this.Dancer[i] != null && this.Dancer[i].Length > 0 && this.Dancer[i][this.ar踊り子モーション番号[nNowDancerFrame]] != null) + { this.Dancer[i][this.ar踊り子モーション番号[nNowDancerFrame]].t2D中心基準描画(TJAPlayer3.Skin.Game_Dancer_X[i], TJAPlayer3.Skin.Game_Dancer_Y[i]); + } + break; } } } @@ -129,13 +247,27 @@ namespace TJAPlayer3 #region[ private ] //----------------- + private int nDancerCount; + private float[] nNowDancerInCounter; + private float[] nNowDancerOutCounter; private float nNowDancerCounter; private int nNowDancerFrame; + private int nDancerInPtn; + private int nDancerOutPtn; private int nDancerPtn; private float nDancerBeat; + private float nDancerInInterval; + private float nDancerOutInterval; + private int[] arMotionArray_In; + private int[] arMotionArray_Out; private int[] ar踊り子モーション番号; //public CCounter ct踊り子モーション; + private CTexture[][] Dancer_In; + private CTexture[][] Dancer_Out; private CTexture[][] Dancer; + private int[] DancerStates; + private string Game_Dancer_In_Motion; + private string Game_Dancer_Out_Motion; private void LoadDancerConifg(string dancerPath) { @@ -147,6 +279,9 @@ namespace TJAPlayer3 TJAPlayer3.Skin.Game_Dancer_X = new int[] { 640, 430, 856, 215, 1070 }; TJAPlayer3.Skin.Game_Dancer_Y = new int[] { 500, 500, 500, 500, 500 }; + nDancerCount = 5; + nDancerInInterval = 0; + nDancerOutInterval = 0; foreach (string s in strSingleLine) { @@ -164,10 +299,16 @@ namespace TJAPlayer3 strCommand = strArray[0].Trim(); strParam = strArray[1].Trim(); - if (strCommand == "Game_Dancer_X") + if (strCommand == "Game_Dancer_Count") + { + nDancerCount = int.Parse(strParam); + TJAPlayer3.Skin.Game_Dancer_X = new int[nDancerCount]; + TJAPlayer3.Skin.Game_Dancer_Y = new int[nDancerCount]; + } + else if (strCommand == "Game_Dancer_X") { string[] strSplit = strParam.Split(','); - for (int i = 0; i < 5; i++) + for (int i = 0; i < nDancerCount; i++) { TJAPlayer3.Skin.Game_Dancer_X[i] = int.Parse(strSplit[i]); } @@ -175,7 +316,7 @@ namespace TJAPlayer3 else if (strCommand == "Game_Dancer_Y") { string[] strSplit = strParam.Split(','); - for (int i = 0; i < 5; i++) + for (int i = 0; i < nDancerCount; i++) { TJAPlayer3.Skin.Game_Dancer_Y[i] = int.Parse(strSplit[i]); } @@ -184,15 +325,30 @@ namespace TJAPlayer3 { TJAPlayer3.Skin.Game_Dancer_Motion = strParam; } - // Game_Dancer_PtnはTextrueLoader.csで反映されます。 + else if (strCommand == "Game_Dancer_In_Motion") + { + Game_Dancer_In_Motion = strParam; + } + else if (strCommand == "Game_Dancer_Out_Motion") + { + Game_Dancer_Out_Motion = strParam; + } else if (strCommand == "Game_Dancer_Beat") { nDancerBeat = int.Parse(strParam); } + else if (strCommand == "Game_Dancer_In_Interval") + { + nDancerInInterval = int.Parse(strParam); + } + else if (strCommand == "Game_Dancer_Out_Interval") + { + nDancerOutInterval = int.Parse(strParam); + } else if (strCommand == "Game_Dancer_Gauge") { string[] strSplit = strParam.Split(','); - for (int i = 0; i < 5; i++) + for (int i = 0; i < nDancerCount; i++) { TJAPlayer3.Skin.Game_Dancer_Gauge[i] = int.Parse(strSplit[i]); } diff --git a/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsMob.cs b/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsMob.cs index 9da7c910..b53c03d5 100644 --- a/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsMob.cs +++ b/OpenTaiko/src/Stages/07.Game/Taiko/CAct演奏DrumsMob.cs @@ -26,26 +26,25 @@ namespace TJAPlayer3 { Random random = new Random(); - var upDirs = System.IO.Directory.GetFiles(mobDir); + var upDirs = System.IO.Directory.GetDirectories(mobDir); if (upDirs.Length > 0) { - var _presetPath = (preset != null && preset.MobSet != null) ? $@"{mobDir}" + preset.MobSet[random.Next(0, preset.MobSet.Length)] + ".png" : ""; - var path = (preset != null && System.IO.File.Exists(_presetPath)) + var _presetPath = (preset != null && preset.MobSet != null) ? $@"{mobDir}" + preset.MobSet[random.Next(0, preset.MobSet.Length)] : ""; + var path = (preset != null && System.IO.Directory.Exists(_presetPath)) ? _presetPath : upDirs[random.Next(0, upDirs.Length)]; - Mob = TJAPlayer3.tテクスチャの生成(path); + MobScript = new ScriptBG($@"{path}{Path.DirectorySeparatorChar}Script.lua"); + MobScript.Init(); } } - nMobBeat = TJAPlayer3.Skin.Game_Mob_Beat; - base.Activate(); } public override void DeActivate() { - TJAPlayer3.tテクスチャの解放(ref Mob); + MobScript?.Dispose(); base.DeActivate(); } @@ -66,6 +65,10 @@ namespace TJAPlayer3 { if (TJAPlayer3.stage選曲.n確定された曲の難易度[0] != (int)Difficulty.Tower && TJAPlayer3.stage選曲.n確定された曲の難易度[0] != (int)Difficulty.Dan) { + if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) MobScript?.Update(); + MobScript?.Draw(); + + /* if (HGaugeMethods.UNSAFE_IsRainbow(0)) { @@ -83,16 +86,14 @@ namespace TJAPlayer3 Mob.t2D描画(0, (TJAPlayer3.Skin.Resolution[1] - (Mob.szテクスチャサイズ.Height - moveHeight)) + -((float)Math.Sin(nNowMobCounter * (Math.PI / 180)) * moveHeight)); } - + */ } } return base.Draw(); } #region[ private ] //----------------- - public CTexture Mob; - private float nNowMobCounter; - private float nMobBeat; + private ScriptBG MobScript; //----------------- #endregion } diff --git a/OpenTaiko/src/Stages/07.Game/Taiko/ScriptBG.cs b/OpenTaiko/src/Stages/07.Game/Taiko/ScriptBG.cs index f61197d4..a206b50c 100644 --- a/OpenTaiko/src/Stages/07.Game/Taiko/ScriptBG.cs +++ b/OpenTaiko/src/Stages/07.Game/Taiko/ScriptBG.cs @@ -116,6 +116,24 @@ namespace TJAPlayer3 } } } + + public double GetTextureWidth(string fileName) + { + if (Textures[fileName] != null) + { + return Textures[fileName].szテクスチャサイズ.Width; + } + return -1; + } + + public double GetTextureHeight(string fileName) + { + if (Textures[fileName] != null) + { + return Textures[fileName].szテクスチャサイズ.Height; + } + return -1; + } } class ScriptBG : IDisposable {