SHOW:
|
|
- or go back to the newest paste.
1 | local bridge = peripheral.find("rsBridge") | |
2 | ||
3 | local box = peripheral.find("chatBox") | |
4 | ||
5 | local manager = peripheral.find("inventoryManager") | |
6 | ||
7 | while true do | |
8 | ||
9 | event, username, message = os.pullEvent("chat") | |
10 | ||
11 | if username == "esgamo" | |
12 | then | |
13 | a = string.find(message, " ") | |
14 | itemname = string.sub(message, 0, a) | |
15 | itemcount = string.sub(message, a, string.len(message)) | |
16 | itemname = message | |
17 | end | |
18 | - | iteminfo = bridge.getItem({name=itemname}) |
18 | + | |
19 | - | bridge.exportItem({name=itemname},"top") |
19 | + | |
20 | ||
21 | bridge.exportItem({name=itemname,count=tonumber(itemcount)},"top") | |
22 | ||
23 | manager.addItemToPlayer("left",1000) | |
24 | ||
25 | end |