diff --git a/Changelog.txt b/Changelog.txt index 6c561f274..c7d43d42b 100644 --- a/Changelog.txt +++ b/Changelog.txt @@ -3962,4 +3962,9 @@ Added: 'H' shortcut for variables to get the value as hexadecimal. 2. No damage amount can be less than 1. 4-12-2024, canerksk -- Fixed: Sphere crash troubleshooting if a player has no CHATNAME value and remove a channel \ No newline at end of file +- Fixed: Sphere crash troubleshooting if a player has no CHATNAME value and remove a channel + +5-12-2024, canerksk +- Added: New item function, CARVECORPSE + It was not possible to cut a corpse from the outside and reveal the resources inside, this could not be done with a script or it required very long operations. .xCARVECORPSE command that can be used on corpses has been added, it directly carves the corpse. + \ No newline at end of file diff --git a/src/game/items/CItem.cpp b/src/game/items/CItem.cpp index fba785497..80049e552 100644 --- a/src/game/items/CItem.cpp +++ b/src/game/items/CItem.cpp @@ -3526,6 +3526,13 @@ bool CItem::r_Verb( CScript & s, CTextConsole * pSrc ) // Execute command from s return false; pCharSrc->ItemBounce( this ); break; + case CIV_CARVECORPSE: + if (!pCharSrc) + return false; + if (!IsType(IT_CORPSE)) + return false; + pCharSrc->Use_CarveCorpse(dynamic_cast(this), this); + break; case CIV_CONSUME: ConsumeAmount( s.HasArgs() ? s.GetArgWVal() : 1 ); break; diff --git a/src/tables/CItem_functions.tbl b/src/tables/CItem_functions.tbl index fe303ab58..b313fa3bb 100644 --- a/src/tables/CItem_functions.tbl +++ b/src/tables/CItem_functions.tbl @@ -5,6 +5,7 @@ // ADD(BOUNCE, "BOUNCE") +ADD(CARVECORPSE, "CARVECORPSE") ADD(CONSUME, "CONSUME") ADD(CONTCONSUME, "CONTCONSUME") ADD(DECAY, "DECAY")