Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local component = require("component")
- local gear =
- {
- {0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0},
- {0, 0, 1, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 1, 0, 0},
- {0, 1, 2, 2, 1, 1, 1, 2, 2, 1, 1, 1, 2 ,2, 1, 0},
- {0, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 0},
- {0, 0, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 0, 0},
- {0, 0, 1, 2, 2, 2, 1, 1, 1, 1, 2, 2, 2, 1, 0, 0},
- {1, 1, 1, 2, 2, 1, 0, 0, 0, 0, 1, 2, 2, 1, 1, 1},
- {1, 2, 2, 2, 2, 1, 0, 0, 0, 0, 1, 2, 2, 2, 2, 1},
- {1, 2, 2, 2, 2, 1, 0, 0, 0, 0, 1, 2, 2, 2, 2, 1},
- {1, 1, 1, 2, 2, 1, 0, 0, 0, 0, 1, 2, 2, 1, 1, 1},
- {0, 0, 1, 2, 2, 2, 1, 1, 1, 1, 2, 2, 2, 1, 0, 0},
- {0, 0, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 0, 0},
- {0, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 0},
- {0, 1, 2, 2, 1, 1, 1, 2, 2, 1, 1, 1, 2 ,2, 1, 0},
- {0, 0, 1, 1, 0, 0, 1, 2, 2, 1, 0, 0, 1, 1, 0, 0},
- {0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0}
- }
- local moustache =
- {
- {3, 0, 0, 3, 3, 0, 0, 3},
- {3, 3, 3, 3, 3, 3, 3, 3},
- {0, 3, 3, 0, 0, 3, 3, 0}
- }
- function initHolo(holo)
- holo.clear()
- holo.setPaletteColor(1, 0x808080)
- holo.setPaletteColor(2, 0xD9D9D9)
- holo.setPaletteColor(3, 0xFFFFFF)
- end
- function printGear(holo, z)
- for x=1,16 do
- for y=1,16 do
- if(not (gear[x][y] == 0)) then
- holo.set(16 + x, 8 + y, z, gear[x][y])
- end
- end
- end
- end
- function printMoustache(holo, z)
- for x=1,8 do
- for y=1,3 do
- if(not (moustache[y][x] == 0)) then
- holo.set(20 + x, 18 + 3 - y, z, moustache[y][x])
- end
- end
- end
- end
- for address, primary in component.list()
- do
- if (primary == "hologram") then
- local hologram = component.proxy(address)
- initHolo(hologram)
- printGear(hologram, 23)
- printGear(hologram, 24)
- printMoustache(hologram, 25)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment