Advertisement
DaLittleTem

Untitled

May 14th, 2016
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 24.46 KB | None | 0 0
  1. local players = game:GetService("Players")
  2.  
  3. local workspac = game:GetService("Workspace")
  4.  
  5. Me = players.adimihai
  6.  
  7. char = Me.Character
  8.  
  9. name = Me.Name
  10.  
  11. local pg = Me.PlayerGui
  12.  
  13. local human = char.Humanoid
  14.  
  15. Torso = char.Torso
  16.  
  17. Rarm = char["Right Arm"]
  18.  
  19. Larm = char["Left Arm"]
  20.  
  21. Rleg = char["Right Leg"]
  22.  
  23. Lleg = char["Left Leg"]
  24.  
  25. local nummovs = 6
  26.  
  27. local mov = 1
  28.  
  29. local peno = false
  30.  
  31. local currmov = 1
  32.  
  33. local attakin = false
  34.  
  35. local asset = "http://roblox.com/asset/?id="
  36.  
  37. local sounds = {
  38.  
  39. Gun = "2760979",
  40.  
  41. Gun2 = "10209859",
  42.  
  43. Click = "12222076",
  44.  
  45. Imbue = "2785493",
  46.  
  47. Ele = "2800815",
  48.  
  49. Curse = "13775494",
  50.  
  51. Slash = "rbxasset://sounds/swordslash.wav",
  52.  
  53. Bow = "16211041"
  54.  
  55. }
  56.  
  57. function sound(id)
  58.  
  59. local sound = Instance.new("Sound", Torso)
  60.  
  61. sound.SoundId = id
  62.  
  63. sound.Volume = 0.5
  64.  
  65. sound:play()
  66.  
  67. sound:stop()
  68.  
  69. wait()
  70.  
  71. sound:play()
  72.  
  73. coroutine.resume(coroutine.create(function()
  74.  
  75. wait(1)
  76.  
  77. sound:remove()
  78.  
  79. end))
  80.  
  81. end
  82.  
  83. function create(prt, parent, siz, cf, can, col, anc, brea, tran, ref, form, weld, part1, cf2, mesh, sca, type, id, bckup)
  84.  
  85. part = Instance.new(prt)
  86.  
  87. part.formFactor = form
  88.  
  89. part.BrickColor = BrickColor.new(col)
  90.  
  91. part.Size = siz
  92.  
  93. part.Anchored = anc
  94.  
  95. part.Transparency = tran
  96.  
  97. part.Name = "ShipPart"
  98.  
  99. part.Reflectance = ref
  100.  
  101. part.CFrame = cf
  102.  
  103. part.CanCollide = can
  104.  
  105. part.TopSurface = "Smooth"
  106.  
  107. part.BottomSurface = "Smooth"
  108.  
  109. if brea == true then
  110.  
  111. part:BreakJoints()
  112.  
  113. end
  114.  
  115. if weld == true then
  116.  
  117. weld = Instance.new("Weld")
  118.  
  119. weld.Part0 = part
  120.  
  121. weld.Part1 = part1
  122.  
  123. weld.C1 = cf2
  124.  
  125. weld.Parent = part
  126.  
  127. end
  128.  
  129. if mesh ~= nil then
  130.  
  131. mesh = Instance.new(mesh)
  132.  
  133. mesh.Scale = sca
  134.  
  135. if bckup == true then
  136.  
  137. mesh.MeshType = "Sphere"
  138.  
  139. end
  140.  
  141. if mesh == "SpecialMesh" then
  142.  
  143. mesh.MeshType = type
  144.  
  145. pcall(function()
  146.  
  147. if type == "Wedge" then
  148.  
  149. mesh.MeshType = "Wedge"
  150.  
  151. end
  152.  
  153. if type == "FileMesh" then
  154.  
  155. mesh.MeshType = "FileMesh"
  156.  
  157. mesh.MeshId = id
  158.  
  159. end
  160.  
  161. end)
  162.  
  163. end
  164.  
  165. mesh.Parent = part
  166.  
  167. end
  168.  
  169. part.Parent = parent
  170.  
  171. return part,weld
  172.  
  173. end
  174.  
  175. pcall(function() char[":P"]:remove() end)
  176.  
  177. pcall(function() char["Pen"]:remove() end)
  178.  
  179. local Model = Instance.new("Model",char)
  180.  
  181. Model.Name = ":P"
  182.  
  183. local Model2 = Instance.new("Model",char)
  184.  
  185. Model2.Name = "Pen"
  186.  
  187. local Model3 = Instance.new("Model",Model2)
  188.  
  189. Model3.Name = "Staff"
  190.  
  191. local Model4 = Instance.new("Model",Model2)
  192.  
  193. Model4.Name = "Sword"
  194.  
  195. local Model5 = Instance.new("Model",Model2)
  196.  
  197. Model5.Name = "Bow"
  198.  
  199. local Model6 = Instance.new("Model",Model2)
  200.  
  201. Model6.Name = "Lantern"
  202.  
  203. local Model7 = Instance.new("Model",Model2)
  204.  
  205. Model7.Name = "Gun"
  206.  
  207. local RAB = Instance.new("Part") -- Right Arm Brick
  208.  
  209. RAB.formFactor = "Custom"
  210.  
  211. RAB.Size = Vector3.new(0.2, 0.2, 0.2)
  212.  
  213. RAB.Transparency = 1
  214.  
  215. RAB.Parent = Model
  216.  
  217. RAB:BreakJoints()
  218.  
  219. local RABW = Instance.new("Weld",RAB) -- Right Arm Brick Weld
  220.  
  221. RABW.Part0 = Torso
  222.  
  223. RABW.Part1 = RAB
  224.  
  225. RABW.C1 = CFrame.new(-1.5, -0.5, 0)
  226.  
  227. local LAB = Instance.new("Part") -- Right Arm Brick
  228.  
  229. LAB.formFactor = "Custom"
  230.  
  231. LAB.Size = Vector3.new(0.2, 0.2, 0.2)
  232.  
  233. LAB.Transparency = 1
  234.  
  235. LAB.Parent = Model
  236.  
  237. LAB:BreakJoints()
  238.  
  239. local LABW = Instance.new("Weld",LAB) -- Left Arm Brick Weld
  240.  
  241. LABW.Part0 = Torso
  242.  
  243. LABW.Part1 = LAB
  244.  
  245. LABW.C1 = CFrame.new(1.5, -0.5, 0)
  246.  
  247. local RAW = Instance.new("Weld",RAB) -- Right Arm Weld
  248.  
  249. RAW.Part0 = RAB
  250.  
  251. RAW.Part1 = nil
  252.  
  253. RAW.C1 = CFrame.new(0, 0.5, 0)
  254.  
  255. local LAW = Instance.new("Weld",LAB) -- Left Arm Weld
  256.  
  257. LAW.Part0 = LAB
  258.  
  259. LAW.Part1 = nil
  260.  
  261. LAW.C1 = CFrame.new(0, 0.5, 0)
  262.  
  263. --pen
  264.  
  265. local shaft = create("Part", Model2, Vector3.new(0.2, 1, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 0, 0, "Custom", true, Rarm, CFrame.new(0,-1,0)*CFrame.Angles(math.rad(90),0,0), "CylinderMesh", Vector3.new(0.5,1,0.5), derp, id, bckup)
  266.  
  267. local shaft2 = create("Part", Model2, Vector3.new(0.2, 0.25, 0.2), CFrame.new(0,0,0), false, "Black", false, true, 0, 0, "Custom", true, shaft, CFrame.new(0,-0.3749,0.05)*CFrame.Angles(math.rad(0),0,0), "BlockMesh", Vector3.new(0.25,1,0.25), derp, id, bckup)
  268.  
  269. local shaft3 = create("Part", Model2, Vector3.new(0.2, 0.2, 0.2), CFrame.new(0,0,0), false, "Black", false, true, 0, 0, "Custom", true, shaft, CFrame.new(0,-0.425,0)*CFrame.Angles(math.rad(0),0,0), "CylinderMesh", Vector3.new(0.3,1,0.3), derp, id, bckup)
  270.  
  271. local shaft4 = create("Part", Model2, Vector3.new(0.2, 0.2, 0.2), CFrame.new(0,0,0), false, "Black", false, true, 0, 0, "Custom", true, shaft, CFrame.new(0,0.55,0)*CFrame.Angles(math.rad(0),0,0), "SpecialMesh", Vector3.new(0.05,0.15,0.05), "FileMesh", "http://www.roblox.com/asset/?id=1033714", bckup)
  272.  
  273. shaft4.Mesh.MeshId = "http://www.roblox.com/asset/?id=1033714"
  274.  
  275. local led, ledw = create("Part", Model2, Vector3.new(0.2, 0.5, 0.2), CFrame.new(0,0,0), false, "Mid stone grey", false, true, 0, 0, "Custom", true, shaft, CFrame.new(0,0.375,0)*CFrame.Angles(math.rad(0),0,0), "CylinderMesh", Vector3.new(0.05,1,0.05), "FileMesh", "http://www.roblox.com/asset/?id=1033714", bckup)
  276.  
  277. --staff
  278.  
  279. local han = create("Part", Model3, Vector3.new(0.25, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, Rarm, CFrame.new(0,-1,0)*CFrame.Angles(math.rad(90),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  280.  
  281. local han2 = create("Part", Model3, Vector3.new(0.5, 0.25, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,0.75,0)*CFrame.Angles(math.rad(0),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  282.  
  283. local han3 = create("Part", Model3, Vector3.new(0.35, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,1.5,0.05)*CFrame.Angles(math.rad(0),0,0), "SpecialMesh", Vector3.new(1,1,1), "Wedge", id, bckup)
  284.  
  285. han3.Mesh.MeshType = "Wedge"
  286.  
  287. local han4 = create("Part", Model3, Vector3.new(0.35, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,1.5,-0.05)*CFrame.Angles(math.rad(0),math.rad(180),0), "SpecialMesh", Vector3.new(1,1,1), "Wedge", id, bckup)
  288.  
  289. han4.Mesh.MeshType = "Wedge"
  290.  
  291. local han5 = create("Part", Model3, Vector3.new(0.5, 0.25, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.75,0)*CFrame.Angles(math.rad(0),0,0), "BlockMesh", Vector3.new(1,1,1), derp, id, bckup)
  292.  
  293. for i = 1, 6 do
  294.  
  295. local han6 = create("Part", Model3, Vector3.new(0.5, 0.25, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.75-(0.25*i),0)*CFrame.Angles(math.rad(45*i),0,0), "BlockMesh", Vector3.new(1-(0.1*i),1,1), derp, id, bckup)
  296.  
  297. end
  298.  
  299. for i = 1, 6 do
  300.  
  301. local han6 = create("Part", Model3, Vector3.new(0.35, 0.1, 0.35), CFrame.new(0,0,0), false, "Black", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.75+(0.25*i),0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,0.5,1), derp, id, bckup)
  302.  
  303. end
  304.  
  305. for i = 1, 7 do
  306.  
  307. local han6 = create("Part", Model3, Vector3.new(0.26, 0.1, 0.26), CFrame.new(0,0,0), false, "Black", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.6+(0.15*i),0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,0.5,1), derp, id, bckup)
  308.  
  309. end
  310.  
  311. local han7 = create("Part", Model3, Vector3.new(0.5, 0.5, 0.5), CFrame.new(0,0,0), false, "Navy blue", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-2.5,0)*CFrame.Angles(math.rad(0),0,0), "SpecialMesh", Vector3.new(1.5,2,1.5), derp, id, bckup)
  312.  
  313. han7.Mesh.MeshType = "Sphere"
  314.  
  315. han7.Name = "Orb"
  316.  
  317. --sword
  318.  
  319. local han = create("Part", Model4, Vector3.new(0.25, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, Rarm, CFrame.new(0,-1,0)*CFrame.Angles(math.rad(90),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  320.  
  321. local han2 = create("Part", Model4, Vector3.new(0.5, 0.25, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.85,0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(90)), "SpecialMesh", Vector3.new(1,1,1), "Torso", id, bckup)
  322.  
  323. local han3 = create("Part", Model4, Vector3.new(0.5, 0.25, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han2, CFrame.new(0,0,0.25)*CFrame.Angles(math.rad(90),0,math.rad(-45)), "SpecialMesh", Vector3.new(1,1,1), "Torso", id, bckup)
  324.  
  325. han3.Mesh.MeshType = "Torso"
  326.  
  327. local han4 = create("Part", Model4, Vector3.new(0.5, 0.25, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han2, CFrame.new(0,0,-0.25)*CFrame.Angles(math.rad(90),0,math.rad(-135)), "SpecialMesh", Vector3.new(1,1,1), "Torso", id, bckup)
  328.  
  329. han4.Mesh.MeshType = "Torso"
  330.  
  331. local han5 = create("Part", Model4, Vector3.new(0.3, 3, 0.2), CFrame.new(0,0,0), false, "Mid stone grey", false, true, 1, 0, "Custom", true, han2, CFrame.new(-1.5,0,0)*CFrame.Angles(math.rad(90),math.rad(0),math.rad(90)), "SpecialMesh", Vector3.new(1,1,1), "Torso", id, bckup)
  332.  
  333. han5.Mesh.MeshType = "Torso"
  334.  
  335. han5.Name = "Blade"
  336.  
  337. local han7 = create("Part", Model4, Vector3.new(0.3, 0.275, 0.3), CFrame.new(0,0,0), false, "New Yeller", false, true, 1, 0, "Custom", true, han2, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0),0), "SpecialMesh", Vector3.new(1,1,1), "Torso", id, bckup)
  338.  
  339. --bow
  340.  
  341. local han = create("Part", Model5, Vector3.new(0.25, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, Rarm, CFrame.new(0,-1,0)*CFrame.Angles(math.rad(90),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  342.  
  343. local han2 = create("Part", Model5, Vector3.new(0.25, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-1.2,-0.5)*CFrame.Angles(math.rad(45),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  344.  
  345. local han3 = create("Part", Model5, Vector3.new(0.25, 1.5, 0.25), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,1.2,-0.5)*CFrame.Angles(math.rad(-45),0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  346.  
  347. local han4 = create("Part", Model5, Vector3.new(0.2, 3.25, 0.2), CFrame.new(0,0,0), false, "White", false, true, 1, 0, "Custom", true, han, CFrame.new(0,0,-1)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(0.5,1,0.5), derp, id, bckup)
  348.  
  349. local han5 = create("Part", Model5, Vector3.new(0.26, 1, 0.26), CFrame.new(0,0,0), false, "Black", false, true, 1, 0, "Custom", true, han, CFrame.new(0,0,0)*CFrame.Angles(0, 0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  350.  
  351. --lantern
  352.  
  353. local han = create("Part", Model6, Vector3.new(0.5, 0.5, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, Rarm, CFrame.new(0,-1,0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  354.  
  355. local han2 = create("Part", Model6, Vector3.new(0.75, 0.25, 0.75), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.25,0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  356.  
  357. local han3 = create("Part", Model6, Vector3.new(0.6, 1, 0.6), CFrame.new(0,0,0), false, "White", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.65,0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  358.  
  359. han3.Name = "Glass"
  360.  
  361. local han4 = create("Part", Model6, Vector3.new(0.75, 0.25, 0.75), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han3, CFrame.new(0,-0.5,0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  362.  
  363. local han5 = create("Part", Model6, Vector3.new(0.5, 0.25, 0.5), CFrame.new(0,0,0), false, "Reddish brown", false, true, 1, 0, "Custom", true, han4, CFrame.new(0,-0.25,0)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  364.  
  365. local bill = Instance.new("BillboardGui", han3)
  366.  
  367. bill.Name = "Light"
  368.  
  369. bill.Size = UDim2.new(10, 0, 10, 0)
  370.  
  371. bill.Enabled = false
  372.  
  373. local l1 = Instance.new("ImageLabel", bill)
  374.  
  375. l1.Image = "http://www.roblox.com/asset/?id=42835416"
  376.  
  377. l1.Size = UDim2.new(2, 0, 2, 0)
  378.  
  379. l1.Position = UDim2.new(-0.5, 0, -0.5, 0)
  380.  
  381. l1.ZIndex = 0
  382.  
  383. l1.BackgroundTransparency = 1
  384.  
  385. --gun
  386.  
  387. local han = create("Part", Model7, Vector3.new(0.2, 0.3, 0.75), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, Rarm, CFrame.new(0,-1.1,0)*CFrame.Angles(0,0,0), "BlockMesh", Vector3.new(1,1,1), derp, id, bckup)
  388.  
  389. local han2z = create("Part", Model7, Vector3.new(0.2, 1, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.5,-0.35)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(1,1,1), derp, id, bckup)
  390.  
  391. local han3 = create("Part", Model7, Vector3.new(0.2, 0.75, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.35,-0.25)*CFrame.Angles(0,0,0), "CylinderMesh", Vector3.new(0.75,1,0.75), derp, id, bckup)
  392.  
  393. local han4 = create("Part", Model7, Vector3.new(0.2, 0.2, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.15,-0.15)*CFrame.Angles(math.rad(-45),0,0), "BlockMesh", Vector3.new(0.25,1,0.15), derp, id, bckup)
  394.  
  395. local han5 = create("Part", Model7, Vector3.new(0.2, 0.25, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.225,0.025)*CFrame.Angles(math.rad(45),0,0), "BlockMesh", Vector3.new(0.25,1,0.15), derp, id, bckup)
  396.  
  397. local han6 = create("Part", Model7, Vector3.new(0.2, 0.2, 0.2), CFrame.new(0,0,0), false, "Dark stone grey", false, true, 1, 0, "Custom", true, han, CFrame.new(0,-0.31125,-0.15)*CFrame.Angles(math.rad(90),0,0), "BlockMesh", Vector3.new(0.25,1,0.15), derp, id, bckup)
  398.  
  399. local han7 = create("Part", Model7, Vector3.new(0.201, 0.275, 0.6), CFrame.new(0,0,0), false, "Black", false, true, 1, 0, "Custom", true, han, CFrame.new(0,0,0.05)*CFrame.Angles(0,0,0), "BlockMesh", Vector3.new(1,1,1), derp, id, bckup)
  400.  
  401.  
  402. function pen()
  403.  
  404. for _,v in pairs(Model3:children()) do
  405.  
  406. coroutine.resume(coroutine.create(function()
  407.  
  408. v.Transparency = 1
  409.  
  410. end))
  411.  
  412. end
  413.  
  414. for _,c in pairs(Model6:children()) do
  415.  
  416. pcall(function()
  417.  
  418. c.Transparency = 1
  419.  
  420. c.Light.Enabled = false
  421.  
  422. end)
  423.  
  424. end
  425.  
  426. for _,v in pairs(Model7:children()) do
  427.  
  428. coroutine.resume(coroutine.create(function()
  429.  
  430. v.Transparency = 1
  431.  
  432. end))
  433.  
  434. end
  435.  
  436. for _,v in pairs(Model4:children()) do
  437.  
  438. coroutine.resume(coroutine.create(function()
  439.  
  440. v.Transparency = 1
  441.  
  442. end))
  443.  
  444. end
  445.  
  446. for _,v in pairs(Model5:children()) do
  447.  
  448. coroutine.resume(coroutine.create(function()
  449.  
  450. v.Transparency = 1
  451.  
  452. end))
  453.  
  454. end
  455.  
  456. for _,c in pairs(Model2:children()) do
  457.  
  458. coroutine.resume(coroutine.create(function()
  459.  
  460. for i = 1, 10 do
  461.  
  462. c.Transparency = 1-(0.1*i)
  463.  
  464. wait()
  465.  
  466. end
  467.  
  468. end))
  469.  
  470. end
  471.  
  472. end
  473.  
  474. function staff()
  475.  
  476. for _,v in pairs(Model3:children()) do
  477.  
  478. coroutine.resume(coroutine.create(function()
  479.  
  480. for i = 1, 10 do
  481.  
  482. v.Transparency = 1-(0.1*i)
  483.  
  484. wait()
  485.  
  486. end
  487.  
  488. if v.Name == "Orb" then
  489.  
  490. v.Transparency = 0.5
  491.  
  492. end
  493.  
  494. end))
  495.  
  496. end
  497.  
  498. for _,v in pairs(Model5:children()) do
  499.  
  500. coroutine.resume(coroutine.create(function()
  501.  
  502. v.Transparency = 1
  503.  
  504. end))
  505.  
  506. end
  507.  
  508. for _,c in pairs(Model2:children()) do
  509.  
  510. coroutine.resume(coroutine.create(function()
  511.  
  512. c.Transparency = 1
  513.  
  514. end))
  515.  
  516. end
  517.  
  518. for _,c in pairs(Model6:children()) do
  519.  
  520. pcall(function()
  521.  
  522. c.Transparency = 1
  523.  
  524. c.Light.Enabled = false
  525.  
  526. end)
  527.  
  528. end
  529.  
  530. for _,v in pairs(Model7:children()) do
  531.  
  532. coroutine.resume(coroutine.create(function()
  533.  
  534. v.Transparency = 1
  535.  
  536. end))
  537.  
  538. end
  539.  
  540. for _,c in pairs(Model4:children()) do
  541.  
  542. pcall(function()
  543.  
  544. c.Transparency = 1
  545.  
  546. wait()
  547.  
  548. end)
  549.  
  550. end
  551.  
  552. end
  553.  
  554. function sword()
  555.  
  556. for _,v in pairs(Model4:children()) do
  557.  
  558. coroutine.resume(coroutine.create(function()
  559.  
  560. for i = 1, 10 do
  561.  
  562. v.Transparency = 1-(0.1*i)
  563.  
  564. wait()
  565.  
  566. end
  567.  
  568. end))
  569.  
  570. end
  571.  
  572. for _,c in pairs(Model2:children()) do
  573.  
  574. pcall(function()
  575.  
  576. c.Transparency = 1
  577.  
  578. end)
  579.  
  580. end
  581.  
  582. for _,v in pairs(Model5:children()) do
  583.  
  584. pcall(function()
  585.  
  586. v.Transparency = 1
  587.  
  588. end)
  589.  
  590. end
  591.  
  592. for _,c in pairs(Model6:children()) do
  593.  
  594. pcall(function()
  595.  
  596. c.Transparency = 1
  597.  
  598. c.Light.Enabled = false
  599.  
  600. end)
  601.  
  602. end
  603.  
  604. for _,v in pairs(Model7:children()) do
  605.  
  606. coroutine.resume(coroutine.create(function()
  607.  
  608. v.Transparency = 1
  609.  
  610. end))
  611.  
  612. end
  613.  
  614. for _,c in pairs(Model3:children()) do
  615.  
  616. pcall(function()
  617.  
  618. c.Transparency = 1
  619.  
  620. end)
  621.  
  622. end
  623.  
  624. end
  625.  
  626. function bow()
  627.  
  628. for _,v in pairs(Model5:children()) do
  629.  
  630. coroutine.resume(coroutine.create(function()
  631.  
  632. for i = 1, 10 do
  633.  
  634. v.Transparency = 1-(0.1*i)
  635.  
  636. wait()
  637.  
  638. end
  639.  
  640. end))
  641.  
  642. end
  643.  
  644. for _,c in pairs(Model2:children()) do
  645.  
  646. pcall(function()
  647.  
  648. c.Transparency = 1
  649.  
  650. end)
  651.  
  652. end
  653.  
  654. for _,c in pairs(Model6:children()) do
  655.  
  656. pcall(function()
  657.  
  658. c.Transparency = 1
  659.  
  660. c.Light.Enabled = false
  661.  
  662. end)
  663.  
  664. end
  665.  
  666. for _,v in pairs(Model7:children()) do
  667.  
  668. coroutine.resume(coroutine.create(function()
  669.  
  670. v.Transparency = 1
  671.  
  672. end))
  673.  
  674. end
  675.  
  676. for _,c in pairs(Model3:children()) do
  677.  
  678. pcall(function()
  679.  
  680. c.Transparency = 1
  681.  
  682. end)
  683.  
  684. end
  685.  
  686. for _,c in pairs(Model4:children()) do
  687.  
  688. pcall(function()
  689.  
  690. c.Transparency = 1
  691.  
  692. end)
  693.  
  694. end
  695.  
  696. end
  697.  
  698. function lamp()
  699.  
  700. for _,v in pairs(Model6:children()) do
  701.  
  702. coroutine.resume(coroutine.create(function()
  703.  
  704. for i = 1, 10 do
  705.  
  706. v.Transparency = 1-(0.1*i)
  707.  
  708. wait()
  709.  
  710. end
  711.  
  712. if v.Name == "Glass" then
  713.  
  714. v.Transparency = 0.5
  715.  
  716. v.Light.Enabled = true
  717.  
  718. end
  719.  
  720. end))
  721.  
  722. end
  723.  
  724. for _,v in pairs(Model7:children()) do
  725.  
  726. coroutine.resume(coroutine.create(function()
  727.  
  728. v.Transparency = 1
  729.  
  730. end))
  731.  
  732. end
  733.  
  734. for _,c in pairs(Model2:children()) do
  735.  
  736. pcall(function()
  737.  
  738. c.Transparency = 1
  739.  
  740. end)
  741.  
  742. end
  743.  
  744. for _,c in pairs(Model3:children()) do
  745.  
  746. pcall(function()
  747.  
  748. c.Transparency = 1
  749.  
  750. end)
  751.  
  752. end
  753.  
  754. for _,c in pairs(Model4:children()) do
  755.  
  756. pcall(function()
  757.  
  758. c.Transparency = 1
  759.  
  760. end)
  761.  
  762. end
  763.  
  764. for _,c in pairs(Model5:children()) do
  765.  
  766. pcall(function()
  767.  
  768. c.Transparency = 1
  769.  
  770. end)
  771.  
  772. end
  773.  
  774. end
  775.  
  776. function gun()
  777.  
  778. for _,v in pairs(Model7:children()) do
  779.  
  780. coroutine.resume(coroutine.create(function()
  781.  
  782. for i = 1, 10 do
  783.  
  784. v.Transparency = 1-(0.1*i)
  785.  
  786. wait()
  787.  
  788. end
  789.  
  790. end))
  791.  
  792. end
  793.  
  794. for _,v in pairs(Model6:children()) do
  795.  
  796. coroutine.resume(coroutine.create(function()
  797.  
  798. v.Transparency = 1
  799.  
  800. v.Light.Enabled = false
  801.  
  802. end))
  803.  
  804. end
  805.  
  806. for _,c in pairs(Model2:children()) do
  807.  
  808. pcall(function()
  809.  
  810. c.Transparency = 1
  811.  
  812. end)
  813.  
  814. end
  815.  
  816. for _,c in pairs(Model3:children()) do
  817.  
  818. pcall(function()
  819.  
  820. c.Transparency = 1
  821.  
  822. end)
  823.  
  824. end
  825.  
  826. for _,c in pairs(Model4:children()) do
  827.  
  828. pcall(function()
  829.  
  830. c.Transparency = 1
  831.  
  832. end)
  833.  
  834. end
  835.  
  836. for _,c in pairs(Model5:children()) do
  837.  
  838. pcall(function()
  839.  
  840. c.Transparency = 1
  841.  
  842. end)
  843.  
  844. end
  845.  
  846. end
  847.  
  848. coroutine.resume(coroutine.create(function()
  849.  
  850. while wait() do
  851.  
  852. pcall(function()
  853.  
  854. if mov ~= currmov then
  855.  
  856. currmov = mov
  857.  
  858. if mov == 1 then
  859.  
  860. pen()
  861.  
  862. elseif mov == 2 then
  863.  
  864. staff()
  865.  
  866. elseif mov == 3 then
  867.  
  868. sword()
  869.  
  870. elseif mov == 4 then
  871.  
  872. bow()
  873.  
  874. elseif mov == 5 then
  875.  
  876. lamp()
  877.  
  878. elseif mov == 6 then
  879.  
  880. gun()
  881.  
  882. end
  883.  
  884. end
  885.  
  886. end)
  887.  
  888. end
  889.  
  890. end))
  891.  
  892. function dmg(pos, mag, dmg)
  893.  
  894. for _,v in pairs(workspace:children()) do
  895.  
  896. pcall(function()
  897.  
  898. if (v.Torso.Position - pos).magnitude <= mag then
  899.  
  900. if v.Name ~= Me.Name then
  901.  
  902. v.Humanoid:TakeDamage(dmg)
  903.  
  904. end
  905.  
  906. end
  907.  
  908. end)
  909.  
  910. end
  911.  
  912. end
  913.  
  914. function shoot(targ)
  915.  
  916. sound(asset..sounds["Gun2"])
  917.  
  918. local ray = Instance.new("Part", workspace)
  919.  
  920. ray.Name = "Shot"
  921.  
  922. ray.BrickColor = BrickColor.new("New Yeller")
  923.  
  924. ray.formFactor = "Custom"
  925.  
  926. ray.Size = Vector3.new(0.2, 0.2, (targ - han2z.Position).magnitude)
  927.  
  928. ray.CanCollide = false
  929.  
  930. ray.Anchored = true
  931.  
  932. local cf = han2z.CFrame * CFrame.new(0, -0.5, 0)
  933.  
  934. ray.CFrame = CFrame.new((cf.p + targ) / 2, targ)
  935.  
  936. local raym = Instance.new("BlockMesh", ray)
  937.  
  938. raym.Scale = Vector3.new(0.5, 0.5, 1)
  939.  
  940. dmg(targ, 1, math.random(5,15))
  941.  
  942. coroutine.resume(coroutine.create(function()
  943.  
  944. wait(0.15)
  945.  
  946. ray:remove()
  947.  
  948. end))
  949.  
  950. end
  951.  
  952. function arrow(targ)
  953.  
  954. sound(asset..sounds["Bow"])
  955.  
  956. local ray = Instance.new("Part", workspace)
  957.  
  958. ray.Name = "Shot"
  959.  
  960. ray.BrickColor = BrickColor.new("White")
  961.  
  962. ray.formFactor = "Custom"
  963.  
  964. ray.Transparency = 0.5
  965.  
  966. ray.Size = Vector3.new(0.2, 0.2, (targ - Rarm.Position).magnitude)
  967.  
  968. ray.CanCollide = false
  969.  
  970. ray.Anchored = true
  971.  
  972. local cf = Rarm.CFrame * CFrame.new(0, -0.5, 0)
  973.  
  974. ray.CFrame = CFrame.new((cf.p + targ) / 2, targ)
  975.  
  976. local raym = Instance.new("BlockMesh", ray)
  977.  
  978. raym.Scale = Vector3.new(0.5, 0.5, 1)
  979.  
  980. dmg(targ, 1, math.random(7, 21))
  981.  
  982. coroutine.resume(coroutine.create(function()
  983.  
  984. wait(0.15)
  985.  
  986. ray:remove()
  987.  
  988. end))
  989.  
  990. end
  991.  
  992. function orb(pos)
  993.  
  994. sound(asset..sounds["Ele"])
  995.  
  996. coroutine.resume(coroutine.create(function()
  997.  
  998. local ball = Instance.new("Part", workspace)
  999.  
  1000. ball.formFactor = "Custom"
  1001.  
  1002. ball.BrickColor = BrickColor.new("Really red")
  1003.  
  1004. ball.Size = Vector3.new(1.5,1.5,1.5)
  1005.  
  1006. ball.Name = "Spell"
  1007.  
  1008. ball.CanCollide = true
  1009.  
  1010. ball.CFrame = Model3.Orb.CFrame
  1011.  
  1012. ball:BreakJoints()
  1013.  
  1014. local ballp = Instance.new("BodyPosition", ball)
  1015.  
  1016. ballp.position = pos
  1017.  
  1018. ballp.maxForce = Vector3.new(1000, 50000, 1000)
  1019.  
  1020. local ballm = Instance.new("SpecialMesh", ball)
  1021.  
  1022. ballm.MeshType = "Sphere"
  1023.  
  1024. ball.Touched:connect(function(hit)
  1025.  
  1026. if hit.Parent.Name ~= Me.Name and hit.Name ~= "Spell" and hit.Name ~= "Base" and hit.Parent.Name ~= Model2.Name and hit.Parent.Name ~= Model3.Name and hit.Parent.Name ~= Model4.Name and hit.Parent.Name ~= Model5.Name and hit.Parent.Name ~= Model6.Name and hit.Parent.Name ~= Model7.Name then
  1027.  
  1028. ball.Anchored = true
  1029.  
  1030. for i = 1, 10 do
  1031.  
  1032. ball.Transparency = 0.025*i
  1033.  
  1034. dmg(ball.Position, i, 0.5)
  1035.  
  1036. ballm.Scale = ballm.Scale + Vector3.new(0.5, 0.5, 0.5)
  1037.  
  1038. wait()
  1039.  
  1040. end
  1041.  
  1042. ball:remove()
  1043.  
  1044. end
  1045.  
  1046. end)
  1047.  
  1048. coroutine.resume(coroutine.create(function()
  1049.  
  1050. wait(2.5)
  1051.  
  1052. ball.Anchored = true
  1053.  
  1054. for i = 1, 10 do
  1055.  
  1056. dmg(ball.Position, i, math.random(2,6))
  1057.  
  1058. ball.Transparency = 0.025*i
  1059.  
  1060. ballm.Scale = ballm.Scale + Vector3.new(0.5, 0.5, 0.5)
  1061.  
  1062. wait()
  1063.  
  1064. end
  1065.  
  1066. ball:remove()
  1067.  
  1068. end))
  1069.  
  1070. while wait() do
  1071.  
  1072. if ball.Position == ballp.position then
  1073.  
  1074. ball.Anchored = true
  1075.  
  1076. for i = 1, 10 do
  1077.  
  1078. dmg(ball.Position, i, math.random(2,6))
  1079.  
  1080. ball.Transparency = 0.025*i
  1081.  
  1082. ballm.Scale = ballm.Scale + Vector3.new(0.5, 0.5, 0.5)
  1083.  
  1084. wait()
  1085.  
  1086. end
  1087.  
  1088. ball:remove()
  1089.  
  1090. break
  1091.  
  1092. end
  1093.  
  1094. end
  1095.  
  1096. end))
  1097.  
  1098. end
  1099.  
  1100. function slash()
  1101.  
  1102. local a = math.random(0, 45)
  1103.  
  1104. for i = 0, 1, 0.2 do
  1105.  
  1106. RAW.C0 = CFrame.new() * CFrame.Angles(math.rad(90+45*i),math.rad(a*i),0)
  1107.  
  1108. wait()
  1109.  
  1110. end
  1111.  
  1112. sound(sounds["Slash"])
  1113.  
  1114. for i = 0, 1, 0.1 do
  1115.  
  1116. RAW.C0 = CFrame.new() * CFrame.Angles(math.rad(135-135*i),math.rad(a+0*i),0)
  1117.  
  1118. wait()
  1119.  
  1120. end
  1121.  
  1122. dmg(Model4.Blade.Position, 3, math.random(10, 25))
  1123.  
  1124. for i = 0, 1, 0.1 do
  1125.  
  1126. RAW.C0 = CFrame.new() * CFrame.Angles(math.rad(0+90*i),math.rad(a-a*i),0)
  1127.  
  1128. wait()
  1129.  
  1130. end
  1131.  
  1132. end
  1133.  
  1134. if script.Parent.className ~= "HopperBin" then
  1135.  
  1136. local h = Instance.new("HopperBin", Me.Backpack)
  1137.  
  1138. h.Name = "Pen"
  1139.  
  1140. script.Parent = h
  1141.  
  1142. end
  1143.  
  1144. local bin = script.Parent
  1145.  
  1146. function onSelected(mouse)
  1147.  
  1148. RAW.Part1 = Rarm
  1149.  
  1150. for i = 0, 1, 0.1 do
  1151.  
  1152. RAW.C0 = CFrame.new(0,0,0) * CFrame.Angles(math.rad(90*i),0,0)
  1153.  
  1154. wait()
  1155.  
  1156. end
  1157.  
  1158. mouse.Button1Down:connect(function()
  1159.  
  1160. if mov == 1 then
  1161.  
  1162. sound(asset..sounds["Click"])
  1163.  
  1164. if peno == true then
  1165.  
  1166. peno = false
  1167.  
  1168. ledw.C0 = CFrame.new(0,0.25,0)
  1169.  
  1170. else
  1171.  
  1172. peno = true
  1173.  
  1174. ledw.C0 = CFrame.new(0,0,0)
  1175.  
  1176. end
  1177.  
  1178. elseif mov == 2 then
  1179.  
  1180. orb(mouse.hit.p)
  1181.  
  1182. elseif mov == 3 then
  1183.  
  1184. slash()
  1185.  
  1186. elseif mov == 4 then
  1187.  
  1188. arrow(mouse.hit.p)
  1189.  
  1190. elseif mov == 6 then
  1191.  
  1192. shoot(mouse.hit.p)
  1193.  
  1194. end
  1195.  
  1196. end)
  1197.  
  1198. mouse.KeyDown:connect(function(key)
  1199.  
  1200. if key == "e" then
  1201.  
  1202. if mov == nummovs then
  1203.  
  1204. mov = 1
  1205.  
  1206. else
  1207.  
  1208. mov = mov + 1
  1209.  
  1210. end
  1211.  
  1212. elseif key == "q" then
  1213.  
  1214. if mov == 1 then
  1215.  
  1216. mov = nummovs
  1217.  
  1218. else
  1219.  
  1220. mov = mov - 1
  1221.  
  1222. end
  1223.  
  1224. end
  1225.  
  1226. end)
  1227.  
  1228. mouse.KeyUp:connect(function(key)
  1229.  
  1230. end)
  1231.  
  1232. end
  1233.  
  1234. function onDesel(mouse)
  1235.  
  1236. for i = 0, 1, 0.1 do
  1237.  
  1238. RAW.C0 = CFrame.new() * CFrame.Angles(math.rad(90-90*i),0,0)
  1239.  
  1240. wait()
  1241.  
  1242. end
  1243.  
  1244. RAW.Part1 = nil
  1245.  
  1246. end
  1247.  
  1248. bin.Selected:connect(onSelected)
  1249.  
  1250. bin.Deselected:connect(onDesel)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement