rebel1324 / NutScript

A free role-play framework for Garry's Mod.
http://nutscript.net
MIT License
65 stars 31 forks source link

Vendors don't function properly in NS 1.1 Beta #253

Closed dickmosi closed 5 years ago

dickmosi commented 5 years ago

Three issues:

  1. https://i.imgur.com/FlLbbA1.jpg

  2. Set the item's ITEM.price to 50 Create a vendor then set said item for 10 and make the sell for value 0.75 (75%) Then sell the item to the vendor, the money that you should get is displayed properly on "Sell for X Currency" button but the money you actually get is based on ITEM.price

https://i.imgur.com/PAFFv7g.png https://i.imgur.com/Z0iU0B2.png

  1. Spawn in a vendor, restrict to a certain faction then have a non-admin player that's part of said faction try and access the vendor - They can't.

Side note: When ticking the box in the faction editor, if you close the faction editor then reopen it the box won't show as being ticked even though it is. https://youtu.be/Kj2xocopt94

brianhang commented 5 years ago

Can you check if the features/vendor branch fixes these issues? In my testing, they seem to work.

dickmosi commented 5 years ago

That branch has fixed all of the previously listed issues, however I've discovered two more with the new vendor plugin.

  1. Create a vendor, add the items to said vendor
  2. Create a new vendor and access it You'll notice it already has items for sale, the exact same items as you set for Vendor A
  3. Add or remove something on Vendor B then check Vendor A You'll notice that addition/removal also affects Vendor A

[ERROR] gamemodes/nutscript/plugins/vendor/derma/cl_vendoreditor.lua:106: attempt to perform arithmetic on a nil value

  1. unknown - gamemodes/nutscript/plugins/vendor/derma/cl_vendoreditor.lua:106

Timer Failed! [nutVendorScale][@gamemodes/nutscript/plugins/vendor/derma/cl_vendoreditor.lua (line 102)]

[dickmosi|3|STEAM_0:1:4883034] Lua Error: [ERROR] gamemodes/nutscript/plugins/vendor/derma/cl_vendoreditor.lua:106: attempt to perform arithmetic on a nil value

  1. unknown - gamemodes/nutscript/plugins/vendor/derma/cl_vendoreditor.lua:106
brianhang commented 5 years ago

Fixed in b46892343e7c66c0484a1ab4ff5818344d485858 and 560543494d7ca2a291a2cc3034cfddaa6e3a890c.

dickmosi commented 5 years ago

Issue resolved, thanks!