AlphaSploit

Clock

Mar 3rd, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.58 KB | None | 0 0
  1. script.Parent = nil
  2. text = "hours:mins:secs"
  3. main = Vector3.new(-10,1.7,40)
  4.  
  5. sec = nil
  6. min = nil
  7. ho = nil
  8. mod = nil
  9.  
  10. function makeclock()
  11. for _,v in pairs(workspace:children()) do if v.Name == "xSclock" then v:remove() end end
  12. local m = Instance.new("Model",workspace)
  13. m.Name = "xSclock"
  14. local o = 5
  15. local humbug = 5
  16. for i=0,354,6 do
  17. local p = Instance.new("Part",m)
  18. p.formFactor = "Custom"
  19. p.TopSurface = "Smooth"
  20. Instance.new("BlockMesh",p)
  21. if o >= 5 then
  22. p.Size = Vector3.new(0.9,1,2.6)
  23. p.BrickColor = BrickColor.new("Institutional white")
  24. o = 0
  25. else
  26. p.Size = Vector3.new(0.5,0.8,0.8)
  27. end
  28. if humbug == 5 then
  29. p.Size = Vector3.new(1,1,4.5)
  30. p.BrickColor = BrickColor.new("New Yeller")
  31. local bil = Instance.new("BillboardGui",p)
  32. bil.Adornee = p
  33. bil.Size = UDim2.new(0,200,0,200)
  34. local tx = Instance.new("TextLabel",bil)
  35. tx.BackgroundTransparency = 1
  36. tx.Size = bil.Size
  37. tx.Position = UDim2.new(0,0,0,-80)
  38. tx.TextWrap = true
  39. tx.TextColor3 = Color3.new(1,1,0)
  40. tx.FontSize = "Size24"
  41. coroutine.resume(coroutine.create(function()
  42. while m.Parent ~= nil do
  43. wait(0.1)
  44. local tim = time()
  45. local hours = math.floor((tim/60)/60 % 24)
  46. local mins = math.floor(tim/60 % 60)
  47. local secs = math.floor(tim % 60)
  48. if hours < 10 then hours = "0"..hours end
  49. if mins < 10 then mins = "0"..mins end
  50. if secs < 10 then secs = "0"..secs end
  51. local t = text:gsub("hours", hours)
  52. local te = t:gsub("mins", mins)
  53. local tex = te:gsub("secs", secs)
  54. tx.Text = tex
  55. end
  56. end))
  57. humbug = 0
  58. end
  59. p.Anchored = true
  60. p.CFrame = CFrame.new(main) * CFrame.Angles(0,math.rad(i),0) * CFrame.new(0,0,-15)
  61. o = o + 1
  62. end
  63.  
  64. local se = Instance.new("Part",m)
  65. se.formFactor = "Custom"
  66. se.Size = Vector3.new(0.8,0.8,14)
  67. se.Anchored = true
  68. se.BrickColor = BrickColor.new("Bright red")
  69. se.CFrame = CFrame.new(main) * CFrame.new(0,0,-se.Size.Z/2)
  70. Instance.new("BlockMesh",se)
  71. local mi = Instance.new("Part",m)
  72. mi.formFactor = "Custom"
  73. mi.Size = Vector3.new(0.8,0.8,15)
  74. mi.BrickColor = BrickColor.new("Dark green")
  75. mi.Anchored = true
  76. mi.CFrame = CFrame.new(main) * CFrame.new(0,0,-mi.Size.Z/2)
  77. Instance.new("BlockMesh",mi)
  78. local h = Instance.new("Part",m)
  79. h.formFactor = "Custom"
  80. h.Size = Vector3.new(0.6,0.6,11)
  81. h.BrickColor = BrickColor.new("White")
  82. h.Anchored = true
  83. h.CFrame = CFrame.new(main) * CFrame.new(0,0,-h.Size.Z/2)
  84. Instance.new("BlockMesh",h)
  85. sec = se
  86. min = mi
  87. ho = h
  88. mod = m
  89. local huh = Instance.new("Part",m)
  90. huh.Size = Vector3.new(34,1,34)
  91. huh.Anchored = true
  92. huh.CFrame = CFrame.new(main) * CFrame.new(0,-0.4,0)
  93. huh.BrickColor = BrickColor.new("Black")
  94. Instance.new("CylinderMesh",huh)
  95. local mmm = huh:clone()
  96. mmm.Parent = m
  97. mmm.Size = Vector3.new(2,1,2)
  98. mmm.CFrame = CFrame.new(main)
  99. mmm.BrickColor = BrickColor.new("Really black")
  100. local able = true
  101. local function change(pr)
  102. if pr == "Parent" and able then
  103. able = false
  104. for _,v in pairs(workspace:children()) do if v.Name == "xSclock" then v:remove() end end
  105. makeclock()
  106. end
  107. end
  108. for _,v in pairs(mod:children()) do v.Changed:connect(change) end
  109. mod.Changed:connect(change)
  110. end
  111.  
  112. makeclock()
  113.  
  114. while true do
  115. pcall(function()
  116. local ti = time()
  117. local angs = CFrame.Angles(0,math.rad(-ti*6),0)
  118. local angm = CFrame.Angles(0,math.rad(-(ti*6)/60),0)
  119. local angh = CFrame.Angles(0,math.rad(-((ti*6)/60))/12,0)
  120. sec.CFrame = CFrame.new(main) * angs * CFrame.new(0,0,-sec.Size.Z/2)
  121. min.CFrame = CFrame.new(main) * angm * CFrame.new(0,0,-min.Size.Z/2)
  122. ho.CFrame = CFrame.new(main) * angh * CFrame.new(0,0,-ho.Size.Z/2)
  123. end)
  124. wait(0.1)
  125. end
Add Comment
Please, Sign In to add comment