codemen

Bow script [roblox]

Nov 24th, 2017
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.52 KB | None | 0 0
  1. --mediafire
  2.  
  3. function weld(p0,p1,c0,c1,par)
  4. local w = Instance.new("Weld",p0 or par)
  5. w.Part0 = p0
  6. w.Part1 = p1
  7. w.C0 = c0 or CFrame.new()
  8. w.C1 = c1 or CFrame.new()
  9. return w
  10. end
  11.  
  12. do -- Credit to Stravant...
  13. local function QuaternionFromCFrame(cf) local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() local trace = m00 + m11 + m22 if trace > 0 then local s = math.sqrt(1 + trace) local recip = 0.5/s return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5 else local i = 0 if m11 > m00 then i = 1 end if m22 > (i == 0 and m00 or m11) then i = 2 end if i == 0 then local s = math.sqrt(m00-m11-m22+1) local recip = 0.5/s return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip elseif i == 1 then local s = math.sqrt(m11-m22-m00+1) local recip = 0.5/s return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip elseif i == 2 then local s = math.sqrt(m22-m00-m11+1) local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip end end end
  14.  
  15. local function QuaternionToCFrame(px, py, pz, x, y, z, w) local xs, ys, zs = x + x, y + y, z + z local wx, wy, wz = w*xs, w*ys, w*zs local xx = x*xs local xy = x*ys local xz = x*zs local yy = y*ys local yz = y*zs local zz = z*zs 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)) end
  16.  
  17. local function QuaternionSlerp(a, b, t) local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4] local startInterp, finishInterp; if cosTheta >= 0.0001 then if (1 - cosTheta) > 0.0001 then local theta = math.acos(cosTheta) local invSinTheta = 1/math.sin(theta) startInterp = math.sin((1-t)*theta)*invSinTheta finishInterp = math.sin(t*theta)*invSinTheta else startInterp = 1-t finishInterp = t end else if (1+cosTheta) > 0.0001 then local theta = math.acos(-cosTheta) local invSinTheta = 1/math.sin(theta) startInterp = math.sin((t-1)*theta)*invSinTheta finishInterp = math.sin(t*theta)*invSinTheta else startInterp = t-1 finishInterp = t end end 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 end
  18.  
  19. function clerp(a,b,t)
  20. if not a or not b then print(a,b,"is missing") return end
  21. local qa = {QuaternionFromCFrame(a)}
  22. local qb = {QuaternionFromCFrame(b)}
  23. local ax, ay, az = a.x, a.y, a.z
  24. local bx, by, bz = b.x, b.y, b.z
  25.  
  26. local _t = 1-t
  27. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  28. end
  29. end
  30.  
  31. local oc = oc or function(...) return ... end
  32.  
  33. pcall(function() script.Parent.bScript:Destroy() end)
  34. script.Name = "bScript"
  35.  
  36. local plr = game:service'Players'.LocalPlayer
  37. local mouse = plr:GetMouse()
  38. local char = plr.Character
  39.  
  40. local tor,ra,la,rl,ll,hd,hum = char.Torso,char["Right Arm"],char["Left Arm"],char["Right Leg"],char["Left Leg"],char.Head,char.Humanoid
  41. local rrs,rls,nk = tor["Right Shoulder"],tor["Left Shoulder"],tor.Neck
  42. local nk0 = nk.C0
  43. local rc0,rc1 = rrs.C0,rrs.C1
  44. local lc0,lc1 = rls.C0,rls.C0
  45. local rs,ls = rrs:Clone(),rls:Clone()
  46. rs.Name,ls.Name = "rs","ls"
  47. rs.DesiredAngle,rs.CurrentAngle = 0,0
  48. ls.DesiredAngle,ls.CurrentAngle = 0,0
  49.  
  50. local model = Instance.new("Model",char)
  51. pcall(function() char.bModel:Destroy() end)
  52. model.Name = "bModel"
  53.  
  54. local part = Instance.new("Part")
  55. part.BrickColor = BrickColor.new("Really red")
  56. part.Reflectance = 0.15
  57. part.FormFactor = "Custom"
  58. part.TopSurface,part.BottomSurface = 0,0
  59. part.Size = Vector3.new(.2,.2,.2)
  60. part:BreakJoints()
  61. part.CanCollide = false
  62.  
  63. function clone(t)
  64. local p = t:Clone()
  65. p.Parent = t.Parent or model
  66. return p
  67. end
  68.  
  69. local han = clone(part)
  70. han.Size = Vector3.new(.3,.5,.3)
  71. han.Transparency = 1
  72. local hold = weld(la,han,CFrame.new(0,-1,0) * CFrame.Angles(math.rad(-90),math.rad(23),0),CFrame.new())
  73.  
  74. for i=1,14 do
  75. local gr = clone(part)
  76. gr.BrickColor = BrickColor.new("Dark stone grey")
  77. gr.Size = Vector3.new(.3,.2,.3)
  78. local m = Instance.new("SpecialMesh",gr)
  79. m.MeshType = "Sphere"
  80. m.Scale = Vector3.new(1,.75,1) * math.max(.85,math.abs(i-7)/5)
  81. weld(han,gr,CFrame.new(0,-.6+i*.085,0) * CFrame.Angles(math.rad(15),math.rad(0),math.rad(23)),CFrame.new())
  82. end
  83.  
  84. local p = clone(part)
  85. p.Size = Vector3.new(.45,.2,.32)
  86. local m = Instance.new("BlockMesh",p)
  87. m.Scale = Vector3.new(1,.5,1)
  88.  
  89. weld(han,p,CFrame.new(0,-.62,.125) * CFrame.Angles(math.rad(10),0,0))
  90.  
  91. local p = clone(part)
  92. p.Size = Vector3.new(.45,.2,.3)
  93. local m = Instance.new("BlockMesh",p)
  94. m.Scale = Vector3.new(1,.5,1)
  95.  
  96. weld(han,p,CFrame.new(0,-.62,-.125) * CFrame.Angles(math.rad(-10),0,0))
  97.  
  98. local b1 = clone(part)
  99. b1.Size = Vector3.new(.2,1,.3)
  100. local m = Instance.new("BlockMesh",b1)
  101. m.Scale = Vector3.new(1,1,1)
  102.  
  103. local bw1 = weld(han,b1,CFrame.new(0,-.6,0) * CFrame.Angles(math.rad(-10),0,0),CFrame.new(0,.5,0))
  104.  
  105. local b2 = clone(part)
  106. b2.Size = Vector3.new(.2,1,.25)
  107. local m = Instance.new("BlockMesh",b2)
  108. m.Scale = Vector3.new(.9,1,1)
  109.  
  110. local bw2 = weld(b1,b2,CFrame.new(0,-.5,-.15) * CFrame.Angles(math.rad(-25),0,0),CFrame.new(0,.5,-.125))
  111.  
  112. local b3 = clone(part)
  113. b3.Size = Vector3.new(.2,1,.2)
  114. local m = Instance.new("BlockMesh",b3)
  115. m.Scale = Vector3.new(.75,1,1)
  116.  
  117. local bw3 = weld(b2,b3,CFrame.new(0,-.5,-.125) * CFrame.Angles(math.rad(-25),0,0),CFrame.new(0,.5,-.1))
  118.  
  119. local bt = clone(part)
  120. bt.BrickColor = BrickColor.new("Black")
  121. bt.Size = Vector3.new(.2,.3,.2)
  122. local m = Instance.new("BlockMesh",bt)
  123. m.Scale = Vector3.new(.5,1,1) * .5
  124.  
  125. local btw = weld(b3,bt,CFrame.new(0,-.5,.1) * CFrame.Angles(math.rad(-25),0,0),CFrame.new(0,0,.05))
  126.  
  127.  
  128.  
  129. local p = clone(part)
  130. p.Size = Vector3.new(.45,.2,.32)
  131. local m = Instance.new("BlockMesh",p)
  132. m.Scale = Vector3.new(1,.5,1)
  133.  
  134. weld(han,p,CFrame.new(0,.67,.125) * CFrame.Angles(math.rad(15),0,0))
  135.  
  136. local p = clone(part)
  137. p.Size = Vector3.new(.45,.2,.3)
  138. local m = Instance.new("BlockMesh",p)
  139. m.Scale = Vector3.new(1,.5,1)
  140.  
  141. weld(han,p,CFrame.new(0,.67,-.125) * CFrame.Angles(math.rad(-15),0,0))
  142.  
  143. local p = clone(part)
  144. p.Size = Vector3.new(.4,.2,.3)
  145. local m = Instance.new("BlockMesh",p)
  146. m.Scale = Vector3.new(1,.5,1)
  147.  
  148. weld(han,p,CFrame.new(0,.75,0) * CFrame.Angles(math.rad(0),0,0))
  149.  
  150. local p = clone(part)
  151. p.Size = Vector3.new(.2,.3,.35)
  152. local m = Instance.new("BlockMesh",p)
  153. m.Scale = Vector3.new(1,1,1)
  154.  
  155. weld(han,p,CFrame.new(-.1,.8,0) * CFrame.Angles(math.rad(0),0,0))
  156.  
  157. local p = clone(part)
  158. p.Size = Vector3.new(.45,.2,.32)
  159. local m = Instance.new("BlockMesh",p)
  160. m.Scale = Vector3.new(1,.5,1)
  161.  
  162. weld(han,p,CFrame.new(0,1,.125) * CFrame.Angles(math.rad(-5),0,0))
  163.  
  164. local p = clone(part)
  165. p.Size = Vector3.new(.45,.2,.25)
  166. local m = Instance.new("BlockMesh",p)
  167. m.Scale = Vector3.new(1,.5,1)
  168.  
  169. weld(han,p,CFrame.new(0,1,-.125) * CFrame.Angles(math.rad(5),0,0))
  170.  
  171. local t1 = clone(part)
  172. t1.Size = Vector3.new(.2,1,.3)
  173. local m = Instance.new("BlockMesh",t1)
  174. m.Scale = Vector3.new(1,1,1)
  175.  
  176. local tw1 = weld(han,t1,CFrame.new(0,.975,0) * CFrame.Angles(math.rad(10),0,0),CFrame.new(0,-.5,0))
  177.  
  178. local t2 = clone(part)
  179. t2.Size = Vector3.new(.2,1,.25)
  180. local m = Instance.new("BlockMesh",t2)
  181. m.Scale = Vector3.new(.9,1,1)
  182.  
  183. local tw2 = weld(t1,t2,CFrame.new(0,.5,-.15) * CFrame.Angles(math.rad(25),0,0),CFrame.new(0,-.5,-.125))
  184.  
  185. local t3 = clone(part)
  186. t3.Size = Vector3.new(.2,1,.2)
  187. local m = Instance.new("BlockMesh",t3)
  188. m.Scale = Vector3.new(.75,1,1)
  189.  
  190. local tw3 = weld(t2,t3,CFrame.new(0,.5,-.125) * CFrame.Angles(math.rad(25),0,0),CFrame.new(0,-.5,-.1))
  191.  
  192. local tt = clone(part)
  193. tt.BrickColor = BrickColor.new("Black")
  194. tt.Size = Vector3.new(.2,.3,.2)
  195. local m = Instance.new("BlockMesh",tt)
  196. m.Scale = Vector3.new(.5,1,1) * .5
  197.  
  198. local ttw = weld(t3,tt,CFrame.new(0,.5,.1) * CFrame.Angles(math.rad(25),0,0),CFrame.new(0,0,.05))
  199.  
  200. local W = {bw1,bw2,bw3,tw1,tw2,tw3}
  201. local W0 = {bw1.C0,bw2.C0,bw3.C0,tw1.C0,tw2.C0,tw3.C0}
  202.  
  203. local l1 = clone(part)
  204. l1.BrickColor = BrickColor.new("Really red")
  205. l1.Size = Vector3.new(.2,.2,.2)
  206. local m = Instance.new("CylinderMesh",l1)
  207. local l1w = weld(bt,l1)
  208.  
  209. local l2 = clone(l1)
  210. local l2w = weld(tt,l2)
  211.  
  212.  
  213. local amodel = Instance.new("Model")
  214. local arrow = clone(part)
  215. arrow.Parent = amodel
  216. arrow.BrickColor = BrickColor.new("Brown")
  217. arrow.Size = Vector3.new(.2,3,.2)
  218. arrow.Name = "main"
  219. local m = Instance.new("CylinderMesh",arrow)
  220. m.Scale = Vector3.new(.5,1,.5)
  221.  
  222. local arrw = weld(han,arrow)
  223.  
  224. local tip = clone(part)
  225. tip.Parent = amodel
  226. tip.BrickColor = BrickColor.new("Dark stone grey")
  227. tip.Size = Vector3.new(.2,.4,.2)
  228. tip.Name = "tip"
  229. local m = Instance.new("SpecialMesh",tip)
  230. m.MeshId = "rbxassetid://1033714"
  231. m.Scale = Vector3.new(.1,.45,.1)
  232.  
  233. weld(arrow,tip,CFrame.new(0,1.6,0))
  234.  
  235.  
  236. local walkspeed = 16
  237.  
  238. local hpos_i = CFrame.new(0,.8,1.3)
  239. local hpos_l = CFrame.new(0,.8,1.55)
  240. local hpos = hpos_i
  241.  
  242. local keeper = Vector3.new(0.07,0.82,0)
  243.  
  244. mouse.Button1Up:connect(function()
  245. mup = true
  246. end)
  247.  
  248. function ragJoint(hit,r,d)
  249. Spawn(oc(function()
  250. d = d or 0
  251. local rpar,r0,r1 = r.Parent,r.Part0,r.Part1
  252. if d > 0 then wait(d) end
  253.  
  254. local p = hit:Clone()
  255. p:BreakJoints()
  256. p:ClearAllChildren()
  257. p.FormFactor = "Custom"
  258. p.Size = p.Size/2
  259. p.Transparency = 1
  260. p.CanCollide = true
  261. p.Name = "Colliduh"
  262. p.Parent = hit
  263. local w = Instance.new("Weld",p)
  264. w.Part0 = hit
  265. w.Part1 = p
  266. w.C0 = CFrame.new(0,-p.Size.Y/2,0)
  267.  
  268. local rot = Instance.new("Rotate",rpar)
  269. rot.Name = r.Name
  270. rot.Part0 = r0
  271. rot.Part1 = r1
  272. rot.C0 = r.C0
  273. rot.C1 = r.C1
  274. r0.Velocity = Vector3.new()
  275. r1.Velocity = Vector3.new()
  276. r:Destroy()
  277. end))
  278. end
  279.  
  280.  
  281. function ShootArrow(a,to,spd)
  282. Spawn(oc(function()
  283. local from = a.main.CFrame
  284. a:Destroy()
  285. local a = amodel:Clone()
  286. for i,v in pairs(a:GetChildren()) do
  287. if v:IsA("BasePart") then
  288. v.Anchored = true
  289. end
  290. end
  291. a:MakeJoints()
  292. a.Parent = workspace
  293. local m = a.main
  294. --local from = m.CFrame
  295. local t = {}
  296. local function move(cf)
  297. for i,v in pairs(a:GetChildren()) do
  298. if v ~= m and v:IsA("BasePart") then
  299. t[v] = t[v] or m.CFrame:toObjectSpace(v.CFrame)
  300. v.CFrame = cf * t[v]
  301. end
  302. end
  303. m.CFrame = cf
  304. end
  305. move(from)
  306. local velocity = (to.p-from.p).unit * spd * 500
  307. local con
  308. local t = tick()
  309. con = game:GetService("RunService").Stepped:connect(function()
  310. if tick()-t > 25 then
  311. con:disconnect()
  312. a:Destroy()
  313. return
  314. end
  315. velocity = velocity - Vector3.new(0,196.2/30,0)
  316. local newcf = clerp(m.CFrame,CFrame.new(m.Position,m.Position+velocity) * CFrame.Angles(-math.pi/2,0,0),.5) + velocity / 30
  317. local hit,ray
  318. local rayo = Ray.new(m.Position,newcf.p-m.Position)
  319. local ign = {a,char}
  320. repeat
  321. hit,ray = workspace:FindPartOnRayWithIgnoreList(rayo,ign)
  322. if not hit then break end
  323. if hit.CanCollide or game:GetService("Players"):GetPlayerFromCharacter(hit.Parent) then
  324. break
  325. else
  326. table.insert(ign,hit)
  327. hit = nil
  328. end
  329. until false
  330. if hit then
  331. move(newcf-newcf.p+ray)
  332. con:disconnect()
  333. game:GetService("Debris"):AddItem(a,300)
  334. local char = hit.Parent
  335. if not hit.Anchored then
  336. local b = hit.CFrame:toObjectSpace(m.CFrame)
  337. for i,v in pairs(a:GetChildren()) do
  338. pcall(function() v.Anchored = false v.CanCollide = true end)
  339. end
  340. weld(hit,m,b)
  341. end
  342. if game:service'Players':GetPlayerFromCharacter(char) and char:FindFirstChild("Torso") then
  343. if hit.Name:match("Arm") then
  344. local r = char.Torso:FindFirstChild(hit.Name:gsub("Arm","Shoulder"):gsub("Leg","Hip"))
  345. if r then
  346. ragJoint(hit,r)
  347. end
  348. elseif hit.Name:match("Head") then
  349. for i,v in pairs(char:GetChildren()) do
  350. local r = char.Torso:FindFirstChild(v.Name:gsub("Arm","Shoulder"):gsub("Leg","Hip"))
  351. if v:IsA("BasePart") and r then
  352. ragJoint(v,r,.1)
  353. elseif v:IsA("Humanoid") then
  354. v.PlatformStand = true
  355. v.Changed:connect(function()
  356. v.PlatformStand = true
  357. end)
  358. end
  359. end
  360. Delay(8,function()
  361. char:BreakJoints()
  362. end)
  363. end
  364. end
  365. return
  366. else
  367. move(newcf)
  368. end
  369. end)
  370. end))
  371. end
  372.  
  373. mouse.Button1Down:connect(oc(function()
  374. if mb then return end
  375. mb = true
  376. mup = false
  377. rls.Part0,rls.Part1 = nil,nil
  378. ls.Part0,ls.Part1 = tor,la
  379. ls.Parent = tor
  380. ls.C0 = ls.C0 * CFrame.Angles(0,0,rls.CurrentAngle)
  381. rrs.Part0,rrs.Part1 = nil,nil
  382. rs.Part0,rs.Part1 = tor,ra
  383. rs.Parent = tor
  384. rs.C0 = rs.C0 * CFrame.Angles(0,0,rrs.CurrentAngle)
  385. local hc0 = hold.C0
  386. local bg = Instance.new("BodyGyro",tor)
  387. bg.maxTorque = Vector3.new(1,1,1)*9e7
  388. local ltar = 0
  389. local rtar = rrs.C0 * CFrame.Angles(0,0,math.rad(90)) * CFrame.Angles(math.rad(70),0,0) + Vector3.new(-.65,.25,-.25)
  390. local ntar = nk0 * CFrame.Angles(0,0,math.rad(70))
  391. local htar = hc0 * CFrame.Angles(0,math.rad(10),0)
  392. local t = tick()
  393. local iam = 0
  394. local ham = .3
  395. local lend = false
  396. local ended
  397. local arr = amodel:Clone()
  398. arr.Parent = model
  399. arr:MakeJoints()
  400. hum.WalkSpeed = walkspeed/1.5
  401. local aw = weld(ra,arr.main,CFrame.new(0,-1,0)*CFrame.Angles(-math.pi/2,0,0),CFrame.new(0,-1.5,0))
  402. func = function()
  403. local a = (mouse.Hit.p-tor.CFrame:toWorldSpace(ls.C0).p).unit
  404. bg.cframe = CFrame.new(tor.Position,mouse.Hit.p*Vector3.new(1,0,1)+tor.Position*Vector3.new(0,1,0)) * CFrame.Angles(0,math.rad(-75),0)
  405. local b = math.min(.7,math.max(-.7,a.Y))
  406. ls.C0 = clerp(ls.C0,rls.C0 * CFrame.Angles(math.rad(-90),math.rad(90),math.rad(b*-90)) * CFrame.Angles(math.rad(40),math.rad(0),0) + Vector3.new(math.abs(b)*0,-.25,-.6),.3)
  407. local c = tor.CFrame:toObjectSpace(han.CFrame*hpos) * CFrame.new(0,0,0)
  408. local d = Vector3.new(1,.6,0)
  409. rs.C1 = CFrame.new()
  410. rs.C0 = clerp(rs.C0,CFrame.new(d,c.p) * CFrame.new(0,0,-(c.p-d).magnitude+.95) * CFrame.Angles(math.pi/2,math.pi/2,0),.3)
  411. nk.C0 = clerp(nk.C0,ntar * CFrame.Angles(math.rad(math.floor(b*-90)),0,0),.3)
  412. hold.C0 = clerp(hold.C0,htar,.3)
  413. for i,v in pairs(W) do
  414. -- v.C0 = clerp(v.C0,W0[i] * CFrame.Angles((not mup and (i>3 and 1 or -1)*iam or 0)*.1,0,0),.6)
  415. v.C0 = clerp(v.C0,W0[i] * CFrame.Angles((not mup and (i>3 and 1 or -1)*iam or 0)*.1,0,0),.6)
  416. end
  417. if not mup then
  418. hpos = clerp(hpos,hpos_l * CFrame.new(0,0,iam),.2)
  419. if aw then aw.C0 = CFrame.new(Vector3.new(0,-1,0),ra.CFrame:toObjectSpace(han.CFrame*CFrame.new(keeper)).p) * CFrame.Angles(-math.pi/2,0,0) end
  420. if tick()-t > .5 and iam < 1 then
  421. iam = iam + math.max(0.003,.03-(tick()-t-.5)/70)
  422. ham = iam
  423. if aw then
  424. aw:Destroy()
  425. arrw.Parent = han
  426. arrw.Part0 = han
  427. arrw.Part1 = arr.main
  428. aw = nil
  429. end
  430. end
  431. else
  432.  
  433. hpos = clerp(hpos,hpos_l,ham/math.max(0.01,(hpos.p-hpos_l.p).magnitude))
  434. ham = ham * .7
  435. if not ended then
  436. ended = true
  437. if iam > 0 then
  438. arrw.Part1 = nil
  439. ShootArrow(arr,mouse.Hit,iam)
  440. iam = iam + .2
  441. wait(.5)
  442. lend = true
  443. else
  444. wait(.1)
  445. arr:Destroy()
  446. lend = true
  447. end
  448. end
  449. end
  450. end
  451. repeat wait() until lend or tick()-t > 45
  452. mup = nil
  453. func = nil
  454. hum.WalkSpeed = walkspeed
  455. ls.Part0,ls.Part1 = nil,nil
  456. ls.Parent = nil
  457. rls.Part0,rls.Part1 = tor,la
  458. ls.C0 = rls.C0
  459. rs.Part0,rs.Part1 = nil,nil
  460. rs.Parent = nil
  461. rrs.Part0,rrs.Part1 = tor,ra
  462. rs.C0 = rrs.C0
  463. nk.C0 = nk0
  464. bg:Destroy()
  465. hold.C0 = hc0
  466. hpos = hpos_i
  467. mb = false
  468. end))
  469.  
  470. rcon = game:GetService("RunService").Stepped:connect(oc(function()
  471. if not model:IsDescendantOf(workspace) then rcon:disconnect() error() return end
  472. --local tc = bt.CFrame:toObjectSpace(tt.CFrame)
  473. --local bc = tt.CFrame:toObjectSpace(bt.CFrame)
  474. local bm = bt.CFrame:toObjectSpace(han.CFrame*hpos)
  475. local tm = tt.CFrame:toObjectSpace(han.CFrame*hpos)
  476. l1w.C0 = CFrame.new(bm.p/2,bm.p) * CFrame.Angles(math.pi/2,0,0)
  477. l1.Mesh.Scale = Vector3.new(.2,bm.p.magnitude*5,.2)
  478.  
  479. l2w.C0 = CFrame.new(tm.p/2,tm.p) * CFrame.Angles(math.pi/2,0,0)
  480. l2.Mesh.Scale = Vector3.new(.2,tm.p.magnitude*5,.2)
  481.  
  482. arrw.C0 = CFrame.new(hpos.p,keeper)*CFrame.new(0,0,-arrow.Size.Y/2) * CFrame.Angles(-math.pi/2,0,0)
  483. if func then
  484. func()
  485. end
  486. end))
Add Comment
Please, Sign In to add comment