|
|
@ -193,6 +193,8 @@ bool Crawler::OnUserCreate(){ |
|
|
|
Inventory::AddItem("Blue Slime Remains",22); |
|
|
|
Inventory::AddItem("Blue Slime Remains",22); |
|
|
|
Inventory::AddItem("Copper Armor"); |
|
|
|
Inventory::AddItem("Copper Armor"); |
|
|
|
Inventory::AddItem("Copper Pants"); |
|
|
|
Inventory::AddItem("Copper Pants"); |
|
|
|
|
|
|
|
Inventory::AddItem("Copper Helmet"); |
|
|
|
|
|
|
|
Inventory::AddItem("Copper Shoes"); |
|
|
|
Inventory::AddItem("Shell Helmet"); |
|
|
|
Inventory::AddItem("Shell Helmet"); |
|
|
|
Inventory::AddItem("Shell Armor"); |
|
|
|
Inventory::AddItem("Shell Armor"); |
|
|
|
Inventory::AddItem("Bone Armor"); |
|
|
|
Inventory::AddItem("Bone Armor"); |
|
|
@ -202,6 +204,9 @@ bool Crawler::OnUserCreate(){ |
|
|
|
Inventory::AddItem("Bone Gloves"); |
|
|
|
Inventory::AddItem("Bone Gloves"); |
|
|
|
Inventory::AddItem("Elixir of Bear Strength",3); |
|
|
|
Inventory::AddItem("Elixir of Bear Strength",3); |
|
|
|
Inventory::AddItem("Leather Helmet"); |
|
|
|
Inventory::AddItem("Leather Helmet"); |
|
|
|
|
|
|
|
Inventory::AddItem("Leather Pants"); |
|
|
|
|
|
|
|
Inventory::AddItem("Leather Gloves"); |
|
|
|
|
|
|
|
Inventory::AddItem("Leather Shoes"); |
|
|
|
|
|
|
|
|
|
|
|
LoadLevel(LEVEL_NAMES["starting_map"_S]); |
|
|
|
LoadLevel(LEVEL_NAMES["starting_map"_S]); |
|
|
|
ChangePlayerClass(WARRIOR); |
|
|
|
ChangePlayerClass(WARRIOR); |
|
|
@ -1196,6 +1201,14 @@ void Crawler::RenderWorld(float fElapsedTime){ |
|
|
|
view.DrawShadowStringPropDecal(dn->pos-GetTextSizeProp(text)/2,text,BLACK,VERY_DARK_GREY,{0.5,1}); |
|
|
|
view.DrawShadowStringPropDecal(dn->pos-GetTextSizeProp(text)/2,text,BLACK,VERY_DARK_GREY,{0.5,1}); |
|
|
|
} |
|
|
|
} |
|
|
|
}break; |
|
|
|
}break; |
|
|
|
|
|
|
|
case CRIT:{ |
|
|
|
|
|
|
|
std::string text=std::to_string(dn->damage); |
|
|
|
|
|
|
|
if(!dn->friendly){ |
|
|
|
|
|
|
|
view.DrawShadowStringPropDecal(dn->pos-GetTextSizeProp(text)/2,text,YELLOW,DARK_YELLOW); |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
view.DrawStringPropDecal(dn->pos-GetTextSizeProp(text)/2,text,BLACK); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}break; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -1254,6 +1267,8 @@ void Crawler::RenderHud(){ |
|
|
|
if("debug_player_info"_I){ |
|
|
|
if("debug_player_info"_I){ |
|
|
|
DrawShadowStringDecal({0,128},player->GetPos().str()); |
|
|
|
DrawShadowStringDecal({0,128},player->GetPos().str()); |
|
|
|
DrawShadowStringDecal({0,136},"Spd: "+std::to_string(player->GetMoveSpdMult())); |
|
|
|
DrawShadowStringDecal({0,136},"Spd: "+std::to_string(player->GetMoveSpdMult())); |
|
|
|
|
|
|
|
DrawShadowStringDecal({0,144},"HP Timer: "+std::to_string(player->hpRecoveryTimer)); |
|
|
|
|
|
|
|
DrawShadowStringDecal({0,152},"HP Recovery Amt: "+std::to_string(player->GetHPRecoveryPct()*player->GetMaxHealth())); |
|
|
|
if(!ISBLANK(GetLoadoutItem(0))){ |
|
|
|
if(!ISBLANK(GetLoadoutItem(0))){ |
|
|
|
DrawShadowStringDecal({0,92},"Loadout Slot 1 Qty: "+std::to_string(GetLoadoutItem(0).lock()->Amt())); |
|
|
|
DrawShadowStringDecal({0,92},"Loadout Slot 1 Qty: "+std::to_string(GetLoadoutItem(0).lock()->Amt())); |
|
|
|
} |
|
|
|
} |
|
|
@ -1277,9 +1292,9 @@ void Crawler::RenderCooldowns(){ |
|
|
|
if(loadoutSlot!=-1)iconScale={0.7f,0.7f}; |
|
|
|
if(loadoutSlot!=-1)iconScale={0.7f,0.7f}; |
|
|
|
DrawRotatedDecal(pos+vf2d{12,12},GFX[a.icon].Decal(),0,{12,12},iconScale,{255,255,255,64}); |
|
|
|
DrawRotatedDecal(pos+vf2d{12,12},GFX[a.icon].Decal(),0,{12,12},iconScale,{255,255,255,64}); |
|
|
|
if(circle){ |
|
|
|
if(circle){ |
|
|
|
DrawPie(pos+vf2d{12,12},12,360-(a.cooldown/a.COOLDOWN_TIME)*360,PixelLerp(a.barColor1,a.barColor2,(a.cooldown/a.COOLDOWN_TIME))); |
|
|
|
DrawPie(pos+vf2d{12,12},12,360-(a.cooldown/a.GetCooldownTime())*360,PixelLerp(a.barColor1,a.barColor2,(a.cooldown/a.GetCooldownTime()))); |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
DrawSquarePie(pos+vf2d{12,12},10,360-(a.cooldown/a.COOLDOWN_TIME)*360,PixelLerp(a.barColor1,a.barColor2,(a.cooldown/a.COOLDOWN_TIME))); |
|
|
|
DrawSquarePie(pos+vf2d{12,12},10,360-(a.cooldown/a.GetCooldownTime())*360,PixelLerp(a.barColor1,a.barColor2,(a.cooldown/a.GetCooldownTime()))); |
|
|
|
} |
|
|
|
} |
|
|
|
std::stringstream cooldownTimeDisplay;
|
|
|
|
std::stringstream cooldownTimeDisplay;
|
|
|
|
cooldownTimeDisplay<<std::fixed<<std::setprecision(1)<<a.cooldown; |
|
|
|
cooldownTimeDisplay<<std::fixed<<std::setprecision(1)<<a.cooldown; |
|
|
@ -1342,7 +1357,7 @@ void Crawler::RenderCooldowns(){ |
|
|
|
DrawShadowStringDecal(pos+vf2d{12,-2}-keyDisplaySize/2,a.input->GetDisplayName(),keyDisplayCol,BLACK,{0.5f,0.5f},std::numeric_limits<float>::max(),1); |
|
|
|
DrawShadowStringDecal(pos+vf2d{12,-2}-keyDisplaySize/2,a.input->GetDisplayName(),keyDisplayCol,BLACK,{0.5f,0.5f},std::numeric_limits<float>::max(),1); |
|
|
|
|
|
|
|
|
|
|
|
vf2d shortNameSize=vf2d{GetTextSize(a.shortName)}*vf2d{0.5f,0.75f}; |
|
|
|
vf2d shortNameSize=vf2d{GetTextSize(a.shortName)}*vf2d{0.5f,0.75f}; |
|
|
|
DrawShadowStringDecal(pos+vf2d{13,24}-shortNameSize/2,a.shortName,shortNameCol,{255,255,255,64},{0.5f,0.75f}); |
|
|
|
DrawShadowStringDecal(pos+vf2d{13,24}-shortNameSize/2,a.shortName,shortNameCol,WHITE,{0.5f,0.75f}); |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|