Skip to content

Commit

Permalink
Merge pull request #65 from RimNauts/main
Browse files Browse the repository at this point in the history
Fix issue with delivery cannon deleting items
  • Loading branch information
sindre0830 committed May 19, 2023
2 parents b637bb1 + 98cb525 commit c6723c4
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 2 deletions.
Binary file modified Assemblies/RimNauts2.dll
Binary file not shown.
1 change: 1 addition & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
# Changelog
- Fix issue with delivery cannon deleting items when it went over capacity
2 changes: 1 addition & 1 deletion Source/RimNauts2/RimNauts2/Constants.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
namespace RimNauts2 {
public static class Info {
public static readonly string name = "RimNauts 2";
public static readonly string version = "4.17.0";
public static readonly string version = "4.17.1";
}

public static class Style {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ private void launch() {
ThingOwner<Thing> things = new ThingOwner<Thing>();
float capacity = 0;
foreach (Thing thing in slotGroup.HeldThings) {
if (capacity >= Charger.Props.max_capacity) return;
if (capacity >= Charger.Props.max_capacity) break;
capacity += thing.def.BaseMass * thing.stackCount;
thing.holdingOwner = null;
things.TryAddOrTransfer(thing, thing.stackCount);
Expand Down

0 comments on commit c6723c4

Please sign in to comment.