Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- term.clear()
- term.setTextColor(colors.cyan)
- term.setCursorPos(1,1)
- print("GazzOS V.7 - Market-Exchange")
- term.setTextColor(colors.white)
- --rednet.open("right")
- local deposit = peripheral.wrap("diamond_0")
- local top = peripheral.wrap("monitor_12")
- rednet.open("left")
- mouseWidth = 0
- mouseHeight = 0
- local m = peripheral.wrap("back")
- m.clear()
- m.setCursorPos(1,1)
- w,h=m.getSize()
- print(w)
- print(h)
- function checkbalance()
- id, message = rednet.receive()
- monitorbalance = message
- end
- function topupdate()
- rs.setBundledOutput("right", colors.brown)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.1)
- end
- --DurrDurr--
- function charge()
- deposit.condenseItems()
- if rost < 128 then
- deposit.pushItem("east",1,rost,1)
- rost = rost - 64
- deposit.pushItem("east",2,rost,2)
- topupdate()
- elseif rost < 192 then
- deposit.condenseItems()
- deposit.pushItem("east",1,rost,1)
- rost = rost - 64
- deposit.pushItem("east",2,rost,2)
- rost = rost - 64
- deposit.pushItem("east",3,rost,3)
- rost = rost - 64
- topupdate()
- elseif rost > 192 then
- deposit.condenseItems()
- deposit.pushItem("east",1,rost,1)
- rost = rost - 64
- deposit.pushItem("east",2,rost,2)
- rost = rost - 64
- deposit.pushItem("east",3,rost,3)
- rost = rost - 64
- deposit.pushItem("east",4,rost,4)
- rost = rost - 64
- topupdate()
- elseif rost < 64 then
- deposit.pushItem("east",1,rost,1)
- rs.setOutput("left", true)
- sleep(.8)
- rs.setOutput("left", false)
- end
- end
- --Durr--
- function clean()
- AmmountDiamond = 9 - 9
- AmmountWood = 9 - 9
- AmmountCopper = 9 - 9
- AmmountLapis = 9 - 9
- AmmountRedstone = 9 - 9
- AmmountTin = 9 - 9
- AmmountOsmium = 9 - 9
- AmmountIron = 9 - 9
- AmmountGold = 9 - 9
- newBal = 9 - 9
- end
- monitorbalance = 0
- rost = 0
- function onestackw()
- rs.setBundledOutput("right", colors.lightGray)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackw()
- onestackw()
- onestackw()
- end
- function fourstackw()
- twostackw()
- twostackw()
- end
- function onestacko()
- rs.setBundledOutput("right", colors.pink)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostacko()
- onestacko()
- onestacko()
- end
- function fourstacko()
- twostacko()
- twostacko()
- end
- function onestackl()
- rs.setBundledOutput("right", colors.lime)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackl()
- onestackl()
- onestackl()
- end
- function fourstackl()
- twostackl()
- twostackl()
- end
- function onestackt()
- rs.setBundledOutput("right", colors.lightBlue)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackt()
- onestackt()
- onestackt()
- end
- function fourstackt()
- twostackt()
- twostackt()
- end
- function onestackr()
- rs.setBundledOutput("right", colours.magenta)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackr()
- onestackr()
- onestackr()
- end
- function fourstackr()
- twostackr()
- twostackr()
- end
- function onestackc()
- rs.setBundledOutput("right", colours.yellow)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackc()
- onestackc()
- onestackc()
- end
- function fourstackc()
- twostackc()
- twostackc()
- end
- function onestackg()
- rs.setBundledOutput("right", colours.orange)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostackg()
- onestackg()
- onestackg()
- end
- function fourstackg()
- twostackg()
- twostackg()
- end
- function onestack()
- rs.setBundledOutput("right", colours.white)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.2)
- end
- function twostack()
- onestack()
- onestack()
- end
- function fourstack()
- twostack()
- twostack()
- end
- function doiron()
- if AmmountIron < 63 then
- print("No Iron")
- elseif AmmountIron < 65 then
- onestack()
- elseif AmmountIron < 129 then
- onestack()
- onestack()
- elseif AmmountIron < 193 then
- twostack()
- onestack()
- elseif AmmountIron < 257 then
- twostack()
- twostack()
- elseif AmmountIron < 321 then
- fourstack()
- onestack()
- elseif AmmountIron < 384 then
- fourstack()
- twostack()
- elseif AmmountIron < 449 then
- fourstack()
- twostack()
- onestack()
- elseif AmmountIron < 513 then
- fourstack()
- fourstack()
- elseif AmmountIron < 577 then
- fourstack()
- fourstack()
- onestack()
- elseif AmmountIron < 641 then
- fourstack()
- fourstack()
- twostack()
- elseif AmmountIron < 705 then
- fourstack()
- fourstack()
- twostack()
- onestack()
- elseif AmmountIron < 769 then
- fourstack()
- fourstack()
- fourstack()
- elseif AmmountIron < 833 then
- fourstack()
- fourstack()
- fourstack()
- onestack()
- elseif AmmountIron < 897 then
- fourstack()
- fourstack()
- fourstack()
- twostack()
- elseif AmmountIron < 961 then
- fourstack()
- fourstack()
- fourstack()
- twostack()
- onestack()
- elseif AmmountIron < 1025 then
- fourstack()
- fourstack()
- fourstack()
- fourstack()
- end
- end
- function docopper()
- if AmmountCopper < 63 then
- print("No Copper")
- elseif AmmountCopper < 65 then
- onestackc()
- elseif AmmountCopper < 129 then
- onestackc()
- onestackc()
- elseif AmmountCopper < 193 then
- twostackc()
- onestackc()
- elseif AmmountCopper < 257 then
- twostackc()
- twostackc()
- elseif AmmountCopper < 321 then
- fourstackc()
- onestackc()
- elseif AmmountCopper < 384 then
- fourstackc()
- twostackc()
- elseif AmmountCopper < 449 then
- fourstackc()
- twostackc()
- onestackc()
- elseif AmmountCopper < 513 then
- fourstackc()
- fourstackc()
- elseif AmmountCopper < 577 then
- fourstackc()
- fourstackc()
- onestackc()
- elseif AmmountCopper < 641 then
- fourstackc()
- fourstackc()
- twostackc()
- elseif AmmountCopper < 705 then
- fourstackc()
- fourstackc()
- twostackc()
- onestackc()
- elseif AmmountCopper < 769 then
- fourstackc()
- fourstackc()
- fourstackc()
- elseif AmmountCopper < 833 then
- fourstackc()
- fourstackc()
- fourstackc()
- onestackc()
- elseif AmmountCopper < 897 then
- fourstackc()
- fourstackc()
- fourstackc()
- twostackc()
- elseif AmmountCopper < 961 then
- fourstackc()
- fourstackc()
- fourstackc()
- twostackc()
- onestackc()
- elseif AmmountCopper < 1025 then
- fourstackc()
- fourstackc()
- fourstackc()
- fourstackc()
- end
- end
- function dogold()
- if AmmountGold < 31 then
- print("No Gold")
- elseif AmmountGold < 32 then
- onestackg()
- elseif AmmountGold < 64 then
- onestackg()
- onestackg()
- elseif AmmountGold < 97 then
- twostackg()
- onestackg()
- elseif AmmountGold < 129 then
- twostackg()
- twostackg()
- elseif AmmountGold < 161 then
- fourstackg()
- onestackg()
- elseif AmmountGold < 193 then
- fourstackg()
- twostackg()
- elseif AmmountGold < 225 then
- fourstackg()
- twostackg()
- onestackg()
- elseif AmmountGold < 257 then
- fourstackg()
- fourstackg()
- elseif AmmountGold < 289 then
- fourstackg()
- fourstackg()
- onestackg()
- elseif AmmountGold < 321 then
- fourstackg()
- fourstackg()
- twostackg()
- elseif AmmountGold < 353 then
- fourstackg()
- fourstackg()
- twostackg()
- onestackg()
- elseif AmmountGold < 385 then
- fourstackg()
- fourstackg()
- fourstackg()
- elseif AmmountGold < 417 then
- fourstackg()
- fourstackg()
- fourstackg()
- onestackg()
- elseif AmmountGold < 449 then
- fourstackg()
- fourstackg()
- fourstackg()
- twostackg()
- elseif AmmountGold < 481 then
- fourstackg()
- fourstackg()
- fourstackg()
- twostackg()
- onestackg()
- elseif AmmountGold < 513 then
- fourstackg()
- fourstackg()
- fourstackg()
- fourstackg()
- end
- end
- function doredstone()
- if AmmountRedstone < 63 then
- print("No Redstone")
- elseif AmmountRedstone < 65 then
- onestackr()
- elseif AmmountRedstone < 129 then
- onestackr()
- onestackr()
- elseif AmmountRedstone < 193 then
- twostackr()
- onestackr()
- elseif AmmountRedstone < 257 then
- twostackr()
- twostackr()
- elseif AmmountRedstone < 321 then
- fourstackr()
- onestackr()
- elseif AmmountRedstone < 384 then
- fourstackr()
- twostackr()
- elseif AmmountRedstone < 449 then
- fourstackr()
- twostackr()
- onestackr()
- elseif AmmountRedstone < 513 then
- fourstackr()
- fourstackr()
- elseif AmmountRedstone < 577 then
- fourstackr()
- fourstackr()
- onestackr()
- elseif AmmountRedstone < 641 then
- fourstackr()
- fourstackr()
- twostackr()
- elseif AmmountRedstone < 705 then
- fourstackr()
- fourstackr()
- twostackr()
- onestackr()
- elseif AmmountRedstone < 769 then
- fourstackr()
- fourstackr()
- fourstackr()
- elseif AmmountRedstone < 833 then
- fourstackr()
- fourstackr()
- fourstackr()
- onestackr()
- elseif AmmountRedstone < 897 then
- fourstackr()
- fourstackr()
- fourstackr()
- twostackr()
- elseif AmmountRedstone < 961 then
- fourstackr()
- fourstackr()
- fourstackr()
- twostackr()
- onestackr()
- elseif AmmountRedstone < 1025 then
- fourstackr()
- fourstackr()
- fourstackr()
- fourstackr()
- end
- end
- function dotin()
- if AmmountTin < 63 then
- print("No Tin")
- elseif AmmountTin < 65 then
- onestackt()
- elseif AmmountTin < 129 then
- onestackt()
- onestackt()
- elseif AmmountTin < 193 then
- twostackt()
- onestackt()
- elseif AmmountTin < 257 then
- twostackt()
- twostackt()
- elseif AmmountTin < 321 then
- fourstackt()
- onestackt()
- elseif AmmountTin < 384 then
- fourstackt()
- twostackt()
- elseif AmmountTin < 449 then
- fourstackt()
- twostackt()
- onestackt()
- elseif AmmountTin < 513 then
- fourstackt()
- fourstackt()
- elseif AmmountTin < 577 then
- fourstackt()
- fourstackt()
- onestackt()
- elseif AmmountTin < 641 then
- fourstackt()
- fourstackt()
- twostackt()
- elseif AmmountTin < 705 then
- fourstackt()
- fourstackt()
- twostackt()
- onestackt()
- elseif AmmountTin < 769 then
- fourstackt()
- fourstackt()
- fourstackt()
- elseif AmmountTin < 833 then
- fourstackt()
- fourstackt()
- fourstackt()
- onestackt()
- elseif AmmountTin < 897 then
- fourstackt()
- fourstackt()
- fourstackt()
- twostackt()
- elseif AmmountTin < 961 then
- fourstackt()
- fourstackt()
- fourstackt()
- twostackt()
- onestackt()
- elseif AmmountTin < 1025 then
- fourstackt()
- fourstackt()
- fourstackt()
- fourstackt()
- end
- end
- function dolapis()
- if AmmountLapis < 63 then
- print("No Lapis")
- elseif AmmountLapis < 65 then
- onestackl()
- elseif AmmountLapis < 129 then
- onestackl()
- onestackl()
- elseif AmmountLapis < 193 then
- twostackl()
- onestackl()
- elseif AmmountLapis < 257 then
- twostackl()
- twostackl()
- elseif AmmountLapis < 321 then
- fourstackl()
- onestackl()
- elseif AmmountLapis < 384 then
- fourstackl()
- twostackl()
- elseif AmmountLapis < 449 then
- fourstackl()
- twostackl()
- onestackl()
- elseif AmmountLapis < 513 then
- fourstackl()
- fourstackl()
- elseif AmmountLapis < 577 then
- fourstackl()
- fourstackl()
- onestackl()
- elseif AmmountLapis < 641 then
- fourstackl()
- fourstackl()
- twostackl()
- elseif AmmountLapis < 705 then
- fourstackl()
- fourstackl()
- twostackl()
- onestackl()
- elseif AmmountLapis < 769 then
- fourstackl()
- fourstackl()
- fourstackl()
- elseif AmmountLapis < 833 then
- fourstackl()
- fourstackl()
- fourstackl()
- onestackl()
- elseif AmmountLapis < 897 then
- fourstackl()
- fourstackl()
- fourstackl()
- twostackl()
- elseif AmmountLapis < 961 then
- fourstackl()
- fourstackl()
- fourstackl()
- twostackl()
- onestackl()
- elseif AmmountLapis < 1025 then
- fourstackl()
- fourstackl()
- fourstackl()
- fourstackl()
- end
- end
- function doosmium()
- if AmmountOsmium < 63 then
- print("No Osmium")
- elseif AmmountOsmium < 65 then
- onestacko()
- elseif AmmountOsmium < 129 then
- onestacko()
- onestacko()
- elseif AmmountOsmium < 193 then
- twostacko()
- onestacko()
- elseif AmmountOsmium < 257 then
- twostacko()
- twostacko()
- elseif AmmountOsmium < 321 then
- fourstacko()
- onestacko()
- elseif AmmountOsmium < 384 then
- fourstacko()
- twostacko()
- elseif AmmountOsmium < 449 then
- fourstacko()
- twostacko()
- onestacko()
- elseif AmmountOsmium < 513 then
- fourstacko()
- fourstacko()
- elseif AmmountOsmium < 577 then
- fourstacko()
- fourstacko()
- onestacko()
- elseif AmmountOsmium < 641 then
- fourstacko()
- fourstacko()
- twostacko()
- elseif AmmountOsmium < 705 then
- fourstacko()
- fourstacko()
- twostacko()
- onestacko()
- elseif AmmountOsmium < 769 then
- fourstacko()
- fourstacko()
- fourstacko()
- elseif AmmountOsmium < 833 then
- fourstacko()
- fourstacko()
- fourstacko()
- onestacko()
- elseif AmmountOsmium < 897 then
- fourstacko()
- fourstacko()
- fourstacko()
- twostacko()
- elseif AmmountOsmium < 961 then
- fourstacko()
- fourstacko()
- fourstacko()
- twostacko()
- onestacko()
- elseif AmmountOsmium < 1025 then
- fourstacko()
- fourstacko()
- fourstacko()
- fourstacko()
- end
- end
- function dowood()
- if AmmountWood < 63 then
- print("No Wood")
- elseif AmmountWood < 65 then
- onestackw()
- elseif AmmountWood < 129 then
- onestackw()
- onestackw()
- elseif AmmountWood < 193 then
- twostackw()
- onestackw()
- elseif AmmountWood < 257 then
- twostackw()
- twostackw()
- elseif AmmountWood < 321 then
- fourstackw()
- onestackw()
- elseif AmmountWood < 384 then
- fourstackw()
- twostackw()
- elseif AmmountWood < 449 then
- fourstackw()
- twostackw()
- onestackw()
- elseif AmmountWood < 513 then
- fourstackw()
- fourstackw()
- elseif AmmountWood < 577 then
- fourstackw()
- fourstackw()
- onestackw()
- elseif AmmountWood < 641 then
- fourstackw()
- fourstackw()
- twostackw()
- elseif AmmountWood < 705 then
- fourstackw()
- fourstackw()
- twostackw()
- onestackw()
- elseif AmmountWood < 769 then
- fourstackw()
- fourstackw()
- fourstackw()
- elseif AmmountWood < 833 then
- fourstackw()
- fourstackw()
- fourstackw()
- onestackw()
- elseif AmmountWood < 897 then
- fourstackw()
- fourstackw()
- fourstackw()
- twostackw()
- elseif AmmountWood < 961 then
- fourstackw()
- fourstackw()
- fourstackw()
- twostackw()
- onestackw()
- elseif AmmountWood < 1025 then
- fourstackw()
- fourstackw()
- fourstackw()
- fourstackw()
- end
- end
- function default()
- newBal = 0
- cash = 0
- clean()
- m.clear()
- rs.setBundledOutput("right", colors.brown)
- sleep(.2)
- rs.setBundledOutput("right", 0)
- sleep(.1)
- m.setBackgroundColour((colours.black))
- top.clear()
- top.setBackgroundColour((colours.blue))
- top.setCursorPos(1,1)
- top.write("Cart Balance:")
- top.setCursorPos(27,1)
- top.write("Your balance:"..cash)
- top.setBackgroundColour((colours.black))
- m.setBackgroundColour((colours.blue))
- m.setCursorPos(63, 2)
- m.write("Purchase?")
- m.setCursorPos(65,18)
- m.write("Clear")
- m.setCursorPos(63,19)
- m.write("Cash-Back")
- m.setCursorPos(2,1)
- m.write("-3 Copper-")
- m.setCursorPos(2,2)
- m.write("Iron 64x")
- m.setCursorPos(2,4)
- m.write("Gold 32x")
- m.setCursorPos(2,6)
- m.write("Redstone 64x")
- m.setCursorPos(2,8)
- m.write("Tin 64x")
- m.setCursorPos(2,10)
- m.write("Copper 64x")
- m.setCursorPos(2,12)
- m.write("Lapis 64x")
- m.setCursorPos(2,14)
- m.write("Osmium 64x")
- m.setCursorPos(2,16)
- m.write("Diamond 8x")
- m.setCursorPos(2,18)
- m.write("Oak Log 64x")
- m.setBackgroundColour((colours.black))
- end
- top.clear()
- m.clear()
- m.setBackgroundColour((colours.blue))
- m.setCursorPos(23,9)
- m.write("Insert Cash, Press start.")
- m.setCursorPos(33,10)
- m.write("START.")
- m.setTextScale(1)
- m.setBackgroundColour((colours.black))
- function checkClickPosition()
- if mouseWidth > 64 and mouseWidth < 71 and mouseHeight == 18 then
- default()
- -- rs.setBundledOutput("right", colors.brown)
- -- sleep(.2)
- -- rs.setBundledOutput("right", 0)
- --sleep(.2)
- elseif mouseWidth > 63 and mouseWidth < 71 and mouseHeight == 2 then
- AmmountGoldMath = AmmountGold *2
- AmmountDiamondMath = AmmountDiamond * 8
- yourcostbeforefirst = AmmountDiamondMath + AmmountWood + AmmountCopper + AmmountLapis + AmmountRedstone + AmmountTin + AmmountOsmium + AmmountIron + AmmountGoldMath
- yourcostbefore = yourcostbeforefirst /3
- youcost = yourcostbefore /7
- yourcost = math.floor(youcost)
- print(youcost)
- rost = yourcost
- charge()
- m.setCursorPos(63,2)
- m.setBackgroundColour((colours.lime))
- m.write("Purchase?")
- m.setBackgroundColour((colours.blue))
- m.setCursorPos(57,3)
- m.write("Costs:"..yourcost)
- elseif rost > monitorbalance then
- m.write("You Cannot Afford.")
- doiron()
- docopper()
- dogold()
- doosmium()
- dolapis()
- dowood()
- dotin()
- doredstone()
- yourbaldude()
- elseif mouseWidth > 13 and mouseHeight < 18 and mouseHeight == 10 then
- m.setCursorPos(33,10)
- m.setBackgroundColour((colours.lime))
- m.write("START.")
- m.setBackgroundColour((colours.black))
- checkbalance()
- sleep(.2)
- m.clear()
- default()
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 2 then
- m.setCursorPos(2,2)
- m.setBackgroundColour((colours.lime))
- m.write("Iron 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- top.setCursorPos(1,2)
- AmmountIron = AmmountIron + 64
- top.write("Iron:"..AmmountIron)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 14 then
- m.setCursorPos(2,14)
- m.setBackgroundColour((colours.lime))
- m.write("Osmium 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- top.setCursorPos(17,4)
- AmmountOsmium = AmmountOsmium + 64
- top.write("Osmium:"..AmmountOsmium)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 12 then
- m.setCursorPos(2,12)
- m.setBackgroundColour((colours.lime))
- m.write("Lapis 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- AmmountLapis = AmmountLapis + 64
- top.setCursorPos(17,3)
- top.write("Lapis:"..AmmountLapis)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 10 then
- m.setCursorPos(2,10)
- m.setBackgroundColour((colours.lime))
- m.write("Copper 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- AmmountCopper = AmmountCopper + 64
- top.setCursorPos(17,2)
- top.write("Copper:"..AmmountCopper)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 8 then
- m.setCursorPos(2,8)
- m.setBackgroundColour((colours.lime))
- m.write("Tin 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- top.setCursorPos(1,5)
- AmmountTin = AmmountTin + 64
- top.write("Tin:"..AmmountTin)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 6 then
- m.setCursorPos(2,6)
- m.setBackgroundColour((colours.lime))
- m.write("Redstone 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- top.setCursorPos(1,4)
- AmmountRedstone = AmmountRedstone + 64
- top.write("Redstone:"..AmmountRedstone)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 16 then
- m.setCursorPos(2,16)
- m.setBackgroundColour((colours.lime))
- AmmountDiamond= AmmountDiamond + 8
- m.write("Diamond 8x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- top.setCursorPos(29,2)
- top.write("Diamond:"..AmmountDiamond)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 18 then
- m.setCursorPos(2,18)
- m.setBackgroundColour((colours.lime))
- AmmountWood = AmmountWood + 64
- m.write("Oak Log 64x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- m.setBackgroundColour((colours.black))
- --top.setCursorPos(1,3)
- top.setCursorPos(17,5)
- top.write("Oak Log:"..AmmountWood)
- top.setBackgroundColour((colours.black))
- elseif mouseWidth > 1 and mouseWidth < 8 and mouseHeight == 4 then
- m.setCursorPos(2,4)
- m.setBackgroundColour((colours.lime))
- AmmountGold = AmmountGold + 32
- m.write("Gold 32x")
- newBal = newBal + 3
- top.setCursorPos(14,1)
- top.write(newBal)
- --moneyN()
- m.setBackgroundColour((colours.black))
- top.setCursorPos(1,3)
- top.write("Gold:"..AmmountGold)
- top.setBackgroundColour((colours.black))
- end
- end
- repeat
- event,p1,p2,p3 = os.pullEvent()
- if event=="monitor_touch" then
- mouseWidth = p2
- mouseHeight = p3
- checkClickPosition()
- end
- until event=="char" and p1==("x")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement