Advertisement
kirkarr

Untitled

Mar 24th, 2024 (edited)
712
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.58 KB | None | 0 0
  1. local mat = Material( "https://avatars.akamai.steamstatic.com/8ce5e58726b034567de364c8dc150c768b33d995_medium.jpg" )
  2. local text = mat:GetTexture("$basetexture")
  3. print(text)
  4. wid = text:Width()
  5. hei = text:Height()
  6. local x, y = 1, 1
  7. local last = 0
  8. hook.Add("Tick","sas",function ()
  9.     cur = CurTime()
  10.     if cur - last > 0.6 then
  11.         net.Start("pixelbattle")
  12.         net.WriteUInt(x,24)
  13.         net.WriteUInt(y,24)
  14.         net.WriteUInt(pixelbattle.encode(text:GetColor(x,y)),24)
  15.         net.SendToServer()
  16.         x = x + 1
  17.         if x > wid then
  18.             x = 0
  19.             y = y + 1
  20.         end
  21.         if y > hei then
  22.             y = 0
  23.         end
  24.     end
  25. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement