[1.3] [KV] Weapon Storage [ModSync RW]

Started by Kiame, September 05, 2017, 05:46:47 PM

Previous topic - Next topic

mcduff

I get this bug when I open the shared weapons UI.
QuoteException filling window for WeaponStorage.UI.SharedWeaponsUI: System.ArgumentException: key already present in dictionary
Parameter name: key
  at System.Collections.Generic.SortedDictionary`2[System.String,Verse.ThingDef].Add (System.String key, Verse.ThingDef value) [0x00000] in <filename unknown>:0
  at WeaponStorage.UI.SharedWeaponFilterUI..ctor (WeaponStorage.SharedWeaponFilter filter) [0x00000] in <filename unknown>:0
  at WeaponStorage.UI.SharedWeaponsUI.DoWindowContents (Rect inRect) [0x00000] in <filename unknown>:0
  at Verse.Window+<WindowOnGUI>c__AnonStorey0.<>m__0 (Int32 x) [0x00000] in <filename unknown>:0
Verse.Log:Error(String, Boolean)
Verse.<WindowOnGUI>c__AnonStorey0:<>m__0(Int32)
UnityEngine.GUI:CallWindowDelegate(WindowFunction, Int32, Int32, GUISkin, Int32, Single, Single, GUIStyle)


Amnesiac

Hi Kiame,

I think there is an issue currently with the weapon storage, it seems to randomly teleport beer. I have no idea why.

I've moved the weapon storage box around, and every so often all, or sometimes only 40 or so, of my beer will teleport to the circle area of the weapon storage box.

The issue may have started when I started using VGP Garden Drinks, which adds new alcohol types and may mess with the beer in some way that causes it to do this.

Beer, Mead, and other alcoholic drinks are available to be stored in the weapon box as well, though I have beer disabled the beer still teleports

Kiame

Update:
The stored weapons will now correctly calculate the value of apparel stored in Weapon Storage

Kiame

Update:
The Assign Weapon window's scroll will not go past the button at the bottom. This was making it hard to see the last item in the list.


Kiame

Update:
Fix issue where the game would crash if all weapons were unassigned from a hunting pawn.

Kiame

Update:
- When a pawn dies, their weapon will go to weapon storage (assuming there's a weapon storage that can accept the weapon)
- Biocoded weapons will now be displayed at the bottom of Assign Weapons gui. They will also list who they're encoded to.
- Biocoded weapons will no longer be assigned from Shared Weapons
- When a Single-Use weapon is fired, it will now be removed from the pawn's assigned weapons.

daquan_baton

It seems this mod isn't compatible with the Facial Stuff mod, loading only this and FS causes the game to load forever/never finish loading/stuck on menu screen with no buttons.

I'm not sure how to get an error log, since the game never loads. Although I was able to change the order in which they load, but no matter their orientation this yields the same outcome.

Kiame

Very interesting, there shouldn't be any conflicts between the two. I'll investigate

Kiame

Just tested and loads fine with Weapon Storage and Facial Stuff

Kiame

#205
Update:
Fixed an issue where pawns would drop weapons when both hands/arms are damaged to the point they cannot hold weapon.

Important points:
There is a new mod setting (and a relatively new one) that play a part in this. These settings apply to dropping weapons as well

- Place Dropped Weapon In Storage (default true)
When any weapon is dropped by a player pawn, the weapon will try to be placed in storage. If there is no storage that can accept the weapon then the weapon will be dropped normally

- Allow Pawn to Drop Weapon (default false)
This will disable the Drop Weapon option from the right click menu. This also plays into this logic in that when a pawn loses arms, the equipped weapon will stay assigned to them instead of being placed into the weapon storage

Additional Point:
Shared weapons ignore the above settings and will be placed into storage. If no storage is available to accept the weapon then it will be dropped normally.

VKV

Hi there,

It's a great mod and I have been using it in previous versions too. Now I'm playing with it again with Rimworld 1.1, and I can't find the Assign button. Could you please let me know where to access it? A screenshot would definitely help.

Note: it might be a compatibility issue, but I see no error in the logs, and I'm not using Combat Extended.

Thanks!

VKV

Quote from: VKV on April 07, 2020, 12:07:19 PM
It's a great mod and I have been using it in previous versions too. Now I'm playing with it again with Rimworld 1.1, and I can't find the Assign button. Could you please let me know where to access it? A screenshot would definitely help.

OK, got it again. It's in the action button toolbar at the bottom of the screen, next to Install, Uninstall and Build copy when the Weapon Storage item is selected.

Kiame


Kiame

#209
Update:
Assign Weapon changes:
- Pawns are listed in alphabetical order with previous/next buttons to allow easy cycling.
- Weapon Storages are now listed and can also be cycled through
- Search will now hide unassigned weapons only

When a pawn is selected a new button is available - "Equip From". When pressed, the Assign Weapon window will come up with the pawn selected. A weapon storage can then be selected to interact with from the window. This button can be turned off from mod settings.