Advertisement
dsniper

Untitled

Jun 15th, 2017
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.14 KB | None | 0 0
  1. Character = game.Players.LocalPlayer.Character
  2. Head = Character.Head
  3.  
  4. CV="Really black"
  5. p = game.Players.LocalPlayer
  6. char = p.Character
  7. local txt = Instance.new("BillboardGui", char)
  8. txt.Adornee = char .Head
  9. txt.Name = "_status"
  10. txt.Size = UDim2.new(2, 0, 1.2, 0)
  11. txt.StudsOffset = Vector3.new(-9, 8, 0)
  12. local text = Instance.new("TextLabel", txt)
  13. text.Size = UDim2.new(10, 0, 7, 0)
  14. text.FontSize = "Size24"
  15. text.TextScaled = true
  16. text.TextTransparency = 0
  17. text.BackgroundTransparency = 1
  18. text.TextTransparency = 0
  19. text.TextStrokeTransparency = 0
  20. text.Font = "Cartoon"
  21. text.TextStrokeColor3 = Color3.new(0,0,0)
  22.  
  23. v=Instance.new("Part")
  24. v.Name = "ColorBrick"
  25. v.Parent=p.Character
  26. v.FormFactor="Symmetric"
  27. v.Anchored=true
  28. v.CanCollide=false
  29. v.BottomSurface="Smooth"
  30. v.TopSurface="Smooth"
  31. v.Size=Vector3.new(10,5,3)
  32. v.Transparency=1
  33. v.CFrame=char.Torso.CFrame
  34. v.BrickColor=BrickColor.new(CV)
  35. v.Transparency=1
  36. text.TextColor3 = Color3.new(0,0,0)
  37. v.Shape="Block"
  38. text.Text = "DSniper123"
  39.  
  40. local s = Instance.new("Sound",Character)
  41. s.Name = "BGMusic"
  42. s.SoundId = "rbxassetid://396488242"
  43. s.Pitch = 1
  44. s.Volume = math.huge
  45. s.Looped = true
  46. s.archivable = false
  47. wait(0.1)
  48. s:play()
  49.  
  50.  
  51. --[[Nocturna_A._Alteriano_Night.Owl.Inc]]--
  52. --[[Edited by whenyoudiev3]]--
  53. wait(1 / 60)
  54. Effects = { }
  55. local Player = game.Players.localPlayer
  56. local Character = Player.Character
  57. local Humanoid = Character.Humanoid
  58. local mouse = Player:GetMouse()
  59. local m = Instance.new('Model', Character)
  60. m.Name = "WeaponModel"
  61. local LeftArm = Character["Left Arm"]
  62. local RightArm = Character["Right Arm"]
  63. local LeftLeg = Character["Left Leg"]
  64. local RightLeg = Character["Right Leg"]
  65. local Head = Character.Head
  66. local Torso = Character.Torso
  67. local cam = game.Workspace.CurrentCamera
  68. local RootPart = Character.HumanoidRootPart
  69. local RootJoint = RootPart.RootJoint
  70. local equipped = false
  71. local attack = false
  72. local Anim = 'Idle'
  73. local idle = 0
  74. local attacktype = 1
  75. local Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude
  76. local velocity = RootPart.Velocity.y
  77. local sine = 0
  78. local change = 1
  79. local grabbed = false
  80. local cn = CFrame.new
  81. local mr = math.rad
  82. local angles = CFrame.Angles
  83. local ud = UDim2.new
  84. local c3 = Color3.new
  85. Instance.new("ForceField", game.Players.LocalPlayer.Character)
  86.  
  87. Humanoid.Animator.Parent = nil
  88. Character.Animate.Parent = nil
  89.  
  90. local newMotor = function(part0, part1, c0, c1)
  91. local w = Instance.new('Motor', part0)
  92. w.Part0 = part0
  93. w.Part1 = part1
  94. w.C0 = c0
  95. w.C1 = c1
  96. return w
  97. end
  98.  
  99. function clerp(a, b, t)
  100. return a:lerp(b, t)
  101. end
  102.  
  103. RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  104. NeckCF = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  105.  
  106. local RW = newMotor(Torso, RightArm, CFrame.new(1.5, 0, 0), CFrame.new(0, 0, 0))
  107. local LW = newMotor(Torso, LeftArm, CFrame.new(-1.5, 0, 0), CFrame.new(0, 0, 0))
  108. local RH = newMotor(Torso, RightLeg, CFrame.new(.5, -2, 0), CFrame.new(0, 0, 0))
  109. local LH = newMotor(Torso, LeftLeg, CFrame.new(-.5, -2, 0), CFrame.new(0, 0, 0))
  110. RootJoint.C1 = CFrame.new(0, 0, 0)
  111. RootJoint.C0 = CFrame.new(0, 0, 0)
  112. Torso.Neck.C1 = CFrame.new(0, 0, 0)
  113. Torso.Neck.C0 = CFrame.new(0, 1.5, 0)
  114.  
  115. local rarmc1 = RW.C1
  116. local larmc1 = LW.C1
  117. local rlegc1 = RH.C1
  118. local llegc1 = LH.C1
  119.  
  120. local resetc1 = false
  121.  
  122. function PlayAnimationFromTable(table, speed, bool)
  123. RootJoint.C0 = clerp(RootJoint.C0, table[1], speed)
  124. Torso.Neck.C0 = clerp(Torso.Neck.C0, table[2], speed)
  125. RW.C0 = clerp(RW.C0, table[3], speed)
  126. LW.C0 = clerp(LW.C0, table[4], speed)
  127. RH.C0 = clerp(RH.C0, table[5], speed)
  128. LH.C0 = clerp(LH.C0, table[6], speed)
  129. if bool == true then
  130. if resetc1 == false then
  131. resetc1 = true
  132. RootJoint.C1 = RootJoint.C1
  133. Torso.Neck.C1 = Torso.Neck.C1
  134. RW.C1 = rarmc1
  135. LW.C1 = larmc1
  136. RH.C1 = rlegc1
  137. LH.C1 = llegc1
  138. end
  139. end
  140. end
  141.  
  142. Char = char
  143.  
  144. --[[Credits to SazErenos for his Artificial Heartbeat]]--
  145.  
  146. ArtificialHB = Instance.new("BindableEvent", script)
  147. ArtificialHB.Name = "Heartbeat"
  148.  
  149. script:WaitForChild("Heartbeat")
  150.  
  151. frame = 1 / 30
  152. tf = 0
  153. allowframeloss = false
  154. tossremainder = false
  155. lastframe = tick()
  156. script.Heartbeat:Fire()
  157.  
  158. game:GetService("RunService").Heartbeat:connect(function(s, p)
  159. tf = tf + s
  160. if tf >= frame then
  161. if allowframeloss then
  162. script.Heartbeat:Fire()
  163. lastframe = tick()
  164. else
  165. for i = 1, math.floor(tf / frame) do
  166. script.Heartbeat:Fire()
  167. end
  168. lastframe = tick()
  169. end
  170. if tossremainder then
  171. tf = 0
  172. else
  173. tf = tf - frame * math.floor(tf / frame)
  174. end
  175. end
  176. end)
  177.  
  178. function swait(num)
  179. if num == 0 or num == nil then
  180. ArtificialHB.Event:wait()
  181. else
  182. for i = 0, num do
  183. ArtificialHB.Event:wait()
  184. end
  185. end
  186. end
  187.  
  188. local RbxUtility = LoadLibrary("RbxUtility")
  189. local Create = RbxUtility.Create
  190.  
  191. function RemoveOutlines(part)
  192. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  193. end
  194.  
  195. CFuncs = {
  196. ["Part"] = {
  197. Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  198. local Part = Create("Part"){
  199. Parent = Parent,
  200. Reflectance = Reflectance,
  201. Transparency = Transparency,
  202. CanCollide = false,
  203. Locked = true,
  204. BrickColor = BrickColor.new(tostring(BColor)),
  205. Name = Name,
  206. Size = Size,
  207. Material = Material,
  208. }
  209. RemoveOutlines(Part)
  210. return Part
  211. end;
  212. };
  213.  
  214. ["Mesh"] = {
  215. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  216. local Msh = Create(Mesh){
  217. Parent = Part,
  218. Offset = OffSet,
  219. Scale = Scale,
  220. }
  221. if Mesh == "SpecialMesh" then
  222. Msh.MeshType = MeshType
  223. Msh.MeshId = MeshId
  224. end
  225. return Msh
  226. end;
  227. };
  228.  
  229. ["Mesh"] = {
  230. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  231. local Msh = Create(Mesh){
  232. Parent = Part,
  233. Offset = OffSet,
  234. Scale = Scale,
  235. }
  236. if Mesh == "SpecialMesh" then
  237. Msh.MeshType = MeshType
  238. Msh.MeshId = MeshId
  239. end
  240. return Msh
  241. end;
  242. };
  243.  
  244. ["Weld"] = {
  245. Create = function(Parent, Part0, Part1, C0, C1)
  246. local Weld = Create("Weld"){
  247. Parent = Parent,
  248. Part0 = Part0,
  249. Part1 = Part1,
  250. C0 = C0,
  251. C1 = C1,
  252. }
  253. return Weld
  254. end;
  255. };
  256.  
  257. ["Sound"] = {
  258. Create = function(id, par, vol, pit)
  259. coroutine.resume(coroutine.create(function()
  260. local S = Create("Sound"){
  261. Volume = vol,
  262. Pitch = pit or 1,
  263. SoundId = id,
  264. Parent = par or workspace,
  265. }
  266. Instance.new("DistortionSoundEffect", S).Level = 1
  267. wait()
  268. S:play()
  269. game:GetService("Debris"):AddItem(S, 10)
  270. end))
  271. end;
  272. };
  273.  
  274. ["ParticleEmitter"] = {
  275. Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread)
  276. local fp = Create("ParticleEmitter"){
  277. Parent = Parent,
  278. Color = ColorSequence.new(Color1, Color2),
  279. LightEmission = LightEmission,
  280. Size = Size,
  281. Texture = Texture,
  282. Transparency = Transparency,
  283. ZOffset = ZOffset,
  284. Acceleration = Accel,
  285. Drag = Drag,
  286. LockedToPart = LockedToPart,
  287. VelocityInheritance = VelocityInheritance,
  288. EmissionDirection = EmissionDirection,
  289. Enabled = Enabled,
  290. Lifetime = LifeTime,
  291. Rate = Rate,
  292. Rotation = Rotation,
  293. RotSpeed = RotSpeed,
  294. Speed = Speed,
  295. VelocitySpread = VelocitySpread,
  296. }
  297. return fp
  298. end;
  299. };
  300. }
  301.  
  302. function rayCast(Position, Direction, Range, Ignore)
  303. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  304. end
  305.  
  306. local function GetNearest(obj, distance)
  307. local last, lastx = distance + 1
  308. for i, v in pairs(workspace:GetChildren()) do
  309. if v:IsA'Model' and v ~= Character and v:findFirstChild('Humanoid') and v:findFirstChild('Torso') and v:findFirstChild('Humanoid').Health > 0 then
  310. local t = v.Torso
  311. local dist = (t.Position - obj.Position).magnitude
  312. if dist <= distance then
  313. if dist < last then
  314. last = dist
  315. lastx = v
  316. end
  317. end
  318. end
  319. end
  320. return lastx
  321. end
  322.  
  323. --[[ Credits to Kert109 (Ninja_Deer) for the Damage function. Fenrier for the Magnitude Damage ]]--
  324.  
  325. function Damage(hit, damage, cooldown, Color1, Color2, HSound, HPitch)
  326. for i, v in pairs(hit:GetChildren()) do
  327. if v:IsA("Humanoid") and hit.Name ~= Character.Name then
  328. local find = v:FindFirstChild("DebounceHit")
  329. if not find then
  330. if v.Parent:findFirstChild("Head") then
  331. local BillG = Create("BillboardGui"){
  332. Parent = v.Parent.Head,
  333. Size = UDim2.new(1, 0, 1, 0),
  334. Adornee = v.Parent.Head,
  335. StudsOffset = Vector3.new(math.random(-3, 3), math.random(3, 5), math.random(-3, 3)),
  336. }
  337. local TL = Create("TextLabel"){
  338. Parent = BillG,
  339. Size = UDim2.new(3, 3, 3, 3),
  340. BackgroundTransparency = 1,
  341. Text = tostring(damage).."-",
  342. TextColor3 = Color1.Color,
  343. TextStrokeColor3 = Color2.Color,
  344. TextStrokeTransparency = 0,
  345. TextXAlignment = Enum.TextXAlignment.Center,
  346. TextYAlignment = Enum.TextYAlignment.Center,
  347. FontSize = Enum.FontSize.Size18,
  348. Font = "ArialBold",
  349. }
  350. coroutine.resume(coroutine.create(function()
  351. swait(1)
  352. for i = 0, 1, .1 do
  353. swait(.1)
  354. BillG.StudsOffset = BillG.StudsOffset + Vector3.new(0, .1, 0)
  355. end
  356. BillG:Destroy()
  357. end))
  358. end
  359. v.Health = v.Health - damage
  360. local bool = Create("BoolValue"){
  361. Parent = v,
  362. Name = "DebounceHit",
  363. }
  364. if HSound ~= nil and HPitch ~= nil then
  365. CFuncs["Sound"].Create(HSound, hit, 1, HPitch)
  366. end
  367. game:GetService("Debris"):AddItem(bool, cooldown)
  368. end
  369. end
  370. end
  371. end
  372.  
  373. function MagnitudeDamage(Part, magni, mindam, maxdam, Color1, Color2, HSound, HPitch)
  374. for _, c in pairs(workspace:children()) do
  375. local hum = c:findFirstChild("Humanoid")
  376. if hum ~= nil then
  377. local head = c:findFirstChild("Torso")
  378. if head ~= nil then
  379. local targ = head.Position - Part.Position
  380. local mag = targ.magnitude
  381. if mag <= magni and c.Name ~= Playe…
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement