blob: 895e1fdac9d1051324ff91d1aee0ba0bf0542e59 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# Tut 0x041
## Not enough items
It frequently happens that you want many items with only slight variations. In this tutorial we'll see how to create a item drop for every monster. We'll find all the npc's that the game knows about, and create an item (a corpse) for each one.
First, we need to find all the npc's the game knows about, then create an item for each one.
garrysmod/addons/artery_routelite/data/artery/global/npc_corpses.lua
```
local base = {}
base.Name = "Meat base"
base.weight = 10
function base:Serialize()
return ""
end
function base:DeSerialize()
return table.Copy(self)
end
```
|