边缘世界 RimWorld

边缘世界 RimWorld

Universal Trade Hub
 此主题已被置顶,因此可能具有重要性
жопа  [开发者] 2024 年 7 月 3 日 下午 5:13
Bugs
Post bugs here! Explanations as to what led to the bug occurring and full logs help a ton. It's unlikely that I'll be able to fix the issue if you don't include that. :csgo_explosion:
< >
正在显示第 1 - 15 条,共 33 条留言
Vaarelsauce 2024 年 7 月 5 日 上午 12:49 
Buys steel. Steel lost during shipment. Tried buying steel again. But when I click "Place Order", nothing happens. In my console log, it states:

Exception filling window for Universal_Trade_Hub.UTH_OrderCategoriesMenu: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 90DD5649]
at AlteredCarbon.TradeUtility_PlayerSellableNow_Patch.Postfix (System.Boolean& __result, Verse.Thing t, RimWorld.ITrader trader) [0x00037] in <efe38b4e71be4943b0284ca8eb519dcb>:0
at RimWorld.TradeUtility.PlayerSellableNow (Verse.Thing t, RimWorld.ITrader trader) [0x00117] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
- POSTFIX Altered.Carbon: Void AlteredCarbon.TradeUtility_PlayerSellableNow_Patch:Postfix(Boolean& __result, Thing t, ITrader trader)
at MapWideTradeBeacon.Patcher.CommonLaunchableTFT (System.Collections.Generic.List`1[T] list, Verse.Map map, RimWorld.ITrader trader) [0x000fc] in <eeacaeca16c24d92898d10fc401232d0>:0
at MapWideTradeBeacon.Patcher.AllLaunchableThingsForTrade (System.Collections.Generic.IEnumerable`1[Verse.Thing]& __result, Verse.Map map, RimWorld.ITrader trader) [0x0001d] in <eeacaeca16c24d92898d10fc401232d0>:0
at RimWorld.TradeUtility.AllLaunchableThingsForTrade (Verse.Map map, RimWorld.ITrader trader) [0x00025] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
- POSTFIX OopsAllGeneBanks.mod: IEnumerable`1 OopsAllGeneBanks.TradeUtility_AllLaunchableThingsForTrade_Patch:Postfix(IEnumerable`1 results, Map map, ITrader trader)
- POSTFIX com.SupesSolutions.MapWideTradeBeacon: Void MapWideTradeBeacon.Patcher:AllLaunchableThingsForTrade(IEnumerable`1& __result, Map map, ITrader trader)
- POSTFIX ReSpliceCoreMod: IEnumerable`1 ReSpliceCore.TradeUtility_AllLaunchableThingsForTrade_Patch:Postfix(IEnumerable`1 result, Map map, ITrader trader)
at Universal_Trade_Hub.UTH_UIUtility.CalculateTotalAvailableSilver (Verse.Map map) [0x00004] in <32a746feaa544ef5a5de4dd8a89b1fd5>:0
at <0x1b23f74e240 + 0x002aa> <unknown method>
at Universal_Trade_Hub.UTH_OrderCategoriesMenu.DoWindowContents (UnityEngine.Rect inRect) [0x001e2] in <32a746feaa544ef5a5de4dd8a89b1fd5>:0
at Verse.Window.InnerWindowOnGUI (System.Int32 x) [0x001a6] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch5 (string)
Verse.Window:InnerWindowOnGUI (int)
UnityEngine.GUI:CallWindowDelegate (UnityEngine.GUI/WindowFunction,int,int,UnityEngine.GUISkin,int,single,single,UnityEngine.GUIStyle)
жопа  [开发者] 2024 年 7 月 5 日 上午 1:19 
引用自 Vaarelsauce
Buys steel. Steel lost during shipment. Tried buying steel again. But when I click "Place Order", nothing happens. In my console log, it states:

Exception filling window for Universal_Trade_Hub.UTH_OrderCategoriesMenu: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 90DD5649]
at AlteredCarbon.TradeUtility_PlayerSellableNow_Patch.Postfix (System.Boolean& __result, Verse.Thing t, RimWorld.ITrader trader) [0x00037] in <efe38b4e71be4943b0284ca8eb519dcb>:0
at RimWorld.TradeUtility.PlayerSellableNow (Verse.Thing t, RimWorld.ITrader trader) [0x00117] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
- POSTFIX Altered.Carbon: Void AlteredCarbon.TradeUtility_PlayerSellableNow_Patch:Postfix(Boolean& __result, Thing t, ITrader trader)
at MapWideTradeBeacon.Patcher.CommonLaunchableTFT (System.Collections.Generic.List`1[T] list, Verse.Map map, RimWorld.ITrader trader) [0x000fc] in <eeacaeca16c24d92898d10fc401232d0>:0
at MapWideTradeBeacon.Patcher.AllLaunchableThingsForTrade (System.Collections.Generic.IEnumerable`1[Verse.Thing]& __result, Verse.Map map, RimWorld.ITrader trader) [0x0001d] in <eeacaeca16c24d92898d10fc401232d0>:0
at RimWorld.TradeUtility.AllLaunchableThingsForTrade (Verse.Map map, RimWorld.ITrader trader) [0x00025] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
- POSTFIX OopsAllGeneBanks.mod: IEnumerable`1 OopsAllGeneBanks.TradeUtility_AllLaunchableThingsForTrade_Patch:Postfix(IEnumerable`1 results, Map map, ITrader trader)
- POSTFIX com.SupesSolutions.MapWideTradeBeacon: Void MapWideTradeBeacon.Patcher:AllLaunchableThingsForTrade(IEnumerable`1& __result, Map map, ITrader trader)
- POSTFIX ReSpliceCoreMod: IEnumerable`1 ReSpliceCore.TradeUtility_AllLaunchableThingsForTrade_Patch:Postfix(IEnumerable`1 result, Map map, ITrader trader)
at Universal_Trade_Hub.UTH_UIUtility.CalculateTotalAvailableSilver (Verse.Map map) [0x00004] in <32a746feaa544ef5a5de4dd8a89b1fd5>:0
at <0x1b23f74e240 + 0x002aa> <unknown method>
at Universal_Trade_Hub.UTH_OrderCategoriesMenu.DoWindowContents (UnityEngine.Rect inRect) [0x001e2] in <32a746feaa544ef5a5de4dd8a89b1fd5>:0
at Verse.Window.InnerWindowOnGUI (System.Int32 x) [0x001a6] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch5 (string)
Verse.Window:InnerWindowOnGUI (int)
UnityEngine.GUI:CallWindowDelegate (UnityEngine.GUI/WindowFunction,int,int,UnityEngine.GUISkin,int,single,single,UnityEngine.GUIStyle)

Looks like an incompatibility with either Altered Carbon, All Gene Banks, MapWideTradeBeacon or Resplice Core. I'd probably bet on it being MapWideTradeBeacon, but not sure. Can't really do much from my side though unfortunately.
жопа  [开发者] 2024 年 7 月 5 日 上午 2:36 
I added a null check in the method for the map if for whatever reason it did not exist. See if that fixes it for you. Make sure to update to the latest version of the mod.
Rakey 2024 年 7 月 5 日 上午 4:43 
Cannot purchase materials, only high-tech medicines can be purchased in the pharmaceutical category, and herbal medicines and medical kits cannot be purchased.

引用自 author
Exception filling window for Universal_Trade_Hub.UTH_OrderCategoriesMenu: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 11E08C92]
at <0x1d58c9a2f00 + 0x004f3> <unknown method>
at Universal_Trade_Hub.UTH_OrderCategoriesMenu.DoWindowContents (UnityEngine.Rect inRect) [0x001e2] in <9f7c59687624452b8a3590128131d2e5>:0
at Verse.Window.InnerWindowOnGUI (System.Int32 x) [0x001a6] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
Verse.Log:Error (string)
Verse.Window:InnerWindowOnGUI (int)
UnityEngine.GUI:CallWindowDelegate (UnityEngine.GUI/WindowFunction,int,int,UnityEngine.GUISkin,int,single,single,UnityEngine.GUIStyle)
最后由 Rakey 编辑于; 2024 年 7 月 5 日 上午 4:47
жопа  [开发者] 2024 年 7 月 5 日 上午 4:46 
引用自 Rakey
Cannot purchase materials, only high-tech medicines can be purchased in the pharmaceutical category, and herbal medicines and medical kits cannot be purchased.

引用自 author
Exception filling window for Universal_Trade_Hub.UTH_OrderCategoriesMenu: System.NullReferenceException: Object reference not set to an instance of an object
[Ref 11E08C92]
at <0x1d58c9a2f00 + 0x004f3> <unknown method>
at Universal_Trade_Hub.UTH_OrderCategoriesMenu.DoWindowContents (UnityEngine.Rect inRect) [0x001e2] in <9f7c59687624452b8a3590128131d2e5>:0
at Verse.Window.InnerWindowOnGUI (System.Int32 x) [0x001a6] in <f0ac5eb9b52e4cc396c70fc9a4ee15e5>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
Verse.Log:Error (string)
Verse.Window:InnerWindowOnGUI (int)
UnityEngine.GUI:CallWindowDelegate (UnityEngine.GUI/WindowFunction,int,int,UnityEngine.GUISkin,int,single,single,UnityEngine.GUIStyle)

Fixed. Make sure to update to latest version.
最后由 жопа 编辑于; 2024 年 7 月 5 日 上午 4:55
Glass Shahk 2024 年 7 月 5 日 上午 6:13 
No issue, just love to see an author upkeep their mod for the community! Love the mod!
жопа  [开发者] 2024 年 7 月 5 日 上午 7:27 
引用自 Glass Shahk
No issue, just love to see an author upkeep their mod for the community! Love the mod!

I appreciate your support!
Vaarelsauce 2024 年 7 月 5 日 下午 1:34 
引用自 alt4s
I added a null check in the method for the map if for whatever reason it did not exist. See if that fixes it for you. Make sure to update to the latest version of the mod.

Either your patch or restarting the game fixed the bug. However, for some reason the tax cost went bonkers afterward (even though the config says it's at 10% default):

https://imgur.com/a/TBCwL84
Image: 1 piece of silver is $1.00, but...
Total Price (minus tax): $1.00
Total Tax: $13075
Final Price (with tax): $13076
Skissors_ 2024 年 7 月 5 日 下午 3:57 
引用自 Vaarelsauce
引用自 alt4s
I added a null check in the method for the map if for whatever reason it did not exist. See if that fixes it for you. Make sure to update to the latest version of the mod.

Either your patch or restarting the game fixed the bug. However, for some reason the tax cost went bonkers afterward (even though the config says it's at 10% default):

https://imgur.com/a/TBCwL84
Image: 1 piece of silver is $1.00, but...
Total Price (minus tax): $1.00
Total Tax: $13075
Final Price (with tax): $13076


There is a "Wealth" tax multiplier in the settings that you can change to fix this until the author adjusts the default multiplier.
Paper Angel 2024 年 7 月 5 日 下午 10:20 
Tax adjustment doesn't seem to be working?
When purchasing 1 silver:
At 500% tax rate I get 25304 tax
At 250% tax rate I get 25302 tax
At 1% tax rate I get 25299 tax
At 0% tax rate I also get 25299 tax
So it looks like its calculating a fixed tax of ~25299k regardless of the tax % setting and the percentage applies to the value of the actual purpose.
Starting a new colony I get a similar behaviour but in place of the 25299 I'm getting a much lower value.
Assuming a lot since I don't have VS and can't see the code, but my guess is you have something like:
TaxRate * PurchaseCost + ColonyWeathCalc
when what you want is:
TaxRate * (PurchaseCost + ColonyWealthCalc)
Cool mod - hope this helps.
жопа  [开发者] 2024 年 7 月 6 日 上午 1:06 
引用自 Paper Angel
Tax adjustment doesn't seem to be working?
When purchasing 1 silver:
At 500% tax rate I get 25304 tax
At 250% tax rate I get 25302 tax
At 1% tax rate I get 25299 tax
At 0% tax rate I also get 25299 tax
So it looks like its calculating a fixed tax of ~25299k regardless of the tax % setting and the percentage applies to the value of the actual purpose.
Starting a new colony I get a similar behaviour but in place of the 25299 I'm getting a much lower value.
Assuming a lot since I don't have VS and can't see the code, but my guess is you have something like:
TaxRate * PurchaseCost + ColonyWeathCalc
when what you want is:
TaxRate * (PurchaseCost + ColonyWealthCalc)
Cool mod - hope this helps.

You need to adjust the "Wealth Multiplier" setting in mod settings instead.
最后由 жопа 编辑于; 2024 年 7 月 6 日 上午 1:54
жопа  [开发者] 2024 年 7 月 6 日 上午 1:11 
The crazy prices you’re getting is because it’s adding an additional 5% of your overall colony wealth to the total price by default - which yeah I now realize is a lot and might be jarring to some.
最后由 жопа 编辑于; 2024 年 7 月 6 日 上午 1:54
Paper Angel 2024 年 7 月 6 日 上午 8:25 
Ahh, so perhaps the problem then is that the wealth modifier is missing:from the options menu.
I can't post a screenshot here but for this mod I have the following options under the 'orders' tab:
Enable console init animation (checkbox)
Forbid items when delivered via drop pod (checkbox)
Tax Rate (slider)
Express Delivery Base Cost (slider)
Express Delivery Multiplier per KG (slider)
Express Delivery Multiplier Time Reduction (slider)
Insurance Base Cost (slider)
Insurance Multiplier (slider)
Reset (button)
There is also a 'credits' tab which has a 'your name here' for translators. There's no other tabs.

Update: Oh also to validate this result I removed all other mods and loaded with only Universal Trade Hub active. Options are the same as noted above.
最后由 Paper Angel 编辑于; 2024 年 7 月 6 日 上午 8:27
жопа  [开发者] 2024 年 7 月 6 日 上午 8:37 
引用自 Paper Angel
Ahh, so perhaps the problem then is that the wealth modifier is missing:from the options menu.
I can't post a screenshot here but for this mod I have the following options under the 'orders' tab:
Enable console init animation (checkbox)
Forbid items when delivered via drop pod (checkbox)
Tax Rate (slider)
Express Delivery Base Cost (slider)
Express Delivery Multiplier per KG (slider)
Express Delivery Multiplier Time Reduction (slider)
Insurance Base Cost (slider)
Insurance Multiplier (slider)
Reset (button)
There is also a 'credits' tab which has a 'your name here' for translators. There's no other tabs.

Update: Oh also to validate this result I removed all other mods and loaded with only Universal Trade Hub active. Options are the same as noted above.

Have you tried scrolling?
Paper Angel 2024 年 7 月 6 日 上午 9:42 
Ugghhh... I'd swear I tried that earlier but obviously I tried it just now and it works.
I'll just pack my things and go. Thanks for the help (and patience)
< >
正在显示第 1 - 15 条,共 33 条留言
每页显示数: 1530 50