PivityGmodStore

Entity

Explanation

Items with the Type = "Entity" will spawn the entity next to the NPC on purchase.

Code Example

CH_NPC_Shops.Items["prop_vending_machine"] = { -- Unique name. Can be anything as long as it's unique.
Name = "Vending Machine", -- Name in the menu
Class = "prop_physics", -- Entity class name (in this case it's just a prop)
Type = "Entity", -- Type of the item (use Entity to spawn an entity)
Price = 1000, -- Price of the item
Description = "Vending machine prop used for decoration purposes.", -- Description in the menu
Model = "models/props_interiors/VendingMachineSoda01a.mdl", -- Model to display
Color = Color( 160, 160, 160 ), -- Color of the item
CanBuy = true, -- If the item can be bought from the store
CanSell = true, -- If the item can be sold to the store
}

Can't find what you're looking for?

Contact support