- I understand client-server side now.
Than i need help with this button function.
util.AddNetworkString("NPCShop_AddEntity") net.Receive('NPCShop_AddEntity', function(length, ply) if ply:canAfford(100) then ply:Give( "item_healthkit" ) else return false end end)
Clicker.DoClick = function() hello:Remove() net.Start("SA_CloseNPCMenu") net.SendToServer() net.Start("NPCShop_AddEntity") net.SendToServer() end
Everything is working fine but when i click on button server gives me the entity on the floor and not in my inventory, but if i would change the entity to weapon like “weapon_ak47” it would give the weapon in my inventory.
So yea i would like to know if there is a option so the entity goes into the inventory.