diff --git a/Crawler/Crawler.cpp b/Crawler/Crawler.cpp index ea615cde..634de3fa 100644 --- a/Crawler/Crawler.cpp +++ b/Crawler/Crawler.cpp @@ -1176,8 +1176,7 @@ void Crawler::RenderHud(){ DrawShadowStringDecal({0,136},"Spd: "+std::to_string(player->GetMoveSpdMult())); DrawShadowStringDecal({0,1},"Selection: "+Menu::menus[INVENTORY]->selection.str()); DrawShadowStringDecal({0,12},"Button Hold Time: "+std::to_string(Menu::menus[INVENTORY]->buttonHoldTime)); - } -} + }} void Crawler::RenderCooldowns(){ std::vectorcooldowns{ @@ -1818,6 +1817,10 @@ void Crawler::DrawPie(vf2d center,float radius,float degreesCut,Pixel col){ DrawPolygonDecal(nullptr,circleCooldownPoints,circleCooldownPoints,std::max(1,int(degreesCut/4)),center,radius,col); } +void Crawler::DrawSquarePie(vf2d center,float radius,float degreesCut,Pixel col){ + DrawPolygonDecal(nullptr,squareCircleCooldownPoints,squareCircleCooldownPoints,std::max(1,int(degreesCut/4)),center,radius,col); +} + void Crawler::InitializeDefaultKeybinds(){ Player::KEY_ABILITY1.AddKeybind({KEY,Q}); Player::KEY_ABILITY2.AddKeybind({KEY,E}); @@ -1910,9 +1913,14 @@ void Crawler::RenderMenu(){ void Crawler::InitializeGraphics(){ circleCooldownPoints.push_back({0,0}); + squareCircleCooldownPoints.push_back({0,0}); for(int i=0;i<=360;i+=4){ float angle=util::degToRad(i)-PI/2; circleCooldownPoints.push_back(vf2d{cos(angle),sin(angle)}); + vf2d point=vf2d{cos(angle),sin(angle)}*sqrt(2.1f); + point.x=std::clamp(point.x,-1.f,1.f); + point.y=std::clamp(point.y,-1.f,1.f); + squareCircleCooldownPoints.push_back(point); } for(auto&val:DATA["Images"].GetKeys()){ diff --git a/Crawler/Crawler.h b/Crawler/Crawler.h index b922db8e..73b5579f 100644 --- a/Crawler/Crawler.h +++ b/Crawler/Crawler.h @@ -68,6 +68,7 @@ private: std::vectordropsBeforeLower,dropsAfterLower,dropsBeforeUpper,dropsAfterUpper; std::vectorendZones,upperEndZones; std::vectorcircleCooldownPoints; + std::vectorsquareCircleCooldownPoints; std::mapMAP_TILESETS; vf2d worldShake={}; float worldShakeTime=0; @@ -161,6 +162,7 @@ public: bool IsReflectiveTile(TilesheetData tileSheet,int tileID); void SpawnMonster(vf2d pos,MonsterData*data,bool upperLevel=false,bool isBossSpawn=false); //Queues a monster for spawning on the next frame. void DrawPie(vf2d center,float radius,float degreesCut,Pixel col); + void DrawSquarePie(vf2d center,float radius,float degreesCut,Pixel col); void RenderCooldowns(); void InitializeDefaultKeybinds(); void SetBossNameDisplay(std::string name,float time=5); diff --git a/Crawler/ItemDrop.cpp b/Crawler/ItemDrop.cpp index 3f5e9a84..5e4bf27b 100644 --- a/Crawler/ItemDrop.cpp +++ b/Crawler/ItemDrop.cpp @@ -104,7 +104,7 @@ void ItemDrop::UpdateDrops(float fElapsedTime){ drop.pos=game->GetPlayer()->GetPos(); drop.collected=true; }else{ - drop.pos+=pointVel*(1.f/dist)*"ItemDrop.Item Drop Suction Strength"_F*fElapsedTime; + drop.pos+=pointVel*(1.f/std::min(48.f,dist))*"ItemDrop.Item Drop Suction Strength"_F*fElapsedTime; } } } diff --git a/Crawler/Version.h b/Crawler/Version.h index 48da7c33..df7ab210 100644 --- a/Crawler/Version.h +++ b/Crawler/Version.h @@ -35,7 +35,7 @@ SUCH DAMAGE. #define VERSION_MAJOR 0 #define VERSION_MINOR 2 #define VERSION_PATCH 1 -#define VERSION_BUILD 3077 +#define VERSION_BUILD 3085 #define stringify(a) stringify_(a) #define stringify_(a) #a diff --git a/Crawler/assets/config/gfx/gfx.txt b/Crawler/assets/config/gfx/gfx.txt index 25fc66e8..706c56d3 100644 --- a/Crawler/assets/config/gfx/gfx.txt +++ b/Crawler/assets/config/gfx/gfx.txt @@ -40,6 +40,8 @@ Images GFX_SkillOverlayIconOverlay = skill_overlay_icon_overlay.png GFX_FinishRing = finishring.png GFX_FinishRingGreen = finishring_green.png + GFX_SkillIcon = skill_overlay_icon.png + GFX_SkillIconEmpty = skill_overlay_icon_empty.png # Ability Icons GFX_Warrior_BattleCry_Icon = Ability Icons/battlecry.png diff --git a/Crawler/assets/config/items/items.txt b/Crawler/assets/config/items/items.txt index 54d6ac6a..cf17d8f5 100644 --- a/Crawler/assets/config/items/items.txt +++ b/Crawler/assets/config/items/items.txt @@ -13,10 +13,10 @@ ItemDrop Item Drop Vertical Speed = -15,15 # Item drop suction range - Item Drop Suction Range = 48 + Item Drop Suction Range = 360 # Item drop suction strength - Item Drop Suction Strength = 350 + Item Drop Suction Strength = 5000 # Item drop initial rise speed Item Drop Initial Rise Speed = 10 diff --git a/Crawler/assets/square_skill_overlay_icon.png b/Crawler/assets/square_skill_overlay_icon.png new file mode 100644 index 00000000..ed8cd97e Binary files /dev/null and b/Crawler/assets/square_skill_overlay_icon.png differ diff --git a/Crawler/assets/square_skill_overlay_icon_empty.png b/Crawler/assets/square_skill_overlay_icon_empty.png new file mode 100644 index 00000000..b7540359 Binary files /dev/null and b/Crawler/assets/square_skill_overlay_icon_empty.png differ diff --git a/x64/Release/Crawler.exe b/x64/Release/Crawler.exe index 07713bcc..ff8afc5b 100644 Binary files a/x64/Release/Crawler.exe and b/x64/Release/Crawler.exe differ