Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Converted with ttyyuu12345's model to script plugin v4
- function sandbox(var,func)
- local env = getfenv(func)
- local newenv = setmetatable({},{
- __index = function(self,k)
- if k=="script" then
- return var
- else
- return env[k]
- end
- end,
- })
- setfenv(func,newenv)
- return func
- end
- cors = {}
- mas = Instance.new("Model",game:GetService("Lighting"))
- Tool0 = Instance.new("Tool")
- Part1 = Instance.new("Part")
- SpecialMesh2 = Instance.new("SpecialMesh")
- Sound3 = Instance.new("Sound")
- Script4 = Instance.new("Script")
- Tool5 = Instance.new("Tool")
- StringValue6 = Instance.new("StringValue")
- Script7 = Instance.new("Script")
- BoolValue8 = Instance.new("BoolValue")
- LocalScript9 = Instance.new("LocalScript")
- Animation10 = Instance.new("Animation")
- Animation11 = Instance.new("Animation")
- Animation12 = Instance.new("Animation")
- Animation13 = Instance.new("Animation")
- Animation14 = Instance.new("Animation")
- Animation15 = Instance.new("Animation")
- Part16 = Instance.new("Part")
- Weld17 = Instance.new("Weld")
- Attachment18 = Instance.new("Attachment")
- Attachment19 = Instance.new("Attachment")
- SpecialMesh20 = Instance.new("SpecialMesh")
- Tool0.Name = "C4"
- Tool0.Parent = mas
- Tool0.TextureId = "http://www.roblox.com/asset/?id=29784479"
- Tool0.GripForward = Vector3.new(1, -0, -0)
- Tool0.GripPos = Vector3.new(-0.100000001, 0, 0)
- Tool0.GripRight = Vector3.new(0, 0, 1)
- Part1.Name = "Handle"
- Part1.Parent = Tool0
- Part1.Rotation = Vector3.new(-180, 32.3999977, 179.949997)
- Part1.RotVelocity = Vector3.new(1, 1, 1)
- Part1.FormFactor = Enum.FormFactor.Symmetric
- Part1.Size = Vector3.new(1, 1, 1)
- Part1.CFrame = CFrame.new(201.749634, 31.4991264, 61.4766388, -0.844324708, -0.000672729395, 0.535831749, -0.000796642096, 0.999999642, 1.95097499e-07, -0.53583163, -0.000426701445, -0.844324887)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Part1.Position = Vector3.new(201.749634, 31.4991264, 61.4766388)
- Part1.Orientation = Vector3.new(0, 147.599991, -0.049999997)
- SpecialMesh2.Parent = Part1
- SpecialMesh2.MeshId = "http://www.roblox.com/asset/?id=28511792"
- SpecialMesh2.Scale = Vector3.new(2, 2, 2)
- SpecialMesh2.TextureId = "http://www.roblox.com/asset/?id=28511890"
- SpecialMesh2.MeshType = Enum.MeshType.FileMesh
- SpecialMesh2.Scale = Vector3.new(2, 2, 2)
- Sound3.Name = "Plant"
- Sound3.Parent = Part1
- Sound3.SoundId = "http://www.roblox.com/asset/?id=28518380"
- Script4.Name = "PlantBomb"
- Script4.Parent = Tool0
- table.insert(cors,sandbox(Script4,function()
- Tool = script.Parent
- local planting = true
- local bomb = nil
- local uses = 3
- local sound = Instance.new("Sound")
- sound.SoundId = "http://www.roblox.com/asset/?id=28517063"
- sound.Looped = true
- local explosion = Instance.new("Sound")
- explosion.SoundId = "http://www.roblox.com/asset/?id=28518734"
- explosion.Volume = 0.01
- explosion:Play()
- explosion.Volume = 0.5
- function plant(pos)
- Tool.Handle.Plant:Play()
- local vCharacter = Tool.Parent
- local vPlayer = game.Players:playerFromCharacter(vCharacter)
- local spawnPos = vCharacter.PrimaryPart.Position
- bomb = Instance.new("Part")
- bomb.Locked = true
- bomb.formFactor = 2
- bomb.Size = Vector3.new(1,0.4,1)
- bomb.Name = "Mine"
- bomb.Position = pos
- mesh = Instance.new("SpecialMesh")
- mesh.Parent = bomb
- mesh.MeshId = "http://www.roblox.com/asset/?id=13319240"
- mesh.TextureId = "http://www.roblox.com/asset/?id=23087350"
- mesh.Scale = Vector3.new(1.3,1.3,1.3)
- sound.Parent = bomb
- sound:Play()
- explosion:Stop()
- local creator_tag = Instance.new("ObjectValue")
- creator_tag.Value = vPlayer
- creator_tag.Name = "creator"
- creator_tag.Parent = bomb
- bomb.Parent = game.Workspace
- bomb.Touched:connect(function(part)
- if part ~= Tool.Handle and part.Parent:FindFirstChild("Humanoid") == nil then
- bomb.Anchored = true
- bomb.CanCollide = false
- end
- end)
- end
- function blowUp()
- local e = Instance.new("Explosion")
- e.BlastPressure = 100
- e.BlastRadius = 5
- e.Parent = game.Workspace
- e.Position = bomb.Position
- sound:Stop()
- explosion.Parent = e
- explosion:Play()
- bomb:remove()
- end
- Tool.Enabled = true
- function onActivated()
- if not Tool.Enabled then
- return
- end
- Tool.Enabled = false
- local character = Tool.Parent;
- local humanoid = character.Humanoid
- if humanoid == nil then
- print("Humanoid not found")
- return
- end
- local targetPos = humanoid.TargetPoint
- if planting then
- plant(Tool.Handle.Position)
- planting = false
- else
- blowUp()
- planting = true
- end
- Tool.Enabled = true
- end
- script.Parent.Activated:connect(onActivated)
- end))
- Tool5.Name = "Knife"
- Tool5.Parent = mas
- Tool5.GripForward = Vector3.new(-0.0954888314, -0.84233582, 0.530426502)
- Tool5.GripPos = Vector3.new(-0.000422431156, 0.562534153, 0.476890266)
- Tool5.GripRight = Vector3.new(0.995430529, -0.0808028951, 0.0508822948)
- Tool5.GripUp = Vector3.new(-3.47819062e-09, -0.532861292, -0.846202612)
- StringValue6.Name = "RunAnim"
- StringValue6.Parent = Tool5
- Script7.Name = "KnifeScript"
- Script7.Parent = Tool5
- table.insert(cors,sandbox(Script7,function()
- sp = script.Parent
- r = game:service("RunService")
- debris = game:GetService("Debris")
- anims = {"RightSlash","LeftSlash","OverHeadSwing","LeftSwingFast","RightSwingFast"}
- Sounds = {{145180512, "Metal"}, {145180522, "Metal"}, {145180533, "Wood"}, {145180541, "Wood"}, {145180529, "Slash"}, {145180550, "Slash"}}
- WoodSounds = {}
- MetalSounds = {}
- SlashSounds = {}
- basedamage = 0
- slashdamage = 1
- swingdamage = 1
- damage = basedamage
- sword = sp.Handle
- sp.Taunting.Value = false
- local UnsheathSound = Instance.new("Sound")
- UnsheathSound.SoundId = "http://www.roblox.com/Asset/?id=145180523"
- UnsheathSound.Parent = sword
- UnsheathSound.Volume = 0.5
- for _,Sound in pairs(Sounds) do
- local S = Instance.new("Sound")
- S.SoundId = "http://www.roblox.com/Asset/?id=" .. Sound[1]
- S.Parent = sword
- S.Volume = 1
- if Sound[2] == "Wood" then
- table.insert(WoodSounds, S)
- elseif Sound[2] == "Metal" then
- table.insert(MetalSounds, S)
- elseif Sound[2] == "Slash" then
- table.insert(SlashSounds, S)
- end
- end
- function waitfor(parent,name)
- while true do
- local child = parent:FindFirstChild(name)
- if child ~= nil then
- return child
- end
- wait()
- end
- end
- waitfor(sp,"Taunting")
- waitfor(sp,"RunAnim")
- local Halt = false;
- function blow(hit)
- if hit:findFirstChild("IsShield") then
- damage = 12
- pcall(function()
- if hit.IsShield.Value == "Wood" then
- WoodSounds[math.random(#WoodSounds)]:Play()
- elseif hit.IsShield.Value == "Metal" then
- MetalSounds[math.random(#MetalSounds)]:Play()
- else
- WoodSounds[math.random(#WoodSounds)]:Play()
- end
- end);
- return
- end
- if Halt then return end;
- Halt = true;
- if hit.Parent ~= nil then
- local humanoid = hit.Parent:findFirstChild("Humanoid")
- local vCharacter = sp.Parent
- if vCharacter ~= nil then
- local vPlayer = game.Players:playerFromCharacter(vCharacter)
- if vPlayer ~= nil then
- local hum = vCharacter:findFirstChild("Humanoid")
- if humanoid ~= nil then
- if hum ~= nil and humanoid ~= hum then
- local right_arm = vCharacter:FindFirstChild("Right Arm")
- if right_arm ~= nil then
- local joint = right_arm:FindFirstChild("RightGrip")
- if joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword) then
- tagHumanoid(humanoid,vPlayer)
- humanoid:TakeDamage(damage)
- wait(3)
- humanoid.Parent:BreakJoints()
- end
- end
- end
- end
- end
- end
- end
- Halt = false;
- end
- function tagHumanoid(humanoid,player)
- for i,v in ipairs(humanoid:GetChildren()) do
- if v.Name == "creator" then
- v:Destroy()
- end
- end
- local creator_tag = Instance.new("ObjectValue")
- creator_tag.Value = player
- creator_tag.Name = "creator"
- creator_tag.Parent = humanoid
- debris:AddItem(creator_tag,1)
- end
- sp.Enabled = true
- function onActivated()
- if sp.Enabled and not sp.Taunting.Value then
- sp.Enabled = false
- local character = sp.Parent;
- local humanoid = character.Humanoid
- if humanoid == nil then
- print("Humanoid not found")
- return
- end
- SlashSounds[math.random(#SlashSounds)]:Play()
- newanim = anims[math.random(1,#anims)]
- while newanim == sp.RunAnim.Value do
- newanim = anims[math.random(1,#anims)]
- end
- sp.RunAnim.Value = newanim
- if newanim == "OverHeadSwing" then
- damage = swingdamage
- else
- damage = slashdamage
- end
- wait(.5)
- damage = basedamage
- sp.Enabled = true
- end
- end
- function onEquipped()
- UnsheathSound:play()
- end
- sp.Activated:connect(onActivated)
- sp.Equipped:connect(onEquipped)
- connection = sword.Touched:connect(blow)
- end))
- BoolValue8.Name = "Taunting"
- BoolValue8.Parent = Tool5
- LocalScript9.Name = "Local Gui"
- LocalScript9.Parent = Tool5
- table.insert(cors,sandbox(LocalScript9,function()
- local sp = script.Parent
- originalgrip = sp.Grip
- currentgrip = originalgrip
- GripForward = sp.GripForward
- GripPos = sp.GripPos
- GripRight = sp.GripRight
- GripUp = sp.GripUp
- enabled = true
- taunting = false
- function waitfor(parent,name)
- while true do
- local child = parent:FindFirstChild(name)
- if child~=nil then
- return child
- end
- wait()
- end
- end
- waitfor(sp,"Handle")
- function onButton1Down(mouse)
- if not enabled then
- return
- end
- enabled=false
- mouse.Icon="http://www.roblox.com/asset/?id=1370539746"
- wait(.75)
- mouse.Icon="http://www.roblox.com/asset/?id=1371304987"
- enabled=true
- end
- function swordUp()
- currentgrip = originalgrip
- end
- function swordOut()
- currentgrip = originalgrip * CFrame.Angles(math.pi/4,.4,0)
- end
- function spinsword(spintime)
- delay(0,function()
- local startspin=tick()
- local endspin=startspin+spintime
- while tick()<endspin do
- sp.Grip=currentgrip*CFrame.Angles(math.pi*2*((tick()-startspin)/spintime),0,0)
- wait()
- end
- sp.Grip = currentgrip
- end)
- end
- function onEquippedLocal(mouse)
- local currentlast = lastequipped
- if mouse==nil then
- print("Mouse not found")
- return
- end
- mouse.Icon="http://www.roblox.com/asset/?id=1370539746"
- mouse.Button1Down:connect(function()
- onButton1Down(mouse)
- end)
- waitfor(sp,"Taunting")
- waitfor(sp,"Taunt")
- mouse.KeyDown:connect(function(key)
- key=string.lower(key)
- if key=="r" then -- :3
- local h=sp.Parent:FindFirstChild("Humanoid")
- if h~=nil then
- sp.Taunting.Value=true
- h.WalkSpeed=2
- tauntanim=h:LoadAnimation(sp.Taunt)
- tauntanim:Play()
- wait(1)
- swordOut()
- sp.Grip=currentgrip
- wait(1.4)
- swordUp()
- sp.Grip=currentgrip
- wait(1)
- h.WalkSpeed=16
- sp.Taunting.Value=false
- end
- end
- end)
- end
- sp.Equipped:connect(onEquippedLocal)
- waitfor(sp,"RunAnim")
- sp.RunAnim.Changed:connect(function()
- local h=sp.Parent:FindFirstChild("Humanoid")
- local t=sp.Parent:FindFirstChild("Torso")
- local anim=sp:FindFirstChild(sp.RunAnim.Value)
- if anim and t and h then
- theanim=h:LoadAnimation(anim)
- if theanim and h.Health>0 then
- theanim:Play()
- if sp.RunAnim.Value=="RightSlash" or sp.RunAnim.Value=="LeftSlash" or sp.RunAnim.Value=="OverHeadSwing" then
- spinsword(.5)
- end
- if sp.RunAnim.Value=="OverHeadSwing" then
- wait(.25)
- swordOut()
- wait(.5)
- swordUp()
- sp.Grip = currentgrip
- sp.GripForward = GripForward
- sp.GripPos = GripPos
- sp.GripRight = GripRight
- sp.GripUp = GripUp
- elseif sp.RunAnim.Value=="OverHeadSwingFast" then
- wait(.125)
- swordOut()
- wait(.25)
- swordUp()
- sp.Grip = currentgrip
- sp.GripForward = GripForward
- sp.GripPos = GripPos
- sp.GripRight = GripRight
- sp.GripUp = GripUp
- end
- end
- end
- end)
- end))
- Animation10.Name = "LeftSlash"
- Animation10.Parent = Tool5
- Animation10.AnimationId = "http://www.roblox.com/Asset?ID=74894663"
- Animation11.Name = "LeftSwingFast"
- Animation11.Parent = Tool5
- Animation11.AnimationId = "http://www.roblox.com/Asset?ID=86313418"
- Animation12.Name = "OverHeadSwing"
- Animation12.Parent = Tool5
- Animation12.AnimationId = "http://www.roblox.com/Asset?ID=74897796"
- Animation13.Name = "RightSlash"
- Animation13.Parent = Tool5
- Animation13.AnimationId = "http://www.roblox.com/Asset?ID=74813494"
- Animation14.Name = "RightSwingFast"
- Animation14.Parent = Tool5
- Animation14.AnimationId = "http://www.roblox.com/Asset?ID=86313260"
- Animation15.Name = "Taunt"
- Animation15.Parent = Tool5
- Animation15.AnimationId = "rbxassetid://01413369796"
- Part16.Name = "Handle"
- Part16.Parent = Tool5
- Part16.BrickColor = BrickColor.new("Dark stone grey")
- Part16.Reflectance = 0.40000000596046
- Part16.Rotation = Vector3.new(107.079994, 2.91999984, 4.63999987)
- Part16.FormFactor = Enum.FormFactor.Plate
- Part16.Size = Vector3.new(0.200000033, 2.00000024, 2)
- Part16.CFrame = CFrame.new(40.112587, 5.47537613, 38.3044052, 0.995430589, -0.0808026716, 0.0508828573, 0.0247150157, -0.29669103, -0.95465368, 0.0922350511, 0.951548934, -0.293338269)
- Part16.BottomSurface = Enum.SurfaceType.Smooth
- Part16.TopSurface = Enum.SurfaceType.Smooth
- Part16.Color = Color3.new(0.388235, 0.372549, 0.384314)
- Part16.Position = Vector3.new(40.112587, 5.47537613, 38.3044052)
- Part16.Orientation = Vector3.new(72.6800003, 170.160004, 175.23999)
- Part16.Color = Color3.new(0.388235, 0.372549, 0.384314)
- Weld17.Name = "Handle-to-Part Weld"
- Weld17.Parent = Part16
- Weld17.C0 = CFrame.new(0.5, -3, 0.5, 1, 0, 0, 0, 0, -1, 0, 1, 0)
- Weld17.C1 = CFrame.new(1, 1.20000076, -13, 7.4505806e-09, 1, 3.7403327e-12, 4.14893814e-13, 3.36629596e-13, -1, -1, 1.49011612e-08, 2.15725493e-11)
- Attachment18.Name = "UpperBlade_Attachment"
- Attachment18.Parent = Part16
- Attachment18.CFrame = CFrame.new(-3.66789436e-06, -0.949999392, -0.982302547, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment18.Position = Vector3.new(-3.66789436e-06, -0.949999392, -0.982302547)
- Attachment19.Name = "LowerBlade_Attachment"
- Attachment19.Parent = Part16
- Attachment19.CFrame = CFrame.new(-3.27045836e-06, 0.200000033, 0.13645044, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment19.Position = Vector3.new(-3.27045836e-06, 0.200000033, 0.13645044)
- SpecialMesh20.Parent = Part16
- SpecialMesh20.MeshId = "rbxassetid://470094777"
- SpecialMesh20.Scale = Vector3.new(0.200000003, 0.200000003, 0.200000003)
- SpecialMesh20.TextureId = "http://www.roblox.com/asset/?id=470149026"
- SpecialMesh20.MeshType = Enum.MeshType.FileMesh
- SpecialMesh20.Scale = Vector3.new(0.200000003, 0.200000003, 0.200000003)
- for i,v in pairs(mas:GetChildren()) do
- v.Parent = game:GetService("Players").LocalPlayer.Backpack
- pcall(function() v:MakeJoints() end)
- end
- mas:Destroy()
- for i,v in pairs(cors) do
- spawn(function()
- pcall(v)
- end)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement