Skip to content

Commit

Permalink
Update items.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
DragonSlayer62 committed Jan 17, 2025
1 parent 21082cf commit add5789
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions source/items.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1207,6 +1207,10 @@ CItem * cItem::CreateBaseScriptItem( CItem *mCont, std::string ourItem, const UI
{
iCreated->SetMaxHP( iCreated->GetHP() );
}
else
{// If you add a maxhp tag and have durabilityHpBonus, it will increase the Durability (aka Health).
iCreated->SetMaxHP( iCreated->GetMaxHP() + durabilityHpBonus );
}

// If maxUses is higher than usesLeft for a new item, randomize the amount of usesLeft the item should have!
if( iCreated->GetMaxUses() > iCreated->GetUsesLeft() )
Expand Down

0 comments on commit add5789

Please sign in to comment.