From 73129732813573834acbb441513b8d43775584e8 Mon Sep 17 00:00:00 2001 From: jc_gargma Date: Tue, 9 Apr 2024 12:41:03 -0700 Subject: Updated to 0.6.0 Revert weapon mount obsoletion Revert nether healing being too obvious Fix meat scrap description Fix missing rebuilt recon laser recipe Add patch to nerf fungal blossom spawn rate --- ...s-reloading-from-deleting-containers-4104.patch | 63 ---------------------- 1 file changed, 63 deletions(-) delete mode 100644 hotfix-02_fix-Prevents-reloading-from-deleting-containers-4104.patch (limited to 'hotfix-02_fix-Prevents-reloading-from-deleting-containers-4104.patch') diff --git a/hotfix-02_fix-Prevents-reloading-from-deleting-containers-4104.patch b/hotfix-02_fix-Prevents-reloading-from-deleting-containers-4104.patch deleted file mode 100644 index 5414c95..0000000 --- a/hotfix-02_fix-Prevents-reloading-from-deleting-containers-4104.patch +++ /dev/null @@ -1,63 +0,0 @@ -From db0b41135105d165ead640d4d4d46d220491c873 Mon Sep 17 00:00:00 2001 -From: joveeater -Date: Sat, 13 Jan 2024 12:21:59 +0000 -Subject: [PATCH] fix: Prevents reloading from deleting containers (#4104) - -* Prevents reloading from deleting containers - -* style(autofix.ci): automated formatting - ---------- - -Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> ---- - src/item.cpp | 24 ++++++++++-------------- - 1 file changed, 10 insertions(+), 14 deletions(-) - -diff --git a/src/item.cpp b/src/item.cpp -index 25051aeb76c..b4667994e17 100644 ---- a/src/item.cpp -+++ b/src/item.cpp -@@ -8186,9 +8186,7 @@ bool item::reload( player &u, item &loc, int qty ) - } - } - -- detached_ptr to_reload = item::spawn( *ammo ); -- to_reload->charges = qty; -- ammo->charges -= qty; -+ detached_ptr to_reload = ammo->split( qty ); - bool merged = false; - for( item *it : contents.all_items_top() ) { - if( it->merge_charges( std::move( to_reload ) ) ) { -@@ -8246,19 +8244,17 @@ bool item::reload( player &u, item &loc, int qty ) - ammo->charges -= qty; - charges += qty; - } -- } -- -- // we have transfered ammo from the container to the item -- // therefore, we erase the 0-charge item inside container -- // TODO: why don't we just remove 0-charge items? -- if( ammo->charges == 0 && !ammo->has_flag( flag_SPEEDLOADER ) ) { -- if( container != nullptr && !container->contents.empty() ) { -- container->remove_item( container->contents.front() ); -- u.inv_restack( ); // emptied containers do not stack with non-empty ones -- } else { -- loc.detach(); -+ // we have transfered ammo from the container to the item -+ // therefore, we erase the 0-charge item inside container -+ // TODO: why don't we just remove 0-charge items? -+ if( ammo->charges == 0 && !ammo->has_flag( flag_SPEEDLOADER ) ) { -+ ammo->detach(); -+ if( container != nullptr ) { -+ u.inv_restack(); -+ } - } - } -+ - return true; - } - --- -2.43.0 - -- cgit v1.2.1