Advertisement
mathmasterphil

Dragon Claw

Feb 22nd, 2015
344
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.37 KB | None | 0 0
  1. t = Instance.new("Tool")
  2. t.Parent = game.Players.mathmasterphil.Backpack
  3. t.Name = "Claw"
  4.  
  5. local handlee = Instance.new("Part")
  6. handlee.Name = "Handle"
  7. handlee.Parent = t
  8. handlee.BrickColor = BrickColor.new("Really red")
  9. handlee.Size = Vector3.new(1, 1, 2)
  10. handlee.TopSurface = "Smooth"
  11. handlee.BottomSurface = "Smooth"
  12. handlee.Transparency = 0
  13. handlee.Reflectance = 0
  14. -----------------------------------------mesh
  15. m = Instance.new("BlockMesh")
  16. m.Parent = handlee
  17. m.Scale = Vector3.new(0.2, 0.2, 1)
  18. -----------------------------------------Brick2
  19. local brick3 = Instance.new("Part")
  20. brick3.Name = "Part"
  21. brick3.Parent = t
  22. brick3.formFactor = "Plate"
  23. brick3.BrickColor = BrickColor.new("Really red")
  24. brick3.Size = Vector3.new(1, 1, 2)
  25. brick3.TopSurface = "Smooth"
  26. brick3.BottomSurface = "Smooth"
  27. brick3.Transparency = 0
  28. brick3.Reflectance = 0
  29. -----------------------------------------mesh
  30. m = Instance.new("BlockMesh")
  31. m.Parent = brick3
  32. m.Scale = Vector3.new(0.2, 0.2, 1)
  33. -----------------------------------------weld
  34. w2 = Instance.new("Weld")
  35. w2.Parent = handlee
  36. w2.Part0 = brick3
  37. w2.Part1 = handlee
  38. w2.C0 = CFrame.fromEulerAnglesXYZ(0, 0, 0) + Vector3.new(-0.3, 0, 0)
  39. -----------------------------------------Brick2
  40. local brick4 = Instance.new("Part")
  41. brick4.Name = "Part"
  42. brick4.Parent = t
  43. brick4.formFactor = "Plate"
  44. brick4.BrickColor = BrickColor.new("Really red")
  45. brick4.Size = Vector3.new(1, 1, 2)
  46. brick4.TopSurface = "Smooth"
  47. brick4.BottomSurface = "Smooth"
  48. brick4.Transparency = 0
  49. brick4.Reflectance = 0
  50. -----------------------------------------mesh
  51. m = Instance.new("BlockMesh")
  52. m.Parent = brick4
  53. m.Scale = Vector3.new(0.2, 0.2, 1)
  54. -----------------------------------------weld
  55. w2 = Instance.new("Weld")
  56. w2.Parent = handlee
  57. w2.Part0 = brick4
  58. w2.Part1 = handlee
  59. w2.C0 = CFrame.fromEulerAnglesXYZ(0, 0, 0) + Vector3.new(0.3, 0, 0)
  60.  
  61. ---------------------Part 2
  62. ---------------------Part 2
  63. ---------------------Part 2
  64.  
  65. r = game:service("RunService")
  66.  
  67.  
  68. local damage = 100000
  69.  
  70.  
  71. local slash_damage = 100000
  72.  
  73.  
  74. sword = brick4
  75. Tool = t
  76.  
  77. function attack()
  78. local anim = Instance.new("StringValue")
  79. anim.Name = "toolanim"
  80. anim.Value = "Slash"
  81. anim.Parent = Tool
  82. end
  83.  
  84. function lunge()
  85. local anim = Instance.new("StringValue")
  86. anim.Name = "toolanim"
  87. anim.Value = "Lunge"
  88. anim.Parent = Tool
  89. end
  90.  
  91.  
  92. function swordUp()
  93. Tool.GripForward = Vector3.new(-1,0,0)
  94. Tool.GripRight = Vector3.new(0,1,0)
  95. Tool.GripUp = Vector3.new(0,0,1)
  96. end
  97.  
  98. function swordOut()
  99. Tool.GripForward = Vector3.new(0,0,1)
  100. Tool.GripRight = Vector3.new(0,-1,0)
  101. Tool.GripUp = Vector3.new(-1,0,0)
  102. end
  103.  
  104.  
  105.  
  106. Tool.Enabled = true
  107.  
  108. function onActivated()
  109.  
  110. if not Tool.Enabled then
  111. return
  112. end
  113.  
  114. Tool.Enabled = false
  115.  
  116. local character = Tool.Parent;
  117. local humanoid = character.Humanoid
  118. if humanoid == nil then
  119. print("Humanoid not found")
  120. return
  121. end
  122.  
  123.  
  124. m = math.random(1, 2)
  125. if m == 1 then
  126. attack()
  127. elseif m == 2 then
  128. lunge()
  129. end
  130.  
  131. wait()
  132.  
  133. Tool.Enabled = true
  134. end
  135.  
  136.  
  137. function onEquipped()
  138.  
  139. end
  140.  
  141.  
  142. ------part 3
  143. ------part 3
  144. ------part 3
  145. function onTouched(hit)
  146. h = hit.Parent:findFirstChild("Humanoid")
  147. if h ~= nil then
  148. h:TakeDamage(25)
  149. end
  150. end
  151.  
  152.  
  153. Tool.Activated:connect(onActivated)
  154. Tool.Equipped:connect(onEquipped)
  155. sword.Touched:connect(onTouched)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement