Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- ---------------------------------
- ./ P R I D E B R I C C \.
- '\ /'
- ---------------------------------
- --]]
- local plr = owner
- --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")
- Script2 = Instance.new("Script")
- Sound3 = Instance.new("Sound")
- Sound4 = Instance.new("Sound")
- Sound5 = Instance.new("Sound")
- Script6 = Instance.new("Script")
- Tool0.Name = "pridebricc"
- Tool0.Parent = plr.Character
- Tool0.TextureId = "rbxassetid://1505410801"
- Tool0.Grip = CFrame.new(0.0227543004, -0.00938914716, 0.371580482, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Tool0.GripPos = Vector3.new(0.0227543004, -0.00938914716, 0.371580482)
- Tool0.ToolTip = "cause why not"
- Part1.Name = "Handle"
- Part1.Parent = Tool0
- Part1.Size = Vector3.new(0.899999976, 0.899999976, 0.899999976)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.Material = Enum.Material.Neon
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Script2.Parent = Part1
- table.insert(cors,sandbox(Script2,function()
- local Brick = script.Parent --Change To Brick
- local speed = 10 --Change to speed you want
- while true do
- for i = 0,1,0.001*speed do
- Brick.Color = Color3.fromHSV(i,1,1) --creates a color using i
- wait()
- end
- end
- end))
- Sound3.Name = "SwordLunge"
- Sound3.Parent = Part1
- Sound3.SoundId = "http://www.roblox.com/asset/?id=12222208"
- Sound3.Volume = 0.60000002384186
- Sound4.Name = "SwordSlash"
- Sound4.Parent = Part1
- Sound4.SoundId = "http://www.roblox.com/asset/?id=12222216"
- Sound4.Volume = 0.69999998807907
- Sound5.Name = "Unsheath"
- Sound5.Parent = Part1
- Sound5.SoundId = "http://www.roblox.com/asset/?id=12222225"
- Sound5.Volume = 1
- Script6.Name = "SwordScript"
- Script6.Parent = Tool0
- table.insert(cors,sandbox(Script6,function()
- --Rescripted by Luckymaxer
- --EUROCOW WAS HERE BECAUSE I MADE THE PARTICLES AND THEREFORE THIS ENTIRE SWORD PRETTY AND LOOK PRETTY WORDS AND I'D LIKE TO DEDICATE THIS TO MY FRIENDS AND HI LUCKYMAXER PLS FIX SFOTH SWORDS TY LOVE Y'ALl
- --Updated for R15 avatars by StarWars
- --Re-updated by TakeoHonorable
- local run = game:GetService("RunService")
- Tool = script.Parent
- Handle = Tool:WaitForChild("Handle")
- function Create(ty)
- return function(data)
- local obj = Instance.new(ty)
- for k, v in pairs(data) do
- if type(k) == 'number' then
- v.Parent = obj
- else
- obj[k] = v
- end
- end
- return obj
- end
- end
- local BaseUrl = "rbxassetid://"
- Players = game:GetService("Players")
- Debris = game:GetService("Debris")
- RunService = game:GetService("RunService")
- DamageValues = {
- BaseDamage = 5,
- SlashDamage = 1,
- LungeDamage = 30
- }
- --For R15 avatars
- Animations = {
- R15Slash = 522635514,
- R15Lunge = 522638767
- }
- Damage = DamageValues.BaseDamage
- Grips = {
- Up = CFrame.new(0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0),
- Out = CFrame.new(0, 0, 0, 0, 1, 0, 1, -0, 0, 0, 0, -1)
- }
- Sounds = {
- Slash = Handle:WaitForChild("SwordSlash"),
- Lunge = Handle:WaitForChild("SwordLunge"),
- Unsheath = Handle:WaitForChild("Unsheath")
- }
- ToolEquipped = false
- --For Omega Rainbow Katana thumbnail to display a lot of particles.
- for i, v in pairs(Handle:GetChildren()) do
- if v:IsA("ParticleEmitter") then
- v.Rate = 20
- end
- end
- Tool.Grip = Grips.Up
- Tool.Enabled = true
- function TagHumanoid(humanoid, player)
- local Creator_Tag = Instance.new("ObjectValue")
- Creator_Tag.Name = "creator"
- Creator_Tag.Value = player
- Debris:AddItem(Creator_Tag, 2)
- Creator_Tag.Parent = humanoid
- end
- function UntagHumanoid(humanoid)
- for i, v in pairs(humanoid:GetChildren()) do
- if v:IsA("ObjectValue") and v.Name == "creator" then
- v:Destroy()
- end
- end
- end
- function Blow(Hit)
- if not Hit or not Hit.Parent or not CheckIfAlive() or not ToolEquipped then
- return
- end
- local RightArm = Character:FindFirstChild("Right Arm") or Character:FindFirstChild("RightHand")
- if not RightArm then
- return
- end
- local RightGrip = RightArm:FindFirstChild("RightGrip")
- if not RightGrip or (RightGrip.Part0 ~= Handle and RightGrip.Part1 ~= Handle) then
- return
- end
- local character = Hit.Parent
- if character == Character then
- return
- end
- local humanoid = character:FindFirstChildOfClass("Humanoid")
- if not humanoid or humanoid.Health == 0 then
- UntagHumanoid(humanoid)
- TagHumanoid(humanoid, Player)
- humanoid:destroy()
- game.Debris:AddItem(Hit:FindFirstAncestorOfClass("Model"),5)
- local fold = Instance.new("Folder",Hit:FindFirstAncestorOfClass("Model"))
- for i,v in pairs(Hit:FindFirstAncestorOfClass("Model"):GetChildren()) do
- if v:IsA("Part") or v:IsA("MeshPart") then
- local clone = Instance.new("Part",fold)
- clone.Name = v.Name
- clone.Material = "Neon"
- clone.Anchored = true
- clone.CFrame = v.CFrame
- clone.CanCollide = false
- if v.Name ~= "Head" then
- clone.Size = v.Size
- else
- clone.Size = v.Size - Vector3.new(v.Size.Y,0,0)
- end
- local change = false
- v:Destroy()
- run.Heartbeat:Connect(function()
- --rainbow effect loop
- for i = 0,1,0.001*10 do
- if change == false then
- change = true
- clone.Color = Color3.fromHSV(i,1,1) --creates a color using i
- wait()
- change = false
- end
- end
- end)
- end
- end
- return
- end
- local player = Players:GetPlayerFromCharacter(character)
- if player and (player == Player) then
- return
- end
- end
- function Attack()
- Damage = DamageValues.SlashDamage
- Sounds.Slash:Play()
- if Humanoid then
- if Humanoid.RigType == Enum.HumanoidRigType.R6 then
- local Anim = Instance.new("StringValue")
- Anim.Name = "toolanim"
- Anim.Value = "Slash"
- Anim.Parent = Tool
- elseif Humanoid.RigType == Enum.HumanoidRigType.R15 then
- local Anim = Tool:FindFirstChild("R15Slash")
- if Anim then
- local Track = Humanoid:LoadAnimation(Anim)
- Track:Play(0)
- end
- end
- end
- end
- function Lunge()
- Damage = DamageValues.LungeDamage
- Sounds.Lunge:Play()
- if Humanoid then
- if Humanoid.RigType == Enum.HumanoidRigType.R6 then
- local Anim = Instance.new("StringValue")
- Anim.Name = "toolanim"
- Anim.Value = "Lunge"
- Anim.Parent = Tool
- elseif Humanoid.RigType == Enum.HumanoidRigType.R15 then
- local Anim = Tool:FindFirstChild("R15Lunge")
- if Anim then
- local Track = Humanoid:LoadAnimation(Anim)
- Track:Play(0)
- end
- end
- end
- --[[
- if CheckIfAlive() then
- local Force = Instance.new("BodyVelocity")
- Force.velocity = Vector3.new(0, 10, 0)
- Force.maxForce = Vector3.new(0, 4000, 0)
- Debris:AddItem(Force, 0.4)
- Force.Parent = Torso
- end
- ]]
- wait(0.2)
- Tool.Grip = Grips.Out
- wait(0.6)
- Tool.Grip = Grips.Up
- Damage = DamageValues.SlashDamage
- end
- Tool.Enabled = true
- LastAttack = 0
- function Activated()
- if not Tool.Enabled or not ToolEquipped or not CheckIfAlive() then
- return
- end
- Tool.Enabled = false
- local Tick = RunService.Stepped:wait()
- if (Tick - LastAttack < 0.2) then
- Lunge()
- else
- Attack()
- end
- LastAttack = Tick
- --wait(0.5)
- Damage = DamageValues.BaseDamage
- local SlashAnim = (Tool:FindFirstChild("R15Slash") or Create("Animation"){
- Name = "R15Slash",
- AnimationId = BaseUrl .. Animations.R15Slash,
- Parent = Tool
- })
- local LungeAnim = (Tool:FindFirstChild("R15Lunge") or Create("Animation"){
- Name = "R15Lunge",
- AnimationId = BaseUrl .. Animations.R15Lunge,
- Parent = Tool
- })
- Tool.Enabled = true
- end
- function CheckIfAlive()
- return (((Player and Player.Parent and Character and Character.Parent and Humanoid and Humanoid.Parent and Humanoid.Health > 0 and Torso and Torso.Parent) and true) or false)
- end
- function Equipped()
- Character = Tool.Parent
- Player = Players:GetPlayerFromCharacter(Character)
- Humanoid = Character:FindFirstChildOfClass("Humanoid")
- Torso = Character:FindFirstChild("Torso") or Character:FindFirstChild("HumanoidRootPart")
- if not CheckIfAlive() then
- return
- end
- ToolEquipped = true
- Sounds.Unsheath:Play()
- end
- function Unequipped()
- Tool.Grip = Grips.Up
- ToolEquipped = false
- end
- Tool.Activated:Connect(Activated)
- Tool.Equipped:Connect(Equipped)
- Tool.Unequipped:Connect(Unequipped)
- Connection = Handle.Touched:Connect(Blow)
- end))
- for i,v in pairs(mas:GetChildren()) do
- v.Parent = workspace
- pcall(function() v:MakeJoints() end)
- end
- mas:Destroy()
- for i,v in pairs(cors) do
- spawn(function()
- pcall(v)
- end)
- end
Add Comment
Please, Sign In to add comment