diff --git a/Adventures in Lestoria/GiantOctopus.cpp b/Adventures in Lestoria/GiantOctopus.cpp index 157f27b2..f29334f7 100644 --- a/Adventures in Lestoria/GiantOctopus.cpp +++ b/Adventures in Lestoria/GiantOctopus.cpp @@ -45,6 +45,7 @@ All rights reserved. using A=Attribute; INCLUDE_game +INCLUDE_MONSTER_LIST void Monster::STRATEGY::GIANT_OCTOPUS(Monster&m,float fElapsedTime,std::string strategy){ enum PhaseName{ @@ -53,10 +54,32 @@ void Monster::STRATEGY::GIANT_OCTOPUS(Monster&m,float fElapsedTime,std::string s }; switch(PHASE()){ case IDENTIFY_ARMS:{ - + m.F(A::CASTING_TIMER)=util::random_range(ConfigFloatArr("Tentacle Move Timer",0),ConfigFloatArr("Tentacle Move Timer",1)); + for(std::shared_ptr&arm:MONSTER_LIST){ + const std::string OCTOPUS_ARM_NAME{"Octopus Arm"}; + if(arm->GetName()==OCTOPUS_ARM_NAME){ + std::weak_ptrarmPtr{arm}; + m.VEC(A::ARM_LIST).emplace_back(armPtr); + m.VEC(A::ARM_LOCATIONS).emplace_back(armPtr.lock()->GetPos()); + } + } }break; case NORMAL:{ - + m.F(A::CASTING_TIMER)-=fElapsedTime; + if(m.F(A::CASTING_TIMER)<=0.f){ + int deadMonsterCount{0}; + std::vectortempArmLocs; + for(size_t i=0U;std::any&arm:m.VEC(A::ARM_LIST)){ + const std::weak_ptr&m{std::any_cast>(arm)}; + if(m.expired()||m.lock()->IsDead()){ + deadMonsterCount++; + tempArmLocs.emplace_back(std::any_cast(m.VEC(A::ARM_LOCATIONS))); + } + } + if(deadMonsterCount>0){ + + } + } }break; } } \ No newline at end of file diff --git a/Adventures in Lestoria/MonsterAttribute.h b/Adventures in Lestoria/MonsterAttribute.h index 8adbc06f..f74b0a63 100644 --- a/Adventures in Lestoria/MonsterAttribute.h +++ b/Adventures in Lestoria/MonsterAttribute.h @@ -154,4 +154,6 @@ enum class Attribute{ SUCTION_TIMER, STORED_ARC, SWING_OCCURRED, + ARM_LOCATIONS, + ARM_LIST, }; \ No newline at end of file diff --git a/Adventures in Lestoria/OctopusArm.cpp b/Adventures in Lestoria/OctopusArm.cpp index 2328b9eb..6c86d44b 100644 --- a/Adventures in Lestoria/OctopusArm.cpp +++ b/Adventures in Lestoria/OctopusArm.cpp @@ -119,6 +119,7 @@ void Monster::STRATEGY::OCTOPUS_ARM(Monster&m,float fElapsedTime,std::string str const float alphaTimer{float(std::fmod(game->GetRunTime(),2.f))}; uint8_t alpha{util::lerp(uint8_t(0),uint8_t(255),alphaTimer)}; if(alphaTimer>1.f)alpha=util::lerp(0,255,1-(alphaTimer-1)); + game->DrawShadowStringDecal({100,100},std::format("{} - {}",alpha,alphaTimer)); attackArc.Draw(game,{0,0,255,uint8_t(alpha)}); if(storedArc.has_value()){ const uint8_t effectAlpha{util::lerp(uint8_t(0),uint8_t(255),alphaTimer/attackEffectTime)}; diff --git a/Adventures in Lestoria/Version.h b/Adventures in Lestoria/Version.h index 96dadab9..a482571d 100644 --- a/Adventures in Lestoria/Version.h +++ b/Adventures in Lestoria/Version.h @@ -39,7 +39,7 @@ All rights reserved. #define VERSION_MAJOR 1 #define VERSION_MINOR 3 #define VERSION_PATCH 0 -#define VERSION_BUILD 11794 +#define VERSION_BUILD 11795 #define stringify(a) stringify_(a) #define stringify_(a) #a diff --git a/Adventures in Lestoria/assets/config/MonsterStrategies.txt b/Adventures in Lestoria/assets/config/MonsterStrategies.txt index 07914560..83c4c8ec 100644 --- a/Adventures in Lestoria/assets/config/MonsterStrategies.txt +++ b/Adventures in Lestoria/assets/config/MonsterStrategies.txt @@ -1218,4 +1218,9 @@ MonsterStrategy # Amount of time the spreading aftershock effect appears for. Attack Effect Time = 0.4s } + Giant Octopus + { + # Min, Max duration + Tentacle Move Timer = 15s,25s + } } \ No newline at end of file diff --git a/x64/Release/Adventures in Lestoria.exe b/x64/Release/Adventures in Lestoria.exe index 81ee49ae..d590b910 100644 Binary files a/x64/Release/Adventures in Lestoria.exe and b/x64/Release/Adventures in Lestoria.exe differ