Advertisement
lafur

Untitled

Mar 31st, 2019
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,game,owner = owner,game
  4. local RealPlayer = Player
  5. do print("FE Compatibility code V2 by Mokiros")local RealPlayer=RealPlayer;script.Parent=RealPlayer.Character;local a=function(b)b[1].f[b[2]]=nil end;local c={__index={disconnect=a,Disconnect=a}}local d={__index={Connect=function(b,e)local f=tostring(math.random(0,10000))while b.f[f]do f=tostring(math.random(0,10000))end;b.f[f]=e;return setmetatable({b,f},c)end}}d.__index.connect=d.__index.Connect;local function g()return setmetatable({f={}},d)end;local h={Hit=CFrame.new(),KeyUp=g(),KeyDown=g(),Button1Up=g(),Button1Down=g(),Button2Up=g(),Button2Down=g()}h.keyUp=h.KeyUp;h.keyDown=h.KeyDown;local i={InputBegan=g(),InputEnded=g()}local CAS={Actions={},BindAction=function(self,j,k,l,...)CAS.Actions[j]=k and{Name=j,Function=k,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function m(self,n,...)for o,e in pairs(self[n].f)do e(...)end end;h.T=m;i.T=m;local p=Instance.new("RemoteEvent")p.Name="UserInput_Event"p.OnServerEvent:Connect(function(q,r)if q~=RealPlayer then return end;h.Target=r.e;h.Hit=r.d;if not r.f then local s=r.c==Enum.UserInputState.Begin;if r.b==Enum.UserInputType.MouseButton1 then return h:T(s and"Button1Down"or"Button1Up")end;if r.b==Enum.UserInputType.MouseButton2 then return h:T(s and"Button2Down"or"Button2Up")end;for o,t in pairs(CAS.Actions)do for o,u in pairs(t.Keys)do if u==r.a then t.Function(t.Name,r.c,r)end end end;h:T(s and"KeyDown"or"KeyUp",r.a.Name:lower())i:T(s and"InputBegan"or"InputEnded",r,false)end end)p.Parent=NLS([==[local a=script:WaitForChild("UserInput_Event")local b=owner:GetMouse()local c=game:GetService("UserInputService")local d=function(e,f)if f then return end;a:FireServer({a=e.KeyCode,b=e.UserInputType,c=e.UserInputState,d=b.Hit,e=b.Target})end;c.InputBegan:Connect(d)c.InputEnded:Connect(d)local g,h;local i=game:GetService("RunService").Heartbeat;while true do if g~=b.Hit or h~=b.Target then g,h=b.Hit,b.Target;a:FireServer({f=1,Target=h,d=g})end;for j=1,2 do i:Wait()end end]==],script)local v=game;local w={__index=function(self,u)local x=rawget(self,"_RealService")if x then return typeof(x[u])=="function"and function(o,...)return x[u](x,...)end or x[u]end end,__newindex=function(self,u,y)local x=rawget(self,"_RealService")if x then x[u]=y end end}local function z(t,A)t._RealService=typeof(A)=="string"and v:GetService(A)or A;return setmetatable(t,w)end;local B={GetService=function(self,x)return rawget(self,x)or v:GetService(x)end,Players=z({LocalPlayer=z({GetMouse=function(self)return h end},Player)},"Players"),UserInputService=z(i,"UserInputService"),ContextActionService=z(CAS,"ContextActionService"),RunService=z({_btrs={},RenderStepped=v:GetService("RunService").Heartbeat,BindToRenderStep=function(self,j,o,k)self._btrs[j]=self.Heartbeat:Connect(k)end,UnbindFromRenderStep=function(self,j)self._btrs[j]:Disconnect()end},"RunService")}rawset(B.Players,"localPlayer",B.Players.LocalPlayer)B.service=B.GetService;z(B,game)game,owner=B,B.Players.LocalPlayer end --[[ A script By makhail07
  6.  
  7.  
  8. Discord demitasse#2958
  9.  
  10. Description:Just,Just......Why?
  11.  
  12. Also Join Our Discord Server :D discord.gg/fhhzeNq
  13. ]]--
  14.  
  15. local IDs = {340106355,927529620,876981900,840433326}
  16.  
  17. function swait(num)
  18. if num==0 or num==nil then
  19. game:service'RunService'.Stepped:wait(0)
  20. else
  21. for i=0,num do
  22. game:service'RunService'.Stepped:wait(0)
  23. end
  24. end
  25. end
  26. function thread(f)
  27. coroutine.resume(coroutine.create(f))
  28. end
  29. function clerp(a, b, t)
  30. local qa = {
  31. QuaternionFromCFrame(a)
  32. }
  33. local qb = {
  34. QuaternionFromCFrame(b)
  35. }
  36. local ax, ay, az = a.x, a.y, a.z
  37. local bx, by, bz = b.x, b.y, b.z
  38. local _t = 1 - t
  39. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  40. end
  41. function QuaternionFromCFrame(cf)
  42. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  43. local trace = m00 + m11 + m22
  44. if trace > 0 then
  45. local s = math.sqrt(1 + trace)
  46. local recip = 0.5 / s
  47. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  48. else
  49. local i = 0
  50. if m00 < m11 then
  51. i = 1
  52. end
  53. if m22 > (i == 0 and m00 or m11) then
  54. i = 2
  55. end
  56. if i == 0 then
  57. local s = math.sqrt(m00 - m11 - m22 + 1)
  58. local recip = 0.5 / s
  59. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  60. elseif i == 1 then
  61. local s = math.sqrt(m11 - m22 - m00 + 1)
  62. local recip = 0.5 / s
  63. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  64. elseif i == 2 then
  65. local s = math.sqrt(m22 - m00 - m11 + 1)
  66. local recip = 0.5 / s
  67. return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  68. end
  69. end
  70. end
  71. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  72. local xs, ys, zs = x + x, y + y, z + z
  73. local wx, wy, wz = w * xs, w * ys, w * zs
  74. local xx = x * xs
  75. local xy = x * ys
  76. local xz = x * zs
  77. local yy = y * ys
  78. local yz = y * zs
  79. local zz = z * zs
  80. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  81. end
  82. function QuaternionSlerp(a, b, t)
  83. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  84. local startInterp, finishInterp
  85. if cosTheta >= 1.0E-4 then
  86. if 1 - cosTheta > 1.0E-4 then
  87. local theta = math.acos(cosTheta)
  88. local invSinTheta = 1 / math.sin(theta)
  89. startInterp = math.sin((1 - t) * theta) * invSinTheta
  90. finishInterp = math.sin(t * theta) * invSinTheta
  91. else
  92. startInterp = 1 - t
  93. finishInterp = t
  94. end
  95. elseif 1 + cosTheta > 1.0E-4 then
  96. local theta = math.acos(-cosTheta)
  97. local invSinTheta = 1 / math.sin(theta)
  98. startInterp = math.sin((t - 1) * theta) * invSinTheta
  99. finishInterp = math.sin(t * theta) * invSinTheta
  100. else
  101. startInterp = t - 1
  102. finishInterp = t
  103. end
  104. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  105. end
  106. function rayCast(Position, Direction, Range, Ignore)
  107. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  108. end
  109. --Wait what okay
  110. wait()
  111. local plr = game:service'Players'.LocalPlayer
  112. local char = plr.Character
  113. local hum = char.Humanoid
  114. local ra = char["Right Arm"]
  115. local la= char["Left Arm"]
  116. local rl= char["Right Leg"]
  117. local ll = char["Left Leg"]
  118. local hed = char.Head
  119. local root = char.HumanoidRootPart
  120. local rootj = root.RootJoint
  121. local tors = char.Torso
  122. local mouse = plr:GetMouse()
  123. local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  124. local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0)
  125. local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0)
  126. local maincolor = BrickColor.new("Magenta")
  127. cf = CFrame.new
  128. angles = CFrame.Angles
  129. attack = false
  130. euler=CFrame.fromEulerAnglesXYZ
  131. equipped = false
  132. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  133. RSH, LSH = nil, nil
  134. RW = Instance.new("Weld")
  135. LW = Instance.new("Weld")
  136. RH = tors["Right Hip"]
  137. LH = tors["Left Hip"]
  138. RSH = tors["Right Shoulder"]
  139. LSH = tors["Left Shoulder"]
  140. RSH.Parent = nil
  141. LSH.Parent = nil
  142. RW.Name = "RW"
  143. RW.Part0 = tors
  144. RW.C0 = CFrame.new(1.5, 0.5, 0)
  145. RW.C1 = CFrame.new(0, 0.5, 0)
  146. RW.Part1 = ra
  147. RW.Parent = tors
  148. LW.Name = "LW"
  149. LW.Part0 = tors
  150. LW.C0 = CFrame.new(-1.5, 0.5, 0)
  151. LW.C1 = CFrame.new(0, 0.5, 0)
  152. LW.Part1 = la
  153. LW.Parent = tors
  154. print('User is '..plr.Name)
  155. Effects = {}
  156.  
  157. ArtificialHB = Instance.new("BindableEvent", script)
  158. ArtificialHB.Name = "Heartbeat"
  159.  
  160. script:WaitForChild("Heartbeat")
  161.  
  162. frame = 1 / 60
  163. tf = 0
  164. allowframeloss = false
  165. tossremainder = false
  166. lastframe = tick()
  167. script.Heartbeat:Fire()
  168.  
  169. game:GetService("RunService").Heartbeat:connect(function(s, p)
  170. tf = tf + s
  171. if tf >= frame then
  172. if allowframeloss then
  173. script.Heartbeat:Fire()
  174. lastframe = tick()
  175. else
  176. for i = 1, math.floor(tf / frame) do
  177. script.Heartbeat:Fire()
  178. end
  179. lastframe = tick()
  180. end
  181. if tossremainder then
  182. tf = 0
  183. else
  184. tf = tf - frame * math.floor(tf / frame)
  185. end
  186. end
  187. end)
  188. local RbxUtility = LoadLibrary("RbxUtility")
  189. local Create = RbxUtility.Create
  190.  
  191. function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch)
  192. if hit.Parent == nil then
  193. return
  194. end
  195. local h = hit.Parent:FindFirstChildOfClass("Humanoid")
  196. for _, v in pairs(hit.Parent:children()) do
  197. if v:IsA("Humanoid") then
  198. h = v
  199. end
  200. end
  201. if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("UpperTorso") ~= nil then
  202. warn'No R15 allowed'
  203. hit.Parent:FindFirstChild("Head"):BreakJoints()
  204. end
  205.  
  206. if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
  207. if hit.Parent:findFirstChild("DebounceHit") ~= nil then
  208. if hit.Parent.DebounceHit.Value == true then
  209. return
  210. end
  211. end
  212. if insta == true then
  213. hit.Parent:FindFirstChild("Head"):BreakJoints()
  214. end
  215. local c = Create("ObjectValue"){
  216. Name = "creator",
  217. Value = game:service("Players").LocalPlayer,
  218. Parent = h,
  219. }
  220. game:GetService("Debris"):AddItem(c, .5)
  221. if HitSound ~= nil and HitPitch ~= nil then
  222. CFuncs.Sound.Create(HitSound, hit, 1, HitPitch)
  223. end
  224. local Damage = math.random(minim, maxim)
  225. local blocked = false
  226. local block = hit.Parent:findFirstChild("Block")
  227. if block ~= nil then
  228. if block.className == "IntValue" then
  229. if block.Value > 0 then
  230. blocked = true
  231. block.Value = block.Value - 1
  232. print(block.Value)
  233. end
  234. end
  235. end
  236. if blocked == false then
  237. h.Health = h.Health - Damage
  238. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color)
  239. else
  240. h.Health = h.Health - (Damage / 2)
  241. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color)
  242. end
  243. if Type == "Knockdown" then
  244. local hum = hit.Parent.Humanoid
  245. hum.PlatformStand = true
  246. coroutine.resume(coroutine.create(function(HHumanoid)
  247. swait(1)
  248. HHumanoid.PlatformStand = false
  249. end), hum)
  250. local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit
  251. local bodvol = Create("BodyVelocity"){
  252. velocity = angle * knockback,
  253. P = 5000,
  254. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  255. Parent = hit,
  256. }
  257. local rl = Create("BodyAngularVelocity"){
  258. P = 3000,
  259. maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
  260. angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
  261. Parent = hit,
  262. }
  263. game:GetService("Debris"):AddItem(bodvol, .5)
  264. game:GetService("Debris"):AddItem(rl, .5)
  265. elseif Type == "Normal" then
  266. local vp = Create("BodyVelocity"){
  267. P = 500,
  268. maxForce = Vector3.new(math.huge, 0, math.huge),
  269. velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05,
  270. }
  271. if knockback > 0 then
  272. vp.Parent = hit.Parent.Torso
  273. end
  274. game:GetService("Debris"):AddItem(vp, .5)
  275. elseif Type == "Up" then
  276. local bodyVelocity = Create("BodyVelocity"){
  277. velocity = Vector3.new(0, 20, 0),
  278. P = 5000,
  279. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  280. Parent = hit,
  281. }
  282. game:GetService("Debris"):AddItem(bodyVelocity, .5)
  283. elseif Type == "DarkUp" then
  284. coroutine.resume(coroutine.create(function()
  285. for i = 0, 1, 0.1 do
  286. swait()
  287. Effects.Block.Create(BrickColor.new("Black"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1)
  288. end
  289. end))
  290. local bodyVelocity = Create("BodyVelocity"){
  291. velocity = Vector3.new(0, 20, 0),
  292. P = 5000,
  293. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  294. Parent = hit,
  295. }
  296. game:GetService("Debris"):AddItem(bodyVelocity, 1)
  297. elseif Type == "Snare" then
  298. local bp = Create("BodyPosition"){
  299. P = 2000,
  300. D = 100,
  301. maxForce = Vector3.new(math.huge, math.huge, math.huge),
  302. position = hit.Parent.Torso.Position,
  303. Parent = hit.Parent.Torso,
  304. }
  305. game:GetService("Debris"):AddItem(bp, 1)
  306. elseif Type == "Freeze" then
  307. local BodPos = Create("BodyPosition"){
  308. P = 50000,
  309. D = 1000,
  310. maxForce = Vector3.new(math.huge, math.huge, math.huge),
  311. position = hit.Parent.Torso.Position,
  312. Parent = hit.Parent.Torso,
  313. }
  314. local BodGy = Create("BodyGyro") {
  315. maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge ,
  316. P = 20e+003,
  317. Parent = hit.Parent.Torso,
  318. cframe = hit.Parent.Torso.CFrame,
  319. }
  320. hit.Parent.Torso.Anchored = true
  321. coroutine.resume(coroutine.create(function(Part)
  322. swait(1.5)
  323. Part.Anchored = false
  324. end), hit.Parent.Torso)
  325. game:GetService("Debris"):AddItem(BodPos, 3)
  326. game:GetService("Debris"):AddItem(BodGy, 3)
  327. end
  328. local debounce = Create("BoolValue"){
  329. Name = "DebounceHit",
  330. Parent = hit.Parent,
  331. Value = true,
  332. }
  333. game:GetService("Debris"):AddItem(debounce, Delay)
  334. c = Create("ObjectValue"){
  335. Name = "creator",
  336. Value = Player,
  337. Parent = h,
  338. }
  339. game:GetService("Debris"):AddItem(c, .5)
  340. end
  341. end
  342.  
  343. function ShowDamage(Pos, Text, Time, Color)
  344. local Rate = (1 / 30)
  345. local Pos = (Pos or Vector3.new(0, 0, 0))
  346. local Text = (Text or "")
  347. local Time = (Time or 2)
  348. local Color = (Color or Color3.new(1, 0, 1))
  349. local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0))
  350. EffectPart.Anchored = true
  351. local BillboardGui = Create("BillboardGui"){
  352. Size = UDim2.new(3, 0, 3, 0),
  353. Adornee = EffectPart,
  354. Parent = EffectPart,
  355. }
  356. local TextLabel = Create("TextLabel"){
  357. BackgroundTransparency = 1,
  358. Size = UDim2.new(1, 0, 1, 0),
  359. Text = Text,
  360. Font = "Highway",
  361. TextColor3 = Color,
  362. TextScaled = true,
  363. Parent = BillboardGui,
  364. }
  365. game.Debris:AddItem(EffectPart, (Time))
  366. EffectPart.Parent = game:GetService("Workspace")
  367. delay(0, function()
  368. local Frames = (Time / Rate)
  369. for Frame = 1, Frames do
  370. wait(Rate)
  371. local Percent = (Frame / Frames)
  372. EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0)
  373. TextLabel.TextTransparency = Percent
  374. end
  375. if EffectPart and EffectPart.Parent then
  376. EffectPart:Destroy()
  377. end
  378. end)
  379. end
  380. function MagnitudeDamage(Part, Magnitude, MinimumDamage, MaximumDamage, KnockBack, Type, HitSound, HitPitch)
  381. for _, c in pairs(workspace:children()) do
  382. local hum = c:findFirstChild("Humanoid")
  383. if hum ~= nil then
  384. local head = c:findFirstChild("Torso") or c:findFirstChild("UpperTorso") or c:FindFirstChild('LowerTorso')
  385. if head ~= nil then
  386. local targ = head.Position - Part.Position
  387. local mag = targ.magnitude
  388. if mag <= Magnitude and c.Name ~= plr.Name then
  389. Damage(head, head, MinimumDamage, MaximumDamage, KnockBack, Type, root, .1, "rbxassetid://" .. HitSound, HitPitch)
  390. end
  391. end
  392. end
  393. end
  394. end
  395. CFuncs = {
  396. Part = {
  397. Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  398. local Part = Create("Part")({
  399. Parent = Parent,
  400. Reflectance = Reflectance,
  401. Transparency = Transparency,
  402. CanCollide = false,
  403. Locked = true,
  404. BrickColor = BrickColor.new(tostring(BColor)),
  405. Name = Name,
  406. Size = Size,
  407. Material = Material
  408. })
  409. RemoveOutlines(Part)
  410. return Part
  411. end
  412. },
  413. Mesh = {
  414. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  415. local Msh = Create(Mesh)({
  416. Parent = Part,
  417. Offset = OffSet,
  418. Scale = Scale
  419. })
  420. if Mesh == "SpecialMesh" then
  421. Msh.MeshType = MeshType
  422. Msh.MeshId = MeshId
  423. end
  424. return Msh
  425. end
  426. },
  427. Mesh = {
  428. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  429. local Msh = Create(Mesh)({
  430. Parent = Part,
  431. Offset = OffSet,
  432. Scale = Scale
  433. })
  434. if Mesh == "SpecialMesh" then
  435. Msh.MeshType = MeshType
  436. Msh.MeshId = MeshId
  437. end
  438. return Msh
  439. end
  440. },
  441. Weld = {
  442. Create = function(Parent, Part0, Part1, C0, C1)
  443. local Weld = Create("Weld")({
  444. Parent = Parent,
  445. Part0 = Part0,
  446. Part1 = Part1,
  447. C0 = C0,
  448. C1 = C1
  449. })
  450. return Weld
  451. end
  452. },
  453. Sound = {
  454. Create = function(id, par, vol, pit)
  455. coroutine.resume(coroutine.create(function()
  456. local S = Create("Sound")({
  457. Volume = vol,
  458. Pitch = pit or 1,
  459. SoundId = id,
  460. Parent = par or workspace
  461. })
  462. wait()
  463. S:play()
  464. game:GetService("Debris"):AddItem(S, 6)
  465. end))
  466. end
  467. },
  468. ParticleEmitter = {
  469. Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread)
  470. local fp = Create("ParticleEmitter")({
  471. Parent = Parent,
  472. Color = ColorSequence.new(Color1, Color2),
  473. LightEmission = LightEmission,
  474. Size = Size,
  475. Texture = Texture,
  476. Transparency = Transparency,
  477. ZOffset = ZOffset,
  478. Acceleration = Accel,
  479. Drag = Drag,
  480. LockedToPart = LockedToPart,
  481. VelocityInheritance = VelocityInheritance,
  482. EmissionDirection = EmissionDirection,
  483. Enabled = Enabled,
  484. Lifetime = LifeTime,
  485. Rate = Rate,
  486. Rotation = Rotation,
  487. RotSpeed = RotSpeed,
  488. Speed = Speed,
  489. VelocitySpread = VelocitySpread
  490. })
  491. return fp
  492. end
  493. }
  494. }
  495. function RemoveOutlines(part)
  496. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  497. end
  498. function CreatePart(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  499. local Part = Create("Part")({
  500. formFactor = FormFactor,
  501. Parent = Parent,
  502. Reflectance = Reflectance,
  503. Transparency = Transparency,
  504. CanCollide = false,
  505. Locked = true,
  506. BrickColor = BrickColor.new(tostring(BColor)),
  507. Name = Name,
  508. Size = Size,
  509. Material = Material
  510. })
  511. RemoveOutlines(Part)
  512. return Part
  513. end
  514. function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  515. local Msh = Create(Mesh)({
  516. Parent = Part,
  517. Offset = OffSet,
  518. Scale = Scale
  519. })
  520. if Mesh == "SpecialMesh" then
  521. Msh.MeshType = MeshType
  522. Msh.MeshId = MeshId
  523. end
  524. return Msh
  525. end
  526. function CreateWeld(Parent, Part0, Part1, C0, C1)
  527. local Weld = Create("Weld")({
  528. Parent = Parent,
  529. Part0 = Part0,
  530. Part1 = Part1,
  531. C0 = C0,
  532. C1 = C1
  533. })
  534. return Weld
  535. end
  536. EffectModel = Instance.new("Model", char)
  537. Effects = {
  538. Block = {
  539. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  540. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  541. prt.Anchored = true
  542. prt.CFrame = cframe
  543. local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  544. game:GetService("Debris"):AddItem(prt, 10)
  545. if Type == 1 or Type == nil then
  546. table.insert(Effects, {
  547. prt,
  548. "Block1",
  549. delay,
  550. x3,
  551. y3,
  552. z3,
  553. msh
  554. })
  555. elseif Type == 2 then
  556. table.insert(Effects, {
  557. prt,
  558. "Block2",
  559. delay,
  560. x3,
  561. y3,
  562. z3,
  563. msh
  564. })
  565. else
  566. table.insert(Effects, {
  567. prt,
  568. "Block3",
  569. delay,
  570. x3,
  571. y3,
  572. z3,
  573. msh
  574. })
  575. end
  576. end
  577. },
  578. Sphere = {
  579. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  580. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  581. prt.Anchored = true
  582. prt.CFrame = cframe
  583. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  584. game:GetService("Debris"):AddItem(prt, 10)
  585. table.insert(Effects, {
  586. prt,
  587. "Cylinder",
  588. delay,
  589. x3,
  590. y3,
  591. z3,
  592. msh
  593. })
  594. end
  595. },
  596. Cylinder = {
  597. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  598. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  599. prt.Anchored = true
  600. prt.CFrame = cframe
  601. local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  602. game:GetService("Debris"):AddItem(prt, 10)
  603. table.insert(Effects, {
  604. prt,
  605. "Cylinder",
  606. delay,
  607. x3,
  608. y3,
  609. z3,
  610. msh
  611. })
  612. end
  613. },
  614. Wave = {
  615. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  616. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  617. prt.Anchored = true
  618. prt.CFrame = cframe
  619. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://431164262", Vector3.new(0, 0, 0), Vector3.new(x1 / 60, y1 / 60, z1 / 60))
  620. game:GetService("Debris"):AddItem(prt, 10)
  621. table.insert(Effects, {
  622. prt,
  623. "Cylinder",
  624. delay,
  625. x3 / 60,
  626. y3 / 60,
  627. z3 / 60,
  628. msh
  629. })
  630. end
  631. },
  632. Ring = {
  633. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  634. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  635. prt.Anchored = true
  636. prt.CFrame = cframe
  637. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  638. game:GetService("Debris"):AddItem(prt, 10)
  639. table.insert(Effects, {
  640. prt,
  641. "Cylinder",
  642. delay,
  643. x3,
  644. y3,
  645. z3,
  646. msh
  647. })
  648. end
  649. },
  650. Break = {
  651. Create = function(brickcolor, cframe, x1, y1, z1)
  652. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  653. prt.Anchored = true
  654. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  655. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  656. local num = math.random(10, 50) / 1000
  657. game:GetService("Debris"):AddItem(prt, 10)
  658. table.insert(Effects, {
  659. prt,
  660. "Shatter",
  661. num,
  662. prt.CFrame,
  663. math.random() - math.random(),
  664. 0,
  665. math.random(50, 100) / 100
  666. })
  667. end
  668. }
  669. }
  670. function BlockEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  671. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  672. prt.Anchored = true
  673. prt.CFrame = cframe
  674. local msh = CreateMesh("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  675. game:GetService("Debris"):AddItem(prt, 10)
  676. if Type == 1 or Type == nil then
  677. table.insert(Effects, {
  678. prt,
  679. "Block1",
  680. delay,
  681. x3,
  682. y3,
  683. z3,
  684. msh
  685. })
  686. elseif Type == 2 then
  687. table.insert(Effects, {
  688. prt,
  689. "Block2",
  690. delay,
  691. x3,
  692. y3,
  693. z3,
  694. msh
  695. })
  696. elseif Type == 3 then
  697. table.insert(Effects, {
  698. prt,
  699. "Block3",
  700. delay,
  701. x3,
  702. y3,
  703. z3,
  704. msh
  705. })
  706. end
  707. end
  708. function SphereEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  709. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  710. prt.Anchored = true
  711. prt.CFrame = cframe
  712. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  713. game:GetService("Debris"):AddItem(prt, 10)
  714. table.insert(Effects, {
  715. prt,
  716. "Cylinder",
  717. delay,
  718. x3,
  719. y3,
  720. z3,
  721. msh
  722. })
  723. end
  724. function RingEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  725. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  726. prt.Anchored = true
  727. prt.CFrame = cframe * CFrame.new(x1, y1, z1)
  728. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "264766957", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  729. game:GetService("Debris"):AddItem(prt, 10)
  730. table.insert(Effects, {
  731. prt,
  732. "Cylinder",
  733. delay,
  734. x3,
  735. y3,
  736. z3,
  737. msh
  738. })
  739. end
  740. function CylinderEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  741. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  742. prt.Anchored = true
  743. prt.CFrame = cframe
  744. local msh = CreateMesh("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  745. game:GetService("Debris"):AddItem(prt, 10)
  746. table.insert(Effects, {
  747. prt,
  748. "Cylinder",
  749. delay,
  750. x3,
  751. y3,
  752. z3,
  753. msh
  754. })
  755. end
  756. function WaveEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  757. local prt = CreatePart(3, workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  758. prt.Anchored = true
  759. prt.CFrame = cframe
  760. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "264766957", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  761. game:GetService("Debris"):AddItem(prt, 10)
  762. table.insert(Effects, {
  763. prt,
  764. "Cylinder",
  765. delay,
  766. x3,
  767. y3,
  768. z3,
  769. msh
  770. })
  771. end
  772. function SpecialEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  773. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  774. prt.Anchored = true
  775. prt.CFrame = cframe
  776. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "24388358", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  777. game:GetService("Debris"):AddItem(prt, 10)
  778. table.insert(Effects, {
  779. prt,
  780. "Cylinder",
  781. delay,
  782. x3,
  783. y3,
  784. z3,
  785. msh
  786. })
  787. end
  788. function BreakEffect(brickcolor, cframe, x1, y1, z1)
  789. local prt = CreatePart(3, workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  790. prt.Anchored = true
  791. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  792. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  793. local num = math.random(10, 50) / 1000
  794. game:GetService("Debris"):AddItem(prt, 10)
  795. table.insert(Effects, {
  796. prt,
  797. "Shatter",
  798. num,
  799. prt.CFrame,
  800. math.random() - math.random(),
  801. 0,
  802. math.random(50, 100) / 100
  803. })
  804. end
  805.  
  806.  
  807.  
  808.  
  809.  
  810. --[[
  811. Thanks for using Build-To-Lua by jarredbcv.
  812. ]]--
  813.  
  814. New = function(Object, Parent, Name, Data)
  815. local Object = Instance.new(Object)
  816. for Index, Value in pairs(Data or {}) do
  817. Object[Index] = Value
  818. end
  819. Object.Parent = Parent
  820. Object.Name = Name
  821. return Object
  822. end
  823.  
  824. Model = New("Model",char,"Model",{})
  825. Handle = New("Part",Model,"Handle",{BrickColor = BrickColor.new("Reddish brown"),Material = Enum.Material.Wood,Size = Vector3.new(0.300000131, 3.89999866, 0.299999565),CFrame = CFrame.new(119.050049, 1.950001, -79.2499695, 1, 0, 0, 0, 1, 0, 0, 0, 1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.411765, 0.25098, 0.156863),})
  826. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.300000012, 0.199998289, 0.299999565),CFrame = CFrame.new(120.651886, 3.42561507, -79.2499695, 0, 0.342021108, -0.939692378, 0, 0.939692378, 0.342021108, 1, 0, 0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  827. Mesh = New("SpecialMesh",Part,"Mesh",{MeshType = Enum.MeshType.Wedge,})
  828. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0, 0, 1, 0.342021108, 0.939692378, 0, -0.939692378, 0.342021108, 0),C1 = CFrame.new(1.60183716, 1.47561407, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  829. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.500000119, 0.499998271, 0.499999553),CFrame = CFrame.new(119.050049, 3.54999804, -79.2499695, 1, 0, 0, 0, 1, 0, 0, 0, 1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  830. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C1 = CFrame.new(0, 1.59999704, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  831. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.700000048, 0.199998289, 0.299999565),CFrame = CFrame.new(119.550079, 3.6999979, -79.2499695, 1, 0, 0, 0, 1, 0, 0, 0, 1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  832. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C1 = CFrame.new(0.500030518, 1.7499969, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  833. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.700000048, 0.199998289, 0.299999565),CFrame = CFrame.new(120.195541, 3.5917089, -79.2499695, 0.939692736, 0.342019886, 0, -0.342019916, 0.939692736, 0, 0, 0, 1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  834. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0.939692736, -0.342019916, 0, 0.342019886, 0.939692736, 0, 0, 0, 1),C1 = CFrame.new(1.14549255, 1.6417079, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  835. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.700000048, 0.199998289, 0.299999565),CFrame = CFrame.new(117.867294, 3.59170794, -79.2499771, -0.939692736, -0.342019886, 0, -0.342019916, 0.939692736, 0, 0, 0, -1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  836. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, -0.939692736, -0.342019916, 0, -0.342019886, 0.939692736, 0, 0, 0, -1),C1 = CFrame.new(-1.18275452, 1.64170694, -7.62939453e-06, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  837. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.700000048, 0.199998289, 0.299999565),CFrame = CFrame.new(118.512802, 3.69999695, -79.2500076, -1, 0, 0, 0, 1, 0, 0, 0, -1),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  838. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1),C1 = CFrame.new(-0.537246704, 1.74999595, -3.81469727e-05, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  839. Part = New("Part",Model,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,Size = Vector3.new(0.300000012, 0.199998289, 0.299999565),CFrame = CFrame.new(117.410965, 3.42561197, -79.2499695, 0, -0.342022002, 0.93969208, 0, 0.93969202, 0.342022002, -1, 0, 0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  840. Mesh = New("SpecialMesh",Part,"Mesh",{MeshType = Enum.MeshType.Wedge,})
  841. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0, 0, -1, -0.342022002, 0.93969202, 0, 0.93969208, 0.342022002, 0),C1 = CFrame.new(-1.63908386, 1.47561097, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  842.  
  843.  
  844. Sword = New("Model",char,"Sword",{})
  845. Handle2 = New("Part",Sword,"Handle",{BrickColor = BrickColor.new("Reddish brown"),Material = Enum.Material.Wood,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(0.399997711, 1.20000005, 0.200000003),CFrame = CFrame.new(115.200005, 4.20000219, -75.9000397, 1, 0, 0, 0, 1, 0, 0, 0, 1),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.411765, 0.25098, 0.156863),})
  846. Part = New("Part",Sword,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(0.200000003, 0.400000036, 0.400000036),CFrame = CFrame.new(115.400002, 8.40000153, -75.9000397, -1.49011612e-08, 0, -0.999999762, 0, 1, 0, 0.999999762, 0, -1.49011612e-08),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  847. Mesh = New("SpecialMesh",Part,"Mesh",{MeshType = Enum.MeshType.Wedge,})
  848. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C0 = CFrame.new(0, 0, 0, -1.49011612e-08, 0, 0.999999762, 0, 1, 0, -0.999999762, 0, -1.49011612e-08),C1 = CFrame.new(0.199996948, 4.19999933, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  849. Part = New("Part",Sword,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(0.799997687, 3.20000005, 0.200000003),CFrame = CFrame.new(115.200005, 6.5999999, -75.9000397, 1, 0, 0, 0, 1, 0, 0, 0, 1),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  850. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C1 = CFrame.new(0, 2.39999771, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  851. Part = New("Part",Sword,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.SmoothPlastic,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(0.200000003, 0.400000036, 0.400000036),CFrame = CFrame.new(115.000008, 8.40000153, -75.9000397, 7.4505806e-08, 0, 0.999999583, 0, 1, 0, -0.999999583, 0, 7.4505806e-08),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  852. Mesh = New("SpecialMesh",Part,"Mesh",{MeshType = Enum.MeshType.Wedge,})
  853. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C0 = CFrame.new(0, 0, 0, 7.4505806e-08, 0, -0.999999583, 0, 1, 0, 0.999999583, 0, 7.4505806e-08),C1 = CFrame.new(-0.199996948, 4.19999933, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  854. Part = New("Part",Sword,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.Slate,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(1.20000005, 0.200000003, 0.400000006),CFrame = CFrame.new(115.200005, 4.89999914, -75.9000397, 1, 0, 0, 0, 1, 0, 0, 0, 1),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  855. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C1 = CFrame.new(0, 0.699996948, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  856. Part = New("Part",Sword,"Part",{BrickColor = BrickColor.new("Teal"),Material = Enum.Material.Slate,FormFactor = Enum.FormFactor.Custom,Size = Vector3.new(0.5, 0.200000003, 0.300000012),CFrame = CFrame.new(115.200005, 3.50000191, -75.9000397, 1, 0, 0, 0, 1, 0, 0, 0, 1),BackSurface = Enum.SurfaceType.SmoothNoOutlines,BottomSurface = Enum.SurfaceType.SmoothNoOutlines,FrontSurface = Enum.SurfaceType.SmoothNoOutlines,LeftSurface = Enum.SurfaceType.SmoothNoOutlines,RightSurface = Enum.SurfaceType.SmoothNoOutlines,TopSurface = Enum.SurfaceType.SmoothNoOutlines,Color = Color3.new(0.0705882, 0.933333, 0.831373),})
  857. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C1 = CFrame.new(0, -0.700000286, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),})
  858. for _,v in next, Model:children() do
  859. if v:IsA'BasePart' then
  860.  
  861. v.CanCollide = false
  862. end
  863. end
  864. for _,v in next, Sword:children() do
  865. if v:IsA'BasePart' then
  866.  
  867.  
  868. v.CanCollide = false
  869. end
  870. end
  871.  
  872.  
  873.  
  874. local NewInstance = function(instance,parent,properties)
  875. local inst = Instance.new(instance,parent)
  876. if(properties)then
  877. for i,v in next, properties do
  878. pcall(function() inst[i] = v end)
  879. end
  880. end
  881. return inst;
  882. end
  883. local HW2 = NewInstance('Weld',char,{Part0=ra,Part1=Handle,C0 = CFrame.new(0,-1,-1)*CFrame.Angles(math.rad(-90),math.rad(90),math.rad(0))})
  884. local HW = NewInstance('Weld',char,{Part0=la,Part1=Handle2,C0 = CFrame.new(0,-1,0)*CFrame.Angles(math.rad(-90),math.rad(90),math.rad(0))})
  885. music = Instance.new("Sound",tors)
  886. music.SoundId = "rbxassetid://840433326"
  887. music.Volume = 1.5
  888. music.Looped = true
  889. music:Play()
  890. torch=false
  891. mouse.KeyDown:connect(function(key)
  892. if key == 'z' and attack == false and torch==false then
  893. UPick()
  894. torch=true
  895. elseif key == 'z' and attack == false and torch==true then
  896. Pick()
  897. torch=false
  898. end
  899. end)
  900.  
  901. function attackoneS()
  902. attack=true
  903. for i = 0,2,0.1 do
  904. swait()
  905. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(-90)),0.15)
  906. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(90)),.3)
  907. HW.C0 = clerp(HW.C0, CFrame.new(0,-1,0) * angles(math.rad(0),math.rad(0),math.rad(125)),.2)
  908. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5+0.04, 0) * angles(math.rad(90 - 1), math.rad(0), math.rad(50)), 0.1)
  909. end
  910. local con = la.Touched:connect(function(hit)
  911. Damage(la, hit, 25, 34, math.random(1, 5), "Normal", root, .2, "rbxassetid://146163522", 1)
  912. end) --Was way to lazy to make a hitbox since this script was just me being fucking bored
  913. for i = 0,2,0.1 do
  914. swait()
  915. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(90)),.3)
  916. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(-55)),0.15)
  917. LW.C0=clerp(LW.C0,cf(-1.5,.5,0)*angles(math.rad(89),math.rad(0),math.rad(-90)),.3)
  918. end
  919. con:Disconnect()
  920. attack=false
  921. end
  922.  
  923. function attacktwoS()
  924. attack=true
  925. for i = 0,1.5,0.1 do
  926. swait()
  927. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(-55)),0.15)
  928. RW.C0=clerp(RW.C0,cf(1.5,.5,0)*angles(math.rad(0),math.rad(0),math.rad(55)),.3)
  929. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(90), math.rad(-0), math.rad(-55)),.2)
  930. HW.C0 = clerp(HW.C0, CFrame.new(0,-1,0) * angles(math.rad(5),math.rad(90),math.rad(-90)),.2)
  931. end
  932. local con = ra.Touched:connect(function(hit)
  933. Damage(ra, hit, 25, 34, math.random(1, 5), "Normal", root, .2, "rbxassetid://146163522", 1)
  934. end) --Was way to lazy to make a hitbox since this script was just me being fucking bored
  935. for i = 0,2,0.1 do
  936. swait()
  937. tors.Neck.C0=clerp(tors.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(-75)),.3)
  938. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(90)),0.15)
  939. RW.C0=clerp(RW.C0,cf(1.5,.5,0)*angles(math.rad(0),math.rad(0),math.rad(90)),.3)
  940. HW.C0 = clerp(HW.C0, CFrame.new(0,-1,0) * angles(math.rad(5),math.rad(90),math.rad(-180)),.2)
  941. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(55), math.rad(-0), math.rad(-25)),.2)
  942. end
  943. attack=false
  944. con:Disconnect()
  945. end
  946.  
  947. function UPick()
  948. attack=true
  949. for i = 0,1.5,0.1 do
  950. swait()
  951.  
  952. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-10), math.rad(-0), math.rad(-0)),.2)
  953.  
  954.  
  955. end
  956. for _,v in next, Model:children() do
  957. if v:IsA'BasePart' then
  958.  
  959. v.Transparency = 1
  960. v.CanCollide = false
  961. end
  962. end
  963. attack=false
  964. end
  965.  
  966. function Pick()
  967. attack=true
  968. for i = 0,1.5,0.1 do
  969. swait()
  970.  
  971. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-25), math.rad(-0), math.rad(-0)),.2)
  972.  
  973. end
  974. for _,v in next, Model:children() do
  975. if v:IsA'BasePart' then
  976.  
  977. v.Transparency = 0
  978. v.CanCollide = false
  979. end
  980. end
  981. attack=false
  982. end
  983.  
  984.  
  985.  
  986. attacktype=1
  987. mouse.Button1Down:connect(function()
  988. if attack==false then
  989. if attacktype==1 then
  990. attack=true
  991. attacktype=2
  992. attackoneS()
  993. elseif attacktype==2 then
  994. attack=true
  995. attacktype=1
  996. attacktwoS()
  997. end
  998. end
  999. end)
  1000. hum.Health = math.huge
  1001. hum.MaxHealth = math.huge
  1002. hum.WalkSpeed = 6
  1003. idle=0
  1004. local sine = 0
  1005. local change = 1
  1006. local val = 0
  1007. toim = 0
  1008. hum.Animator.Parent = nil
  1009. idleanim=.4
  1010. while true do
  1011. swait()
  1012. sine = sine + change
  1013. local torvel=(root.Velocity*Vector3.new(1,0,1)).magnitude
  1014. local velderp=root.Velocity.y
  1015. hitfloor,posfloor=rayCast(root.Position,(CFrame.new(root.Position,root.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1016. if equipped==true or equipped==false then
  1017. if attack==false then
  1018. idle=idle+1
  1019. else
  1020. idle=0
  1021. end
  1022. if root.Velocity.y > 1 and hitfloor==nil then
  1023. Anim="Jump"
  1024. if attack==false then
  1025. rootj.C0 = clerp(rootj.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1026. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  1027. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(10)), 0.3)
  1028. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-30)), 0.3)
  1029. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-20)),.3)
  1030. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-60),math.rad(0)),.3)
  1031. end
  1032. elseif root.Velocity.y < -1 and hitfloor==nil then
  1033. Anim="Fall"
  1034. if attack==false then
  1035. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-20)),.3)
  1036. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-60),math.rad(0)),.3)
  1037. rootj.C0 = clerp(rootj.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1038. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(40),math.rad(0),math.rad(0)),.3)
  1039. RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.65, 0) * angles(math.rad(-10), math.rad(0), math.rad(90)), 0.3)
  1040. LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.65, 0) * angles(math.rad(-10), math.rad(0), math.rad(-90)), 0.3)
  1041. end
  1042. elseif torvel<1 and hitfloor~=nil then
  1043. Anim="Idle"
  1044. change = 1
  1045. if attack==false then
  1046. HW.C0 = clerp(HW.C0, CFrame.new(0,-1,0) * angles(math.rad(15),math.rad(-90),math.rad(50)),.2)
  1047. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.1+0.1*math.cos(sine/20))*angles(math.rad(0),math.rad(0),math.rad(0)),0.15)
  1048. tors.Neck.C0=clerp(tors.Neck.C0,necko*angles(math.rad(5.5*math.cos(sine/30)),math.rad(0),math.rad(0)),.3)
  1049. RH.C0=clerp(RH.C0,cf(1,-0.9-0.1*math.cos(sine/20),0.025*math.cos(sine/20))*angles(math.rad(-2.5),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),0.15)
  1050. LH.C0=clerp(LH.C0,cf(-1,-0.9-0.1*math.cos(sine/20),0.025*math.cos(sine/20))*angles(math.rad(-2.5),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),0.15)
  1051. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5+0.05*math.sin(sine/30), 0) * angles(math.rad(3), math.rad(15*math.cos(sine/40)), math.rad(15)),.2)
  1052. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5+0.05*math.sin(sine/30), 0) * angles(math.rad(75), math.rad(-15*math.cos(sine/40)), math.rad(-10)),.2)
  1053.  
  1054. end
  1055. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  1056. Anim="Walk"
  1057. change = .6
  1058. if attack==false then
  1059. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.175+0.025*math.cos(sine/3.5)+ -math.sin(sine/3.5)/7)*angles(math.rad(5-2.5*math.cos(sine/3.5)),math.rad(0),math.rad(20*math.cos(sine/7))),0.15)
  1060. tors.Neck.C0 = clerp(tors.Neck.C0, necko * cf(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(15*math.cos(sine/7))), 0.3)
  1061. RW.C0=clerp(RW.C0,CFrame.new(1.5,0.5,0)*angles(math.rad(30*math.cos(sine/7))+ math.sin(sine/7)/2.5,math.rad(0),math.rad(10)),0.15)
  1062. LW.C0=clerp(LW.C0,CFrame.new(-1.5,0.5,0)*angles(math.rad(-30*math.cos(sine/7))+ -math.sin(sine/7)/2.5,math.rad(0),math.rad(-10)),0.15)
  1063. RH.C0=clerp(RH.C0,cf(1,-0.925-0.5*math.cos(sine/7)/2,0.5*math.cos(sine/7)/1.5)*angles(math.rad(-5-15*math.cos(sine/7))+ -math.sin(sine/7)/2.5,math.rad(90-10*math.cos(sine/7)),math.rad(0))*angles(math.rad(0+3.5*math.cos(sine/7)),math.rad(0),math.rad(0)),0.15)
  1064. LH.C0=clerp(LH.C0,cf(-1,-0.925+0.5*math.cos(sine/7)/2,-0.5*math.cos(sine/7)/1.5)*angles(math.rad(-5+15*math.cos(sine/7))+ math.sin(sine/7)/2.5,math.rad(-90-10*math.cos(sine/7)),math.rad(0))*angles(math.rad(0-3.5*math.cos(sine/7)),math.rad(0),math.rad(0)),0.15)
  1065. HW.C0 = clerp(HW.C0, CFrame.new(0,-1,0) * angles(math.rad(-90),math.rad(90),math.rad(0)),.2)
  1066. end
  1067. elseif torvel>=22 and hitfloor~=nil then
  1068. Anim="Run"
  1069. if attack==false then
  1070. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.175+0.025*math.cos(sine/3.5)+ -math.sin(sine/3.5)/7)*angles(math.rad(5-2.5*math.cos(sine/3.5)),math.rad(0),math.rad(10*math.cos(sine/7))),0.15)
  1071. tors.Neck.C0 = clerp(tors.Neck.C0, necko * cf(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1072. RW.C0=clerp(RW.C0,CFrame.new(1.5,0.5,0)*angles(math.rad(30*math.cos(sine/7))+ math.sin(sine/7)/2.5,math.rad(0),math.rad(10)),0.15)
  1073. LW.C0=clerp(LW.C0,CFrame.new(-1.5,0.5,0)*angles(math.rad(-30*math.cos(sine/7))+ -math.sin(sine/7)/2.5,math.rad(0),math.rad(-10)),0.15)
  1074. RH.C0=clerp(RH.C0,cf(1,-0.925-0.5*math.cos(sine/7)/2,0.5*math.cos(sine/7)/2)*angles(math.rad(-25-15*math.cos(sine/7))+ -math.sin(sine/7),math.rad(90-10*math.cos(sine/7)),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),0.15)
  1075. LH.C0=clerp(LH.C0,cf(-1,-0.925+0.5*math.cos(sine/7)/2,-0.5*math.cos(sine/7)/2)*angles(math.rad(-25+15*math.cos(sine/7))+ math.sin(sine/7),math.rad(-90-10*math.cos(sine/7)),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),0.15)
  1076. end
  1077. end
  1078. end
  1079. if 0 < #Effects then
  1080. for e = 1, #Effects do
  1081. if Effects[e] ~= nil then
  1082. local Thing = Effects[e]
  1083. if Thing ~= nil then
  1084. local Part = Thing[1]
  1085. local Mode = Thing[2]
  1086. local Delay = Thing[3]
  1087. local IncX = Thing[4]
  1088. local IncY = Thing[5]
  1089. local IncZ = Thing[6]
  1090. if 1 >= Thing[1].Transparency then
  1091. if Thing[2] == "Block1" then
  1092. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  1093. local Mesh = Thing[1].Mesh
  1094. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1095. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1096. elseif Thing[2] == "Block2" then
  1097. Thing[1].CFrame = Thing[1].CFrame + Vector3.new(0, 0, 0)
  1098. local Mesh = Thing[7]
  1099. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1100. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1101. elseif Thing[2] == "Block3" then
  1102. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) + Vector3.new(0, 0.15, 0)
  1103. local Mesh = Thing[7]
  1104. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1105. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1106. elseif Thing[2] == "Cylinder" then
  1107. local Mesh = Thing[1].Mesh
  1108. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1109. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1110. elseif Thing[2] == "Blood" then
  1111. local Mesh = Thing[7]
  1112. Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0)
  1113. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1114. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1115. elseif Thing[2] == "Elec" then
  1116. local Mesh = Thing[1].Mesh
  1117. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9])
  1118. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1119. elseif Thing[2] == "Disappear" then
  1120. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1121. elseif Thing[2] == "Shatter" then
  1122. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1123. Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0)
  1124. Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0)
  1125. Thing[6] = Thing[6] + Thing[5]
  1126. end
  1127. else
  1128. Part.Parent = nil
  1129. table.remove(Effects, e)
  1130. end
  1131. end
  1132. end
  1133. end
  1134. end
  1135. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement