Jump to content

Custom Repec cost issue

Closed 1.2.0 1.2.1

Zoreeno
Zoreeno

Posted

Noticed a minor bug with the newest update surrounding using the "custom" setting for Skill Point respec costs.  I'm currently using paper with a custom cash name and skin as payment, like so....

    "Currency type to respec [scrap, economics, srp, custom]": "custom",
    "If currency is set to custom, what are the details of the item": {
      "displayName": "Cash",
      "shortname": "paper",
      "skin": 2420097877

If the player does not have enough of the "Cash" to pay for the cost of a respec, it does not print a message to chat telling them they have do not have enough, like it does for scrap. It also throws the following error in the console:

Failed to call hook 'DoRespec' on plugin 'SkillTree v1.2.0' (FormatException: Index (zero based) must be greater than or equal to zero and less than the size of the argument list.)
  at System.Text.StringBuilder.AppendFormatHelper (System.IFormatProvider provider, System.String format, System.ParamsArray args) [0x000ff] in <fb001e01371b4adca20013e0ac763896>:0
  at System.String.FormatHelper (System.IFormatProvider provider, System.String format, System.ParamsArray args) [0x00023] in <fb001e01371b4adca20013e0ac763896>:0
  at System.String.Format (System.String format, System.Object[] args) [0x00020] in <fb001e01371b4adca20013e0ac763896>:0
  at Oxide.Plugins.SkillTree.DoRespec (ConsoleSystem+Arg arg) [0x004ba] in <4abe414cfb07483da14127077dfa1613>:0
  at Oxide.Plugins.SkillTree.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x05311] in <4abe414cfb07483da14127077dfa1613>:0
  at Oxide.Plugins.CSharpPlugin.InvokeMethod (Oxide.Core.Plugins.HookMethod method, System.Object[] args) [0x00079] in <b6af59acae274e5a94fb209dfc179b8f>:0
  at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x000d8] in <bae5f1223fce49c493b01571c99dce02>:0
  at Oxide.Core.Plugins.Plugin.CallHook (System.String hook, System.Object[] args) [0x00060] in <bae5f1223fce49c493b01571c99dce02>:0

 

However, if the player does have enough to cover the cost, it takes the currency and resets their skills like normal. 

imthenewguy

Posted

tyty found the issue and added it to the next release.

  • Like 1
imthenewguy

Posted

Changed Status from Pending to Closed

Changed Fixed In to Next Version

1.4m

Downloads

Total number of downloads.

6.9k

Customers

Total customers served.

102.4k

Files Sold

Total number of files sold.

2m

Payments Processed

Total payments processed.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.