Advertisement
NanoBob

(old) Terminator

Jan 6th, 2015
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.85 KB | None | 0 0
  1. glasses=peripheral.wrap("left")
  2. g=glasses
  3.  
  4. local currentPlayer=nil
  5. local guiSize="normal"
  6. local guiSizes={
  7. ["small"]={["x"]=1920,["y"]=1057},
  8. ["normal"]={["x"]=960,["y"]=540},
  9. ["large"]={["x"]=640,["y"]=353},
  10. ["auto"]={["x"]=,["y"]=},
  11. }
  12. local screenX=0
  13. local screenY=0
  14.  
  15. function setScreenSize(guiSize,x,y)
  16.     if guiSize==nil then
  17.         screenX=x
  18.         screenY=y
  19.         return true,screenX,screenY
  20.     else
  21.         screenX=guiSizes[guiSize]["x"]
  22.         screenY=guiSizes[guiSize]["y"]
  23.         return true,screenX,screenY
  24.     end
  25.     return false
  26. end
  27.  
  28. local function drawBackground()
  29.     glasses.clear()
  30.     backgroundBox=glasses.addBox(0,0,screenX,screenY,0xff0000,50)
  31.     glasses.addBox(0,0,screenX,10,0x000000,255)
  32.     glasses.addBox(0,0,0,screenY*,0x000000,255)
  33.     glasses.addBox(screenX,0,screenX,screenY*0.05,0x000000,255)
  34.     glasses.addBox(0,screenY,screenX,screenY*0.05,0x000000,255)
  35. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement