Advertisement
TheUnknownDiscord

2022

Jan 2nd, 2022
47
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. part1 = Instance.new("Part", owner.Character.Head)
  2. part1.Size = Vector3.new(7.5,7.5,0.05)
  3. part1.Anchored = true
  4. part1.CFrame = owner.Character.HumanoidRootPart.CFrame * CFrame.new(0,2.5,-5)
  5. local decal = Instance.new("Texture", part1)
  6. decal.Texture = "http://www.roblox.com/asset/?id=8435594085"
  7. decal.Face = Enum.NormalId.Front
  8. decal.Transparency = 0
  9. local Frames = 318
  10. local currentFrame = 1
  11. local rows = 11
  12. local columns = 30
  13.  
  14. local currentRow,CurrentColumn = 0,0
  15.  
  16. local linear = false
  17.  
  18. local fps = 30
  19. local full60fps = false
  20.  
  21. local size = part1.Size
  22.  
  23. decal.StudsPerTileU = columns*size.X
  24. decal.StudsPerTileV = rows*size.Y
  25.  
  26. while true do
  27. if not full60fps then wait(1/fps) else game:GetService("RunService").Stepped:Wait() end
  28. if linear then
  29. decal.OffsetStudsU = decal.OffsetStudsU + size.X
  30. if decal.OffsetStudsU > decal.StudsPerTileU then
  31. decal.OffsetStudsU = 0
  32. end
  33. else
  34. CurrentColumn = CurrentColumn + 1
  35. if CurrentColumn > columns then
  36. CurrentColumn = 1
  37. currentRow = currentRow + 1
  38. end
  39. if currentFrame > Frames then
  40. currentRow,CurrentColumn,currentFrame = 1,1,1
  41. end
  42. decal.OffsetStudsU = size.X*(CurrentColumn-1)
  43. decal.OffsetStudsV = size.Y*(currentRow-1)
  44. currentFrame = currentFrame+1
  45. end
  46. end
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement