diff options
author | ubq323 <ubq323@ubq323.website> | 2023-01-08 16:08:18 +0000 |
---|---|---|
committer | ubq323 <ubq323@ubq323.website> | 2023-01-08 16:08:18 +0000 |
commit | 85d3dfa5a3c22886b7966b1a492f8f244e4b5a96 (patch) | |
tree | a217fcfc164b22ac0de9d4a943fada775d350b74 /shop2 | |
parent | 4db6ea9756c0785b6825a269fd30fce4752f7af0 (diff) |
shop2
Diffstat (limited to 'shop2')
-rw-r--r-- | shop2/disp.lua | 4 | ||||
-rw-r--r-- | shop2/items.lua | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/shop2/disp.lua b/shop2/disp.lua index 8dcee89..58389a0 100644 --- a/shop2/disp.lua +++ b/shop2/disp.lua @@ -59,8 +59,8 @@ local function disp_shopscreen(items) {1,2}, colors.lightGray, "Stock Price Adr. Name", } - local function fmt_row(y, idesc, amt, colour) - colour = colour or colors.cyan + local function fmt_row(y, idesc, amt) + colour = idesc.colour or colors.white printseq(mon) { {1,y}, colors.white, pad(amt,5), {8,y}, colors.yellow, pad(idesc.price,3), colors.lightGray, "kst", diff --git a/shop2/items.lua b/shop2/items.lua index 20e8a93..d110a67 100644 --- a/shop2/items.lua +++ b/shop2/items.lua @@ -1,6 +1,6 @@ local items = {} -local function i(adr,itname,hname,price) - items[adr]={itname=itname,hname=hname,price=price,adr=adr} +local function i(adr,itname,hname,price,colour) + items[adr]={itname=itname,hname=hname,price=price,adr=adr,colour=colour or colors.white} end i("dmn","minecraft:diamond","Diamond",5) i("blz","minecraft:blaze_rod","Blaze Rod",10) |