Advertisement
iiJosephCats205

Peppa Pig (DEMO)

Nov 12th, 2019
253
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 51.03 KB | None | 0 0
  1. --By iiJoeCats (DEMO VERSION. NOT COMPLETE.)
  2.  
  3. repeat wait(3) until game.Players.LocalPlayer.Character
  4. print("Running...")
  5.  
  6. local player = game.Players.LocalPlayer
  7. local mouse = player:GetMouse()
  8. local UIS = game:GetService("UserInputService")
  9. local character = player.Character
  10. local runS = game:GetService("RunService").RenderStepped
  11. local tweenS = game:GetService("TweenService")
  12.  
  13. local attack = false
  14. local firing = false
  15. local gunSize = 1.2
  16.  
  17. function removeItem(item,timer)
  18.     game:GetService("Debris"):AddItem(item,timer)
  19. end
  20.  
  21. local hum = character:FindFirstChildOfClass("Humanoid")
  22.  
  23. local rArm = character["Right Arm"]
  24. local lArm = character["Left Arm"]
  25. local rLeg = character["Right Leg"]
  26. local lLeg = character["Left Leg"]
  27. local tors = character.Torso
  28. local hed = character.Head
  29. local root = character.HumanoidRootPart
  30.  
  31. local rootj = root.RootJoint
  32.  
  33. for i, v in pairs(character:GetChildren()) do
  34.     if v.ClassName == "Pants" or v.ClassName == "Shirt" or v.ClassName == "Accessory" or v.ClassName == "ShirtGraphic" then
  35.         v:Destroy()
  36.     end
  37. end
  38.  
  39. hed.Transparency = 0.9
  40. if hed:FindFirstChild("face") then
  41.     hed.face:Destroy()
  42. end
  43.  
  44. tors.Transparency = 1
  45. lArm.Transparency = 1
  46. rArm.Transparency = 1
  47. lLeg.CanCollide = true
  48. lLeg.Transparency = 1
  49. rLeg.CanCollide = true
  50. rLeg.Transparency = 1
  51.  
  52. --Morph
  53.  
  54. --//Head
  55.  
  56. function createHead()
  57.     --Converted with ttyyuu12345's model to script plugin v4
  58.     function sandbox(var,func)
  59.         local env = getfenv(func)
  60.         local newenv = setmetatable({},{
  61.             __index = function(self,k)
  62.                 if k=="script" then
  63.                     return var
  64.                 else
  65.                     return env[k]
  66.                 end
  67.             end,
  68.         })
  69.         setfenv(func,newenv)
  70.         return func
  71.     end
  72.     cors = {}
  73.     mas = Instance.new("Model",game:GetService("Lighting"))
  74.     Model0 = Instance.new("Model")
  75.     Part1 = Instance.new("Part")
  76.     Part2 = Instance.new("Part")
  77.     Part3 = Instance.new("Part")
  78.     Part4 = Instance.new("Part")
  79.     Part5 = Instance.new("Part")
  80.     Part6 = Instance.new("Part")
  81.     Part7 = Instance.new("Part")
  82.     Part8 = Instance.new("Part")
  83.     Part9 = Instance.new("Part")
  84.     Part10 = Instance.new("Part")
  85.     Part11 = Instance.new("Part")
  86.     Part12 = Instance.new("Part")
  87.     Script13 = Instance.new("Script")
  88.     Model0.Name = "HeadPart"
  89.     Model0.Parent = mas
  90.     Part1.Name = "Middle"
  91.     Part1.Parent = Model0
  92.     Part1.CFrame = CFrame.new(-75.1135941, 9.12043381, 135.362, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  93.     Part1.Orientation = Vector3.new(0, 89.8399963, 0)
  94.     Part1.Position = Vector3.new(-75.1135941, 9.12043381, 135.362)
  95.     Part1.Rotation = Vector3.new(0, 89.7200012, 0)
  96.     Part1.Color = Color3.new(0.972549, 0.972549, 0.972549)
  97.     Part1.Transparency = 1
  98.     Part1.Size = Vector3.new(2, 1, 1)
  99.     Part1.Anchored = true
  100.     Part1.BottomSurface = Enum.SurfaceType.Smooth
  101.     Part1.BrickColor = BrickColor.new("Institutional white")
  102.     Part1.CanCollide = false
  103.     Part1.Material = Enum.Material.SmoothPlastic
  104.     Part1.TopSurface = Enum.SurfaceType.Smooth
  105.     Part1.brickColor = BrickColor.new("Institutional white")
  106.     Part1.FormFactor = Enum.FormFactor.Symmetric
  107.     Part1.formFactor = Enum.FormFactor.Symmetric
  108.     Part2.Name = "Head"
  109.     Part2.Parent = Model0
  110.     Part2.CFrame = CFrame.new(-75.1037521, 9.62043381, 135.362213, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  111.     Part2.Orientation = Vector3.new(0, 89.8399963, 0)
  112.     Part2.Position = Vector3.new(-75.1037521, 9.62043381, 135.362213)
  113.     Part2.Rotation = Vector3.new(0, 89.7099991, 0)
  114.     Part2.Color = Color3.new(1, 0.4, 0.8)
  115.     Part2.Size = Vector3.new(2, 2, 2)
  116.     Part2.Anchored = true
  117.     Part2.BottomSurface = Enum.SurfaceType.Smooth
  118.     Part2.BrickColor = BrickColor.new("Pink")
  119.     Part2.CanCollide = false
  120.     Part2.TopSurface = Enum.SurfaceType.Smooth
  121.     Part2.brickColor = BrickColor.new("Pink")
  122.     Part2.FormFactor = Enum.FormFactor.Symmetric
  123.     Part2.formFactor = Enum.FormFactor.Symmetric
  124.     Part3.Name = "eyes"
  125.     Part3.Parent = Model0
  126.     Part3.CFrame = CFrame.new(-75.5667877, 9.99046707, 135.341003, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  127.     Part3.Orientation = Vector3.new(0, 89.8399963, 0)
  128.     Part3.Position = Vector3.new(-75.5667877, 9.99046707, 135.341003)
  129.     Part3.Rotation = Vector3.new(0, 89.7099991, 0)
  130.     Part3.Color = Color3.new(0.972549, 0.972549, 0.972549)
  131.     Part3.Size = Vector3.new(2.07999921, 0.600000024, 0.629999876)
  132.     Part3.Anchored = true
  133.     Part3.BottomSurface = Enum.SurfaceType.Smooth
  134.     Part3.BrickColor = BrickColor.new("Institutional white")
  135.     Part3.CanCollide = false
  136.     Part3.Material = Enum.Material.SmoothPlastic
  137.     Part3.TopSurface = Enum.SurfaceType.Smooth
  138.     Part3.brickColor = BrickColor.new("Institutional white")
  139.     Part3.FormFactor = Enum.FormFactor.Symmetric
  140.     Part3.formFactor = Enum.FormFactor.Symmetric
  141.     Part4.Name = "eyes"
  142.     Part4.Parent = Model0
  143.     Part4.CFrame = CFrame.new(-75.7663498, 9.99661636, 134.31543, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  144.     Part4.Orientation = Vector3.new(0, 89.8399963, 0)
  145.     Part4.Position = Vector3.new(-75.7663498, 9.99661636, 134.31543)
  146.     Part4.Rotation = Vector3.new(0, 89.7099991, 0)
  147.     Part4.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  148.     Part4.Size = Vector3.new(0.0700000003, 0.210000053, 0.189999953)
  149.     Part4.Anchored = true
  150.     Part4.BottomSurface = Enum.SurfaceType.Smooth
  151.     Part4.BrickColor = BrickColor.new("Really black")
  152.     Part4.CanCollide = false
  153.     Part4.Material = Enum.Material.SmoothPlastic
  154.     Part4.TopSurface = Enum.SurfaceType.Smooth
  155.     Part4.brickColor = BrickColor.new("Really black")
  156.     Part4.FormFactor = Enum.FormFactor.Symmetric
  157.     Part4.formFactor = Enum.FormFactor.Symmetric
  158.     Part5.Name = "eyes"
  159.     Part5.Parent = Model0
  160.     Part5.CFrame = CFrame.new(-75.7897644, 9.99627686, 136.385345, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  161.     Part5.Orientation = Vector3.new(0, 89.8399963, 0)
  162.     Part5.Position = Vector3.new(-75.7897644, 9.99627686, 136.385345)
  163.     Part5.Rotation = Vector3.new(0, 89.7099991, 0)
  164.     Part5.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  165.     Part5.Size = Vector3.new(0.0500000007, 0.210000053, 0.189999953)
  166.     Part5.Anchored = true
  167.     Part5.BottomSurface = Enum.SurfaceType.Smooth
  168.     Part5.BrickColor = BrickColor.new("Really black")
  169.     Part5.CanCollide = false
  170.     Part5.Material = Enum.Material.SmoothPlastic
  171.     Part5.TopSurface = Enum.SurfaceType.Smooth
  172.     Part5.brickColor = BrickColor.new("Really black")
  173.     Part5.FormFactor = Enum.FormFactor.Symmetric
  174.     Part5.formFactor = Enum.FormFactor.Symmetric
  175.     Part6.Name = "Head"
  176.     Part6.Parent = Model0
  177.     Part6.CFrame = CFrame.new(-75.5237427, 9.99043274, 135.361023, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  178.     Part6.Orientation = Vector3.new(0, 89.8399963, 0)
  179.     Part6.Position = Vector3.new(-75.5237427, 9.99043274, 135.361023)
  180.     Part6.Rotation = Vector3.new(0, 89.7099991, 0)
  181.     Part6.Color = Color3.new(1, 0.4, 0.8)
  182.     Part6.Size = Vector3.new(2, 1.26000011, 2.83999991)
  183.     Part6.Anchored = true
  184.     Part6.BottomSurface = Enum.SurfaceType.Smooth
  185.     Part6.BrickColor = BrickColor.new("Pink")
  186.     Part6.CanCollide = false
  187.     Part6.TopSurface = Enum.SurfaceType.Smooth
  188.     Part6.brickColor = BrickColor.new("Pink")
  189.     Part6.FormFactor = Enum.FormFactor.Symmetric
  190.     Part6.formFactor = Enum.FormFactor.Symmetric
  191.     Part7.Name = "Head"
  192.     Part7.Parent = Model0
  193.     Part7.CFrame = CFrame.new(-76.9470367, 9.83540344, 134.757019, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  194.     Part7.Orientation = Vector3.new(0, 89.8399963, 0)
  195.     Part7.Position = Vector3.new(-76.9470367, 9.83540344, 134.757019)
  196.     Part7.Rotation = Vector3.new(0, 89.7099991, 0)
  197.     Part7.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  198.     Part7.Size = Vector3.new(0.32000041, 0.310000479, 0.109999992)
  199.     Part7.Anchored = true
  200.     Part7.BottomSurface = Enum.SurfaceType.Smooth
  201.     Part7.BrickColor = BrickColor.new("Really black")
  202.     Part7.CanCollide = false
  203.     Part7.TopSurface = Enum.SurfaceType.Smooth
  204.     Part7.brickColor = BrickColor.new("Really black")
  205.     Part7.FormFactor = Enum.FormFactor.Symmetric
  206.     Part7.formFactor = Enum.FormFactor.Symmetric
  207.     Part8.Name = "Head"
  208.     Part8.Parent = Model0
  209.     Part8.CFrame = CFrame.new(-76.9501495, 9.83545113, 135.860916, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  210.     Part8.Orientation = Vector3.new(0, 89.8399963, 0)
  211.     Part8.Position = Vector3.new(-76.9501495, 9.83545113, 135.860916)
  212.     Part8.Rotation = Vector3.new(0, 89.7099991, 0)
  213.     Part8.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  214.     Part8.Size = Vector3.new(0.32000041, 0.310000479, 0.109999992)
  215.     Part8.Anchored = true
  216.     Part8.BottomSurface = Enum.SurfaceType.Smooth
  217.     Part8.BrickColor = BrickColor.new("Really black")
  218.     Part8.CanCollide = false
  219.     Part8.TopSurface = Enum.SurfaceType.Smooth
  220.     Part8.brickColor = BrickColor.new("Really black")
  221.     Part8.FormFactor = Enum.FormFactor.Symmetric
  222.     Part8.formFactor = Enum.FormFactor.Symmetric
  223.     Part9.Name = "Head"
  224.     Part9.Parent = Model0
  225.     Part9.CFrame = CFrame.new(-75.0861053, 10.0253906, 134.422272, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  226.     Part9.Orientation = Vector3.new(0, 89.8399963, 0)
  227.     Part9.Position = Vector3.new(-75.0861053, 10.0253906, 134.422272)
  228.     Part9.Rotation = Vector3.new(0, 89.7099991, 0)
  229.     Part9.Color = Color3.new(1, 0.4, 0.8)
  230.     Part9.Size = Vector3.new(0.119999997, 2.80999923, 0.650000334)
  231.     Part9.Anchored = true
  232.     Part9.BottomSurface = Enum.SurfaceType.Smooth
  233.     Part9.BrickColor = BrickColor.new("Pink")
  234.     Part9.CanCollide = false
  235.     Part9.TopSurface = Enum.SurfaceType.Smooth
  236.     Part9.brickColor = BrickColor.new("Pink")
  237.     Part9.FormFactor = Enum.FormFactor.Symmetric
  238.     Part9.formFactor = Enum.FormFactor.Symmetric
  239.     Part10.Name = "Head"
  240.     Part10.Parent = Model0
  241.     Part10.CFrame = CFrame.new(-75.0912781, 10.0254707, 136.258438, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  242.     Part10.Orientation = Vector3.new(0, 89.8399963, 0)
  243.     Part10.Position = Vector3.new(-75.0912781, 10.0254707, 136.258438)
  244.     Part10.Rotation = Vector3.new(0, 89.7099991, 0)
  245.     Part10.Color = Color3.new(1, 0.4, 0.8)
  246.     Part10.Size = Vector3.new(0.119999997, 2.80999923, 0.650000334)
  247.     Part10.Anchored = true
  248.     Part10.BottomSurface = Enum.SurfaceType.Smooth
  249.     Part10.BrickColor = BrickColor.new("Pink")
  250.     Part10.CanCollide = false
  251.     Part10.TopSurface = Enum.SurfaceType.Smooth
  252.     Part10.brickColor = BrickColor.new("Pink")
  253.     Part10.FormFactor = Enum.FormFactor.Symmetric
  254.     Part10.formFactor = Enum.FormFactor.Symmetric
  255.     Part11.Name = "Head"
  256.     Part11.Parent = Model0
  257.     Part11.CFrame = CFrame.new(-76.0936432, 8.9804287, 135.324463, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  258.     Part11.Orientation = Vector3.new(0, 89.8399963, 0)
  259.     Part11.Position = Vector3.new(-76.0936432, 8.9804287, 135.324463)
  260.     Part11.Rotation = Vector3.new(0, 89.7099991, 0)
  261.     Part11.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  262.     Part11.Size = Vector3.new(1.09000051, 0.0600000024, 0.0799999982)
  263.     Part11.Anchored = true
  264.     Part11.BottomSurface = Enum.SurfaceType.Smooth
  265.     Part11.BrickColor = BrickColor.new("Really black")
  266.     Part11.CanCollide = false
  267.     Part11.TopSurface = Enum.SurfaceType.Smooth
  268.     Part11.brickColor = BrickColor.new("Really black")
  269.     Part11.FormFactor = Enum.FormFactor.Symmetric
  270.     Part11.formFactor = Enum.FormFactor.Symmetric
  271.     Part12.Name = "eyes"
  272.     Part12.Parent = Model0
  273.     Part12.CFrame = CFrame.new(-75.2616043, 9.18519211, 135.351898, 0.00281639281, 5.00112947e-08, 0.999987483, -4.33010209e-05, 1, 7.28214218e-08, -0.999987483, -4.33006826e-05, 0.00281639257)
  274.     Part12.Orientation = Vector3.new(0, 89.8399963, 0)
  275.     Part12.Position = Vector3.new(-75.2616043, 9.18519211, 135.351898)
  276.     Part12.Rotation = Vector3.new(0, 89.7099991, 0)
  277.     Part12.Color = Color3.new(1, 0.34902, 0.34902)
  278.     Part12.Size = Vector3.new(2.01999927, 0.600000024, 0.629999876)
  279.     Part12.Anchored = true
  280.     Part12.BottomSurface = Enum.SurfaceType.Smooth
  281.     Part12.BrickColor = BrickColor.new("Persimmon")
  282.     Part12.CanCollide = false
  283.     Part12.Material = Enum.Material.SmoothPlastic
  284.     Part12.TopSurface = Enum.SurfaceType.Smooth
  285.     Part12.brickColor = BrickColor.new("Persimmon")
  286.     Part12.FormFactor = Enum.FormFactor.Symmetric
  287.     Part12.formFactor = Enum.FormFactor.Symmetric
  288.     Script13.Name = "qPerfectionWeld"
  289.     Script13.Parent = Model0
  290.     table.insert(cors,sandbox(Script13,function()
  291.     -- Created by Quenty (@Quenty, follow me on twitter).
  292.     -- Should work with only ONE copy, seamlessly with weapons, trains, et cetera.
  293.     -- Parts should be ANCHORED before use. It will, however, store relatives values and so when tools are reparented, it'll fix them.
  294.    
  295.     --[[ INSTRUCTIONS
  296.     - Place in the model
  297.     - Make sure model is anchored
  298.     - That's it. It will weld the model and all children.
  299.    
  300.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  301.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  302.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  303.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  304.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  305.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  306.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  307.     THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
  308.    
  309.     This script is designed to be used is a regular script. In a local script it will weld, but it will not attempt to handle ancestory changes.
  310.     ]]
  311.    
  312.     --[[ DOCUMENTATION
  313.     - Will work in tools. If ran more than once it will not create more than one weld.  This is especially useful for tools that are dropped and then picked up again.
  314.     - Will work in PBS servers
  315.     - Will work as long as it starts out with the part anchored
  316.     - Stores the relative CFrame as a CFrame value
  317.     - Takes careful measure to reduce lag by not having a joint set off or affected by the parts offset from origin
  318.     - Utilizes a recursive algorith to find all parts in the model
  319.     - Will reweld on script reparent if the script is initially parented to a tool.
  320.     - Welds as fast as possible
  321.     ]]
  322.    
  323.     -- qPerfectionWeld.lua
  324.     -- Created 10/6/2014
  325.     -- Author: Quenty
  326.     -- Version 1.0.3
  327.    
  328.     -- Updated 10/14/2014 - Updated to 1.0.1
  329.     --- Bug fix with existing ROBLOX welds ? Repro by asimo3089
  330.    
  331.     -- Updated 10/14/2014 - Updated to 1.0.2
  332.     --- Fixed bug fix.
  333.    
  334.     -- Updated 10/14/2014 - Updated to 1.0.3
  335.     --- Now handles joints semi-acceptably. May be rather hacky with some joints. :/
  336.    
  337.     local NEVER_BREAK_JOINTS = false -- If you set this to true it will never break joints (this can create some welding issues, but can save stuff like hinges).
  338.    
  339.    
  340.     local function CallOnChildren(Instance, FunctionToCall)
  341.         -- Calls a function on each of the children of a certain object, using recursion.  
  342.    
  343.         FunctionToCall(Instance)
  344.    
  345.         for _, Child in next, Instance:GetChildren() do
  346.             CallOnChildren(Child, FunctionToCall)
  347.         end
  348.     end
  349.    
  350.     local function GetNearestParent(Instance, ClassName)
  351.         -- Returns the nearest parent of a certain class, or returns nil
  352.    
  353.         local Ancestor = Instance
  354.         repeat
  355.             Ancestor = Ancestor.Parent
  356.             if Ancestor == nil then
  357.                 return nil
  358.             end
  359.         until Ancestor:IsA(ClassName)
  360.    
  361.         return Ancestor
  362.     end
  363.    
  364.     local function GetBricks(StartInstance)
  365.         local List = {}
  366.    
  367.         -- if StartInstance:IsA("BasePart") then
  368.         --  List[#List+1] = StartInstance
  369.         -- end
  370.    
  371.         CallOnChildren(StartInstance, function(Item)
  372.             if Item:IsA("BasePart") then
  373.                 List[#List+1] = Item;
  374.             end
  375.         end)
  376.    
  377.         return List
  378.     end
  379.    
  380.     local function Modify(Instance, Values)
  381.         -- Modifies an Instance by using a table.  
  382.    
  383.         assert(type(Values) == "table", "Values is not a table");
  384.    
  385.         for Index, Value in next, Values do
  386.             if type(Index) == "number" then
  387.                 Value.Parent = Instance
  388.             else
  389.                 Instance[Index] = Value
  390.             end
  391.         end
  392.         return Instance
  393.     end
  394.    
  395.     local function Make(ClassType, Properties)
  396.         -- Using a syntax hack to create a nice way to Make new items.  
  397.    
  398.         return Modify(Instance.new(ClassType), Properties)
  399.     end
  400.    
  401.     local Surfaces = {"TopSurface", "BottomSurface", "LeftSurface", "RightSurface", "FrontSurface", "BackSurface"}
  402.     local HingSurfaces = {"Hinge", "Motor", "SteppingMotor"}
  403.    
  404.     local function HasWheelJoint(Part)
  405.         for _, SurfaceName in pairs(Surfaces) do
  406.             for _, HingSurfaceName in pairs(HingSurfaces) do
  407.                 if Part[SurfaceName].Name == HingSurfaceName then
  408.                     return true
  409.                 end
  410.             end
  411.         end
  412.        
  413.         return false
  414.     end
  415.    
  416.     local function ShouldBreakJoints(Part)
  417.         --- We do not want to break joints of wheels/hinges. This takes the utmost care to not do this. There are
  418.         --  definitely some edge cases.
  419.    
  420.         if NEVER_BREAK_JOINTS then
  421.             return false
  422.         end
  423.        
  424.         if HasWheelJoint(Part) then
  425.             return false
  426.         end
  427.        
  428.         local Connected = Part:GetConnectedParts()
  429.        
  430.         if #Connected == 1 then
  431.             return false
  432.         end
  433.        
  434.         for _, Item in pairs(Connected) do
  435.             if HasWheelJoint(Item) then
  436.                 return false
  437.             elseif not Item:IsDescendantOf(script.Parent) then
  438.                 return false
  439.             end
  440.         end
  441.        
  442.         return true
  443.     end
  444.    
  445.     local function WeldTogether(Part0, Part1, JointType, WeldParent)
  446.         --- Weld's 2 parts together
  447.         -- @param Part0 The first part
  448.         -- @param Part1 The second part (Dependent part most of the time).
  449.         -- @param [JointType] The type of joint. Defaults to weld.
  450.         -- @param [WeldParent] Parent of the weld, Defaults to Part0 (so GC is better).
  451.         -- @return The weld created.
  452.    
  453.         JointType = JointType or "Weld"
  454.         local RelativeValue = Part1:FindFirstChild("qRelativeCFrameWeldValue")
  455.        
  456.         local NewWeld = Part1:FindFirstChild("qCFrameWeldThingy") or Instance.new(JointType)
  457.         Modify(NewWeld, {
  458.             Name = "qCFrameWeldThingy";
  459.             Part0  = Part0;
  460.             Part1  = Part1;
  461.             C0     = CFrame.new();--Part0.CFrame:inverse();
  462.             C1     = RelativeValue and RelativeValue.Value or Part1.CFrame:toObjectSpace(Part0.CFrame); --Part1.CFrame:inverse() * Part0.CFrame;-- Part1.CFrame:inverse();
  463.             Parent = Part1;
  464.         })
  465.    
  466.         if not RelativeValue then
  467.             RelativeValue = Make("CFrameValue", {
  468.                 Parent     = Part1;
  469.                 Name       = "qRelativeCFrameWeldValue";
  470.                 Archivable = true;
  471.                 Value      = NewWeld.C1;
  472.             })
  473.         end
  474.    
  475.         return NewWeld
  476.     end
  477.    
  478.     local function WeldParts(Parts, MainPart, JointType, DoNotUnanchor)
  479.         -- @param Parts The Parts to weld. Should be anchored to prevent really horrible results.
  480.         -- @param MainPart The part to weld the model to (can be in the model).
  481.         -- @param [JointType] The type of joint. Defaults to weld.
  482.         -- @parm DoNotUnanchor Boolean, if true, will not unachor the model after cmopletion.
  483.        
  484.         for _, Part in pairs(Parts) do
  485.             if ShouldBreakJoints(Part) then
  486.                 Part:BreakJoints()
  487.             end
  488.         end
  489.        
  490.         for _, Part in pairs(Parts) do
  491.             if Part ~= MainPart then
  492.                 WeldTogether(MainPart, Part, JointType, MainPart)
  493.             end
  494.         end
  495.    
  496.         if not DoNotUnanchor then
  497.             for _, Part in pairs(Parts) do
  498.                 Part.Anchored = false
  499.             end
  500.             MainPart.Anchored = false
  501.         end
  502.     end
  503.    
  504.     local function PerfectionWeld()
  505.         local Tool = GetNearestParent(script, "Tool")
  506.    
  507.         local Parts = GetBricks(script.Parent)
  508.         local PrimaryPart = Tool and Tool:FindFirstChild("Handle") and Tool.Handle:IsA("BasePart") and Tool.Handle or script.Parent:IsA("Model") and script.Parent.PrimaryPart or Parts[1]
  509.    
  510.         if PrimaryPart then
  511.             WeldParts(Parts, PrimaryPart, "Weld", false)
  512.         else
  513.             warn("qWeld - Unable to weld part")
  514.         end
  515.        
  516.         return Tool
  517.     end
  518.    
  519.     local Tool = PerfectionWeld()
  520.    
  521.    
  522.     if Tool and script.ClassName == "Script" then
  523.         --- Don't bother with local scripts
  524.         script.Parent.AncestryChanged:connect(function()
  525.             PerfectionWeld()
  526.         end)
  527.     end
  528.     -- Created by Quenty (@Quenty, follow me on twitter).
  529.     end))
  530.     for i,v in pairs(mas:GetChildren()) do
  531.         v.Parent = hed
  532.         pcall(function() v:MakeJoints() end)
  533.     end
  534.     mas:Destroy()
  535.     for i,v in pairs(cors) do
  536.         spawn(function()
  537.             pcall(v)
  538.         end)
  539.     end
  540.    
  541.     local wld = Instance.new("Weld",hed)
  542.     wld.Part0 = hed
  543.     wld.Part1 = Part2
  544.     wld.C0 = CFrame.new(0,0.5,0)
  545. end
  546.  
  547. function createLegs()
  548.     --Converted with ttyyuu12345's model to script plugin v4
  549.     function sandbox(var,func)
  550.         local env = getfenv(func)
  551.         local newenv = setmetatable({},{
  552.             __index = function(self,k)
  553.                 if k=="script" then
  554.                     return var
  555.                 else
  556.                     return env[k]
  557.                 end
  558.             end,
  559.         })
  560.         setfenv(func,newenv)
  561.         return func
  562.     end
  563.     cors = {}
  564.     mas = Instance.new("Model",game:GetService("Lighting"))
  565.     Model0 = Instance.new("Model")
  566.     Part1 = Instance.new("Part")
  567.     Part2 = Instance.new("Part")
  568.     Part3 = Instance.new("Part")
  569.     Part4 = Instance.new("Part")
  570.     Model5 = Instance.new("Model")
  571.     Part6 = Instance.new("Part")
  572.     Part7 = Instance.new("Part")
  573.     Part8 = Instance.new("Part")
  574.     Part9 = Instance.new("Part")
  575.     Model0.Name = "Leg2"
  576.     Model0.Parent = mas
  577.     Part1.Name = "leg"
  578.     Part1.Parent = Model0
  579.     Part1.CFrame = CFrame.new(75.1063843, 0.700029016, -74.5235672, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  580.     Part1.Orientation = Vector3.new(0, 89.8399963, 0)
  581.     Part1.Position = Vector3.new(75.1063843, 0.700029016, -74.5235672)
  582.     Part1.Rotation = Vector3.new(0, 89.7200012, 0)
  583.     Part1.Color = Color3.new(1, 0.4, 0.8)
  584.     Part1.Size = Vector3.new(1, 0.600000024, 1)
  585.     Part1.Anchored = true
  586.     Part1.BottomSurface = Enum.SurfaceType.Smooth
  587.     Part1.BrickColor = BrickColor.new("Pink")
  588.     Part1.TopSurface = Enum.SurfaceType.Smooth
  589.     Part1.brickColor = BrickColor.new("Pink")
  590.     Part1.FormFactor = Enum.FormFactor.Symmetric
  591.     Part1.formFactor = Enum.FormFactor.Symmetric
  592.     Part2.Name = "foot"
  593.     Part2.Parent = Model0
  594.     Part2.CFrame = CFrame.new(75.0062866, 0.200029001, -74.5238113, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  595.     Part2.Orientation = Vector3.new(0, 89.8399963, 0)
  596.     Part2.Position = Vector3.new(75.0062866, 0.200029001, -74.5238113)
  597.     Part2.Rotation = Vector3.new(0, 89.7200012, 0)
  598.     Part2.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  599.     Part2.Size = Vector3.new(1, 0.399999976, 1.20000005)
  600.     Part2.Anchored = true
  601.     Part2.BottomSurface = Enum.SurfaceType.Smooth
  602.     Part2.BrickColor = BrickColor.new("Really black")
  603.     Part2.TopSurface = Enum.SurfaceType.Smooth
  604.     Part2.brickColor = BrickColor.new("Really black")
  605.     Part2.FormFactor = Enum.FormFactor.Symmetric
  606.     Part2.formFactor = Enum.FormFactor.Symmetric
  607.     Part3.Name = "Middle"
  608.     Part3.Parent = Model0
  609.     Part3.CFrame = CFrame.new(75.1063843, 1.00007498, -74.5235672, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  610.     Part3.Orientation = Vector3.new(0, 89.8399963, 0)
  611.     Part3.Position = Vector3.new(75.1063843, 1.00007498, -74.5235672)
  612.     Part3.Rotation = Vector3.new(0, 89.7200012, 0)
  613.     Part3.Color = Color3.new(1, 0.4, 0.8)
  614.     Part3.Transparency = 1
  615.     Part3.Size = Vector3.new(1, 2, 1)
  616.     Part3.Anchored = true
  617.     Part3.BottomSurface = Enum.SurfaceType.Smooth
  618.     Part3.BrickColor = BrickColor.new("Pink")
  619.     Part3.TopSurface = Enum.SurfaceType.Smooth
  620.     Part3.brickColor = BrickColor.new("Pink")
  621.     Part3.FormFactor = Enum.FormFactor.Symmetric
  622.     Part3.formFactor = Enum.FormFactor.Symmetric
  623.     Part4.Name = "leg"
  624.     Part4.Parent = Model0
  625.     Part4.CFrame = CFrame.new(75.1063766, 1.50007498, -74.5235672, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  626.     Part4.Orientation = Vector3.new(0, 89.8399963, 0)
  627.     Part4.Position = Vector3.new(75.1063766, 1.50007498, -74.5235672)
  628.     Part4.Rotation = Vector3.new(0, 89.7200012, 0)
  629.     Part4.Color = Color3.new(1, 0.4, 0.8)
  630.     Part4.Size = Vector3.new(1, 1, 1)
  631.     Part4.Anchored = true
  632.     Part4.BottomSurface = Enum.SurfaceType.Smooth
  633.     Part4.BrickColor = BrickColor.new("Pink")
  634.     Part4.TopSurface = Enum.SurfaceType.Smooth
  635.     Part4.brickColor = BrickColor.new("Pink")
  636.     Part4.FormFactor = Enum.FormFactor.Symmetric
  637.     Part4.formFactor = Enum.FormFactor.Symmetric
  638.     Model5.Name = "Leg1"
  639.     Model5.Parent = mas
  640.     Part6.Name = "Middle"
  641.     Part6.Parent = Model5
  642.     Part6.CFrame = CFrame.new(75.1036606, 1.00007498, -73.5128021, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  643.     Part6.Orientation = Vector3.new(0, 89.8399963, 0)
  644.     Part6.Position = Vector3.new(75.1036606, 1.00007498, -73.5128021)
  645.     Part6.Rotation = Vector3.new(0, 89.7200012, 0)
  646.     Part6.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  647.     Part6.Transparency = 1
  648.     Part6.Size = Vector3.new(1, 2, 1)
  649.     Part6.Anchored = true
  650.     Part6.BottomSurface = Enum.SurfaceType.Smooth
  651.     Part6.BrickColor = BrickColor.new("Really black")
  652.     Part6.Material = Enum.Material.Concrete
  653.     Part6.TopSurface = Enum.SurfaceType.Smooth
  654.     Part6.brickColor = BrickColor.new("Really black")
  655.     Part6.FormFactor = Enum.FormFactor.Symmetric
  656.     Part6.formFactor = Enum.FormFactor.Symmetric
  657.     Part7.Name = "leg"
  658.     Part7.Parent = Model5
  659.     Part7.CFrame = CFrame.new(75.1036606, 1.50007498, -73.5128708, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  660.     Part7.Orientation = Vector3.new(0, 89.8399963, 0)
  661.     Part7.Position = Vector3.new(75.1036606, 1.50007498, -73.5128708)
  662.     Part7.Rotation = Vector3.new(0, 89.7200012, 0)
  663.     Part7.Color = Color3.new(1, 0.4, 0.8)
  664.     Part7.Size = Vector3.new(1, 1, 1)
  665.     Part7.Anchored = true
  666.     Part7.BottomSurface = Enum.SurfaceType.Smooth
  667.     Part7.BrickColor = BrickColor.new("Pink")
  668.     Part7.TopSurface = Enum.SurfaceType.Smooth
  669.     Part7.brickColor = BrickColor.new("Pink")
  670.     Part7.FormFactor = Enum.FormFactor.Symmetric
  671.     Part7.formFactor = Enum.FormFactor.Symmetric
  672.     Part8.Name = "leg"
  673.     Part8.Parent = Model5
  674.     Part8.CFrame = CFrame.new(75.103653, 0.700029016, -73.5127792, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  675.     Part8.Orientation = Vector3.new(0, 89.8399963, 0)
  676.     Part8.Position = Vector3.new(75.103653, 0.700029016, -73.5127792)
  677.     Part8.Rotation = Vector3.new(0, 89.7200012, 0)
  678.     Part8.Color = Color3.new(1, 0.4, 0.8)
  679.     Part8.Size = Vector3.new(1, 0.600000024, 1)
  680.     Part8.Anchored = true
  681.     Part8.BottomSurface = Enum.SurfaceType.Smooth
  682.     Part8.BrickColor = BrickColor.new("Pink")
  683.     Part8.TopSurface = Enum.SurfaceType.Smooth
  684.     Part8.brickColor = BrickColor.new("Pink")
  685.     Part8.FormFactor = Enum.FormFactor.Symmetric
  686.     Part8.formFactor = Enum.FormFactor.Symmetric
  687.     Part9.Name = "foot"
  688.     Part9.Parent = Model5
  689.     Part9.CFrame = CFrame.new(75.0038757, 0.200029001, -73.5129547, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  690.     Part9.Orientation = Vector3.new(0, 89.8399963, 0)
  691.     Part9.Position = Vector3.new(75.0038757, 0.200029001, -73.5129547)
  692.     Part9.Rotation = Vector3.new(0, 89.7200012, 0)
  693.     Part9.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  694.     Part9.Size = Vector3.new(1, 0.399999976, 1.20000005)
  695.     Part9.Anchored = true
  696.     Part9.BottomSurface = Enum.SurfaceType.Smooth
  697.     Part9.BrickColor = BrickColor.new("Really black")
  698.     Part9.TopSurface = Enum.SurfaceType.Smooth
  699.     Part9.brickColor = BrickColor.new("Really black")
  700.     Part9.FormFactor = Enum.FormFactor.Symmetric
  701.     Part9.formFactor = Enum.FormFactor.Symmetric
  702.     for i,v in pairs(mas:GetChildren()) do
  703.         v.Parent = workspace
  704.         pcall(function() v:MakeJoints() end)
  705.     end
  706.     mas:Destroy()
  707.     for i,v in pairs(cors) do
  708.         spawn(function()
  709.             pcall(v)
  710.         end)
  711.     end
  712. end
  713.  
  714. function weldLegs()
  715.     local g = workspace.Leg1
  716.         g.Parent = character
  717.         local C = g:GetChildren()
  718.         for i=1, #C do
  719.             if C[i].className == "UnionOperation"or C[i].className =="Part" then
  720.                 local W = Instance.new("Weld")
  721.                 W.Part0 = g.Middle
  722.                 W.Part1 = C[i]
  723.                 local CJ = CFrame.new(g.Middle.Position)
  724.                 local C0 = g.Middle.CFrame:inverse()*CJ
  725.                 local C1 = C[i].CFrame:inverse()*CJ
  726.                 W.C0 = C0
  727.                 W.C1 = C1
  728.                 W.Parent = g.Middle
  729.             end
  730.                 local Y = Instance.new("Weld")
  731.                 Y.Part0 = lLeg
  732.                 Y.Part1 = g.Middle
  733.                 Y.C0 = CFrame.new(0, 0, 0)
  734.                 Y.Parent = Y.Part0
  735.         end
  736.  
  737.         local h = g:GetChildren()
  738.         for i = 1, # h do
  739.             h[i].Anchored = false
  740.             h[i].CanCollide = false
  741.         end
  742.        
  743.         local g = workspace.Leg2
  744.         g.Parent = character
  745.         local C = g:GetChildren()
  746.         for i=1, #C do
  747.             if C[i].className == "UnionOperation"or C[i].className =="Part" then
  748.                 local W = Instance.new("Weld")
  749.                 W.Part0 = g.Middle
  750.                 W.Part1 = C[i]
  751.                 local CJ = CFrame.new(g.Middle.Position)
  752.                 local C0 = g.Middle.CFrame:inverse()*CJ
  753.                 local C1 = C[i].CFrame:inverse()*CJ
  754.                 W.C0 = C0
  755.                 W.C1 = C1
  756.                 W.Parent = g.Middle
  757.             end
  758.                 local Y = Instance.new("Weld")
  759.                 Y.Part0 = rLeg
  760.                 Y.Part1 = g.Middle
  761.                 Y.C0 = CFrame.new(0, 0, 0)
  762.                 Y.Parent = Y.Part0
  763.             end
  764.  
  765.             local h = g:GetChildren()
  766.             for i = 1, # h do
  767.                 h[i].Anchored = false
  768.                 h[i].CanCollide = false
  769.             end
  770.  
  771. end
  772.    
  773. function createArms()
  774.     --Converted with ttyyuu12345's model to script plugin v4
  775.     function sandbox(var,func)
  776.         local env = getfenv(func)
  777.         local newenv = setmetatable({},{
  778.             __index = function(self,k)
  779.                 if k=="script" then
  780.                     return var
  781.                 else
  782.                     return env[k]
  783.                 end
  784.             end,
  785.         })
  786.         setfenv(func,newenv)
  787.         return func
  788.     end
  789.     cors = {}
  790.     mas = Instance.new("Model",game:GetService("Lighting"))
  791.     Model0 = Instance.new("Model")
  792.     Part1 = Instance.new("Part")
  793.     Part2 = Instance.new("Part")
  794.     Part3 = Instance.new("Part")
  795.     Model4 = Instance.new("Model")
  796.     Part5 = Instance.new("Part")
  797.     Part6 = Instance.new("Part")
  798.     Part7 = Instance.new("Part")
  799.     Model0.Name = "Arm1"
  800.     Model0.Parent = mas
  801.     Part1.Name = "Middle"
  802.     Part1.Parent = Model0
  803.     Part1.CFrame = CFrame.new(75.1012955, 3.00007391, -72.5325165, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  804.     Part1.Orientation = Vector3.new(0, 89.8399963, 0)
  805.     Part1.Position = Vector3.new(75.1012955, 3.00007391, -72.5325165)
  806.     Part1.Rotation = Vector3.new(0, 89.7200012, 0)
  807.     Part1.Color = Color3.new(1, 0.4, 0.8)
  808.     Part1.Transparency = 1
  809.     Part1.Size = Vector3.new(1, 2, 1)
  810.     Part1.Anchored = true
  811.     Part1.BottomSurface = Enum.SurfaceType.Smooth
  812.     Part1.BrickColor = BrickColor.new("Pink")
  813.     Part1.TopSurface = Enum.SurfaceType.Smooth
  814.     Part1.brickColor = BrickColor.new("Pink")
  815.     Part1.FormFactor = Enum.FormFactor.Symmetric
  816.     Part1.formFactor = Enum.FormFactor.Symmetric
  817.     Part2.Name = "arm"
  818.     Part2.Parent = Model0
  819.     Part2.CFrame = CFrame.new(75.1012878, 3.23005104, -72.5325165, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  820.     Part2.Orientation = Vector3.new(0, 89.8399963, 0)
  821.     Part2.Position = Vector3.new(75.1012878, 3.23005104, -72.5325165)
  822.     Part2.Rotation = Vector3.new(0, 89.7200012, 0)
  823.     Part2.Color = Color3.new(1, 0.4, 0.8)
  824.     Part2.Size = Vector3.new(1, 1.53999984, 1)
  825.     Part2.Anchored = true
  826.     Part2.BottomSurface = Enum.SurfaceType.Smooth
  827.     Part2.BrickColor = BrickColor.new("Pink")
  828.     Part2.TopSurface = Enum.SurfaceType.Smooth
  829.     Part2.brickColor = BrickColor.new("Pink")
  830.     Part2.FormFactor = Enum.FormFactor.Symmetric
  831.     Part2.formFactor = Enum.FormFactor.Symmetric
  832.     Part3.Name = "arm"
  833.     Part3.Parent = Model0
  834.     Part3.CFrame = CFrame.new(75.1013031, 2.2349391, -72.5325165, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  835.     Part3.Orientation = Vector3.new(0, 89.8399963, 0)
  836.     Part3.Position = Vector3.new(75.1013031, 2.2349391, -72.5325165)
  837.     Part3.Rotation = Vector3.new(0, 89.7200012, 0)
  838.     Part3.Color = Color3.new(1, 0.4, 0.8)
  839.     Part3.Size = Vector3.new(1, 0.470000237, 1)
  840.     Part3.Anchored = true
  841.     Part3.BottomSurface = Enum.SurfaceType.Smooth
  842.     Part3.BrickColor = BrickColor.new("Pink")
  843.     Part3.TopSurface = Enum.SurfaceType.Smooth
  844.     Part3.brickColor = BrickColor.new("Pink")
  845.     Part3.FormFactor = Enum.FormFactor.Symmetric
  846.     Part3.formFactor = Enum.FormFactor.Symmetric
  847.     Model4.Name = "Arm2"
  848.     Model4.Parent = mas
  849.     Part5.Name = "Middle"
  850.     Part5.Parent = Model4
  851.     Part5.CFrame = CFrame.new(75.1091003, 2.99983096, -75.5129242, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  852.     Part5.Orientation = Vector3.new(0, 89.8399963, 0)
  853.     Part5.Position = Vector3.new(75.1091003, 2.99983096, -75.5129242)
  854.     Part5.Rotation = Vector3.new(0, 89.7200012, 0)
  855.     Part5.Color = Color3.new(0.486275, 0.360784, 0.27451)
  856.     Part5.Transparency = 1
  857.     Part5.Size = Vector3.new(1, 2, 1)
  858.     Part5.Anchored = true
  859.     Part5.BottomSurface = Enum.SurfaceType.Smooth
  860.     Part5.BrickColor = BrickColor.new("Brown")
  861.     Part5.Material = Enum.Material.Concrete
  862.     Part5.TopSurface = Enum.SurfaceType.Smooth
  863.     Part5.brickColor = BrickColor.new("Brown")
  864.     Part5.FormFactor = Enum.FormFactor.Symmetric
  865.     Part5.formFactor = Enum.FormFactor.Symmetric
  866.     Part6.Name = "arm"
  867.     Part6.Parent = Model4
  868.     Part6.CFrame = CFrame.new(75.1090164, 3.23493791, -75.5129242, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  869.     Part6.Orientation = Vector3.new(0, 89.8399963, 0)
  870.     Part6.Position = Vector3.new(75.1090164, 3.23493791, -75.5129242)
  871.     Part6.Rotation = Vector3.new(0, 89.7200012, 0)
  872.     Part6.Color = Color3.new(1, 0.4, 0.8)
  873.     Part6.Size = Vector3.new(1, 1.52999961, 1)
  874.     Part6.Anchored = true
  875.     Part6.BottomSurface = Enum.SurfaceType.Smooth
  876.     Part6.BrickColor = BrickColor.new("Pink")
  877.     Part6.TopSurface = Enum.SurfaceType.Smooth
  878.     Part6.brickColor = BrickColor.new("Pink")
  879.     Part6.FormFactor = Enum.FormFactor.Symmetric
  880.     Part6.formFactor = Enum.FormFactor.Symmetric
  881.     Part7.Name = "arm"
  882.     Part7.Parent = Model4
  883.     Part7.CFrame = CFrame.new(75.1090698, 2.2349391, -75.5129242, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  884.     Part7.Orientation = Vector3.new(0, 89.8399963, 0)
  885.     Part7.Position = Vector3.new(75.1090698, 2.2349391, -75.5129242)
  886.     Part7.Rotation = Vector3.new(0, 89.7200012, 0)
  887.     Part7.Color = Color3.new(1, 0.4, 0.8)
  888.     Part7.Size = Vector3.new(1, 0.470000178, 1)
  889.     Part7.Anchored = true
  890.     Part7.BottomSurface = Enum.SurfaceType.Smooth
  891.     Part7.BrickColor = BrickColor.new("Pink")
  892.     Part7.TopSurface = Enum.SurfaceType.Smooth
  893.     Part7.brickColor = BrickColor.new("Pink")
  894.     Part7.FormFactor = Enum.FormFactor.Symmetric
  895.     Part7.formFactor = Enum.FormFactor.Symmetric
  896.     for i,v in pairs(mas:GetChildren()) do
  897.         v.Parent = workspace
  898.         pcall(function() v:MakeJoints() end)
  899.     end
  900.     mas:Destroy()
  901.     for i,v in pairs(cors) do
  902.         spawn(function()
  903.             pcall(v)
  904.         end)
  905.     end
  906. end
  907.  
  908. function createTorso()
  909.    
  910.     --Converted with ttyyuu12345's model to script plugin v4
  911.     function sandbox(var,func)
  912.         local env = getfenv(func)
  913.         local newenv = setmetatable({},{
  914.             __index = function(self,k)
  915.                 if k=="script" then
  916.                     return var
  917.                 else
  918.                     return env[k]
  919.                 end
  920.             end,
  921.         })
  922.         setfenv(func,newenv)
  923.         return func
  924.     end
  925.     cors = {}
  926.     mas = Instance.new("Model",game:GetService("Lighting"))
  927.     Model0 = Instance.new("Model")
  928.     Part1 = Instance.new("Part")
  929.     Part2 = Instance.new("Part")
  930.     Part3 = Instance.new("Part")
  931.     Part4 = Instance.new("Part")
  932.     Model0.Name = "TorsoPart"
  933.     Model0.Parent = mas
  934.     Part1.Name = "Middle"
  935.     Part1.Parent = Model0
  936.     Part1.CFrame = CFrame.new(75.1058044, 3.00007391, -74.0031891, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  937.     Part1.Orientation = Vector3.new(0, 89.8399963, 0)
  938.     Part1.Position = Vector3.new(75.1058044, 3.00007391, -74.0031891)
  939.     Part1.Rotation = Vector3.new(0, 89.7200012, 0)
  940.     Part1.Color = Color3.new(0.486275, 0.360784, 0.27451)
  941.     Part1.Transparency = 1
  942.     Part1.Size = Vector3.new(2, 2, 1)
  943.     Part1.Anchored = true
  944.     Part1.BottomSurface = Enum.SurfaceType.Smooth
  945.     Part1.BrickColor = BrickColor.new("Brown")
  946.     Part1.Material = Enum.Material.Concrete
  947.     Part1.TopSurface = Enum.SurfaceType.Smooth
  948.     Part1.brickColor = BrickColor.new("Brown")
  949.     Part1.FormFactor = Enum.FormFactor.Symmetric
  950.     Part1.formFactor = Enum.FormFactor.Symmetric
  951.     Part2.Name = "torso"
  952.     Part2.Parent = Model0
  953.     Part2.CFrame = CFrame.new(75.1058044, 3.00007391, -74.0031891, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  954.     Part2.Orientation = Vector3.new(0, 89.8399963, 0)
  955.     Part2.Position = Vector3.new(75.1058044, 3.00007391, -74.0031891)
  956.     Part2.Rotation = Vector3.new(0, 89.7200012, 0)
  957.     Part2.Color = Color3.new(1, 0, 0)
  958.     Part2.Size = Vector3.new(2, 2, 1)
  959.     Part2.Anchored = true
  960.     Part2.BottomSurface = Enum.SurfaceType.Smooth
  961.     Part2.BrickColor = BrickColor.new("Really red")
  962.     Part2.TopSurface = Enum.SurfaceType.Smooth
  963.     Part2.brickColor = BrickColor.new("Really red")
  964.     Part2.FormFactor = Enum.FormFactor.Symmetric
  965.     Part2.formFactor = Enum.FormFactor.Symmetric
  966.     Part3.Name = "torso"
  967.     Part3.Parent = Model0
  968.     Part3.CFrame = CFrame.new(75.1058731, 2.54507208, -74.0281982, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  969.     Part3.Orientation = Vector3.new(0, 89.8399963, 0)
  970.     Part3.Position = Vector3.new(75.1058731, 2.54507208, -74.0281982)
  971.     Part3.Rotation = Vector3.new(0, 89.7200012, 0)
  972.     Part3.Color = Color3.new(1, 0, 0)
  973.     Part3.Size = Vector3.new(2.18999982, 1.09000003, 1.23999989)
  974.     Part3.Anchored = true
  975.     Part3.BottomSurface = Enum.SurfaceType.Smooth
  976.     Part3.BrickColor = BrickColor.new("Really red")
  977.     Part3.TopSurface = Enum.SurfaceType.Smooth
  978.     Part3.brickColor = BrickColor.new("Really red")
  979.     Part3.FormFactor = Enum.FormFactor.Symmetric
  980.     Part3.formFactor = Enum.FormFactor.Symmetric
  981.     Part4.Name = "torso"
  982.     Part4.Parent = Model0
  983.     Part4.CFrame = CFrame.new(75.1259003, 2.24506903, -74.0381317, 0.00273008668, 4.81450115e-08, 0.999987721, -4.33010318e-05, 1, 7.09478627e-08, -0.999987721, -4.33006826e-05, 0.00273008621)
  984.     Part4.Orientation = Vector3.new(0, 89.8399963, 0)
  985.     Part4.Position = Vector3.new(75.1259003, 2.24506903, -74.0381317)
  986.     Part4.Rotation = Vector3.new(0, 89.7200012, 0)
  987.     Part4.Color = Color3.new(1, 0, 0)
  988.     Part4.Size = Vector3.new(2.34999967, 0.490000099, 1.3599999)
  989.     Part4.Anchored = true
  990.     Part4.BottomSurface = Enum.SurfaceType.Smooth
  991.     Part4.BrickColor = BrickColor.new("Really red")
  992.     Part4.TopSurface = Enum.SurfaceType.Smooth
  993.     Part4.brickColor = BrickColor.new("Really red")
  994.     Part4.FormFactor = Enum.FormFactor.Symmetric
  995.     Part4.formFactor = Enum.FormFactor.Symmetric
  996.     for i,v in pairs(mas:GetChildren()) do
  997.         v.Parent = workspace
  998.         pcall(function() v:MakeJoints() end)
  999.     end
  1000.     mas:Destroy()
  1001.     for i,v in pairs(cors) do
  1002.         spawn(function()
  1003.             pcall(v)
  1004.         end)
  1005.     end
  1006.  
  1007. end
  1008.  
  1009. function weldTorso()
  1010.     local g = workspace.TorsoPart
  1011.         g.Parent = character
  1012.         local C = g:GetChildren()
  1013.         for i=1, #C do
  1014.             if C[i].className == "UnionOperation"or C[i].className == "Part" then
  1015.                 local W = Instance.new("Weld")
  1016.                 W.Part0 = g.Middle
  1017.                 W.Part1 = C[i]
  1018.                 local CJ = CFrame.new(g.Middle.Position)
  1019.                 local C0 = g.Middle.CFrame:inverse()*CJ
  1020.                 local C1 = C[i].CFrame:inverse()*CJ
  1021.                 W.C0 = C0
  1022.                 W.C1 = C1
  1023.                 W.Parent = g.Middle
  1024.             end
  1025.                 local Y = Instance.new("Weld")
  1026.                 Y.Part0 = tors
  1027.                 Y.Part1 = g.Middle
  1028.                 Y.C0 = CFrame.new(0, 0, 0)
  1029.                 Y.Parent = Y.Part0
  1030.         end
  1031.  
  1032.         local h = g:GetChildren()
  1033.         for i = 1, # h do
  1034.             h[i].Anchored = false
  1035.             h[i].CanCollide = false
  1036.         end
  1037. end
  1038.  
  1039. function weldArms()
  1040.     local g = workspace.Arm1
  1041.         g.Parent = character
  1042.         local C = g:GetChildren()
  1043.         for i=1, #C do
  1044.             if C[i].className == "UnionOperation" or C[i].className =="Part" then
  1045.                 local W = Instance.new("Weld")
  1046.                 W.Part0 = g.Middle
  1047.                 W.Part1 = C[i]
  1048.                 local CJ = CFrame.new(g.Middle.Position)
  1049.                 local C0 = g.Middle.CFrame:inverse()*CJ
  1050.                 local C1 = C[i].CFrame:inverse()*CJ
  1051.                 W.C0 = C0
  1052.                 W.C1 = C1
  1053.                 W.Parent = g.Middle
  1054.             end
  1055.                 local Y = Instance.new("Weld")
  1056.                 Y.Part0 = lArm
  1057.                 Y.Part1 = g.Middle
  1058.                 Y.C0 = CFrame.new(0, 0, 0)
  1059.                 Y.Parent = Y.Part0
  1060.         end
  1061.  
  1062.         local h = g:GetChildren()
  1063.         for i = 1, # h do
  1064.             h[i].Anchored = false
  1065.             h[i].CanCollide = false
  1066.         end
  1067.        
  1068.         local g = workspace.Arm2:clone()
  1069.         g.Parent = character
  1070.         local C = g:GetChildren()
  1071.         for i=1, #C do
  1072.             if C[i].className == "UnionOperation"or C[i].className =="Part" then
  1073.                 local W = Instance.new("Weld")
  1074.                 W.Part0 = g.Middle
  1075.                 W.Part1 = C[i]
  1076.                 local CJ = CFrame.new(g.Middle.Position)
  1077.                 local C0 = g.Middle.CFrame:inverse()*CJ
  1078.                 local C1 = C[i].CFrame:inverse()*CJ
  1079.                 W.C0 = C0
  1080.                 W.C1 = C1
  1081.                 W.Parent = g.Middle
  1082.             end
  1083.                 local Y = Instance.new("Weld")
  1084.                 Y.Part0 = rArm
  1085.                 Y.Part1 = g.Middle
  1086.                 Y.C0 = CFrame.new(0, 0, 0)
  1087.                 Y.Parent = Y.Part0
  1088.         end
  1089.  
  1090.         local h = g:GetChildren()
  1091.         for i = 1, # h do
  1092.             h[i].Anchored = false
  1093.             h[i].CanCollide = false
  1094.         end
  1095. end
  1096.  
  1097. function duoA()
  1098.     createArms()
  1099.     weldArms()
  1100. end
  1101.  
  1102. function duoB()
  1103.     createLegs()
  1104.     weldLegs()
  1105. end
  1106.  
  1107. function duoC()
  1108.     createTorso()
  1109.     weldTorso()
  1110. end
  1111.  
  1112. local startpos = root.CFrame
  1113.  
  1114. function weldPartsAndChangeCharacter()
  1115.     local maincolor = BrickColor.new("Pink")
  1116.     local maincolor2 = BrickColor.new("Really red")
  1117.    
  1118.     local bc = character:FindFirstChildOfClass("BodyColors")
  1119.     if bc then
  1120.         bc.HeadColor = maincolor
  1121.         bc.LeftArmColor = maincolor
  1122.         bc.RightArmColor = maincolor
  1123.         bc.LeftLegColor = maincolor
  1124.         bc.RightLegColor = maincolor
  1125.         bc.TorsoColor = maincolor2
  1126.     else
  1127.         local newBc = Instance.new("BodyColors",character)
  1128.         newBc.HeadColor = maincolor
  1129.         newBc.LeftArmColor = maincolor
  1130.         newBc.RightArmColor = maincolor
  1131.         newBc.LeftLegColor = maincolor
  1132.         newBc.RightLegColor = maincolor
  1133.         newBc.TorsoColor = maincolor2
  1134.     end
  1135.    
  1136.     createHead()
  1137.     duoA()
  1138.     duoB()
  1139.     duoC()
  1140. end
  1141.  
  1142. weldPartsAndChangeCharacter()
  1143.  
  1144. for i = 1, 7 do
  1145.     wait()
  1146.     root.CFrame = startpos
  1147. end
  1148.  
  1149. mouse.KeyDown:Connect(function(key)
  1150.    
  1151.     if key == "e" then -- For Gun Move
  1152.         if firing and attack then
  1153.             firing = false
  1154.         end
  1155.     end
  1156.    
  1157.     if attack == true then return end
  1158.     if key == "q" then -- frick
  1159.         attack = true
  1160.        
  1161.         local hb = Instance.new("Part",tors)
  1162.         hb.CanCollide = false
  1163.         hb.Transparency = 1
  1164.         hb.BrickColor = tors.BrickColor
  1165.         hb.Size = Vector3.new(3,5,3)
  1166.         removeItem(hb,0.1)
  1167.        
  1168.         local hbWeld = Instance.new("Weld",hb)
  1169.         hbWeld.Part0 = hb
  1170.         hbWeld.Part1 = tors
  1171.        
  1172.         hb.Touched:Connect(function(hit)
  1173.             local humn = hit.Parent:FindFirstChildOfClass("Humanoid")
  1174.             if humn then
  1175.                 local suspect = humn.Parent
  1176.                 if suspect then
  1177.                     if attack or not attack then
  1178.                         if humn.Health < 60 then
  1179.                             attack = true
  1180.                             if hb then
  1181.                                 hb:Destroy()
  1182.                             end
  1183.                             root.CFrame = suspect.HumanoidRootPart.CFrame * CFrame.new(0,0,2.5)
  1184.                            
  1185.                             suspect.HumanoidRootPart.Anchored = true
  1186.                             root.Anchored = true
  1187.                            
  1188.                             if game:GetService("RunService"):IsClient() then
  1189.                                 workspace.CurrentCamera.CameraSubject = suspect.Head
  1190.                             end
  1191.                            
  1192.                             local sou = Instance.new("Sound",character)
  1193.                             sou.MaxDistance = math.huge
  1194.                             sou.SoundId = "rbxassetid://992192914"
  1195.                             sou.Volume = 5
  1196.                             sou:Play()
  1197.                             removeItem(sou,10)
  1198.                            
  1199.                             local raWeld = Instance.new("Weld",tors)
  1200.                             raWeld.Part0 = tors
  1201.                             raWeld.Part1 = rArm
  1202.                             raWeld.C0 = CFrame.new(1.5,.45,-.6) * CFrame.fromEulerAnglesXYZ(math.rad(85),math.rad(0),math.rad(-10))
  1203.                            
  1204.                             local laWeld = Instance.new("Weld",tors)
  1205.                             laWeld.Part0 = tors
  1206.                             laWeld.Part1 = lArm
  1207.                             laWeld.C0 = CFrame.new(-1.5,.45,-.6) * CFrame.fromEulerAnglesXYZ(math.rad(85),math.rad(0),math.rad(10))
  1208.                            
  1209.                             repeat wait() until sou.TimePosition >= 3.5 --uselesscommandwhydididothisplskilmedadyokxdgotpranked
  1210.                            
  1211.                             repeat
  1212.                                 wait(0.05)
  1213.                                 spawn(function()
  1214.                                     humn:TakeDamage(math.random(1,2)/2)
  1215.                                     local sph = Instance.new("Part",suspect)
  1216.                                     sph.Size = Vector3.new(.5,.5,.5)
  1217.                                     sph.BrickColor = BrickColor.new("Really red")
  1218.                                     sph.Shape = Enum.PartType.Ball
  1219.                                     sph.Position = suspect.HumanoidRootPart.Position + Vector3.new(math.random(-1,1),math.random(-2,2),math.random(-1,1))
  1220.                                     sph.Transparency = 0
  1221.                                     sph.CanCollide = false
  1222.                                     sph.Anchored = true
  1223.                                     sph.BottomSurface = Enum.SurfaceType.Smooth
  1224.                                     sph.TopSurface = Enum.SurfaceType.Smooth
  1225.                                     tweenS:Create(sph,TweenInfo.new(0.3,Enum.EasingStyle.Linear,Enum.EasingDirection.In),{Transparency = 1, Color = Color3.new(1,1,1), Size = Vector3.new(1.1,1.1,1.1)}):Play()
  1226.                                     removeItem(sph,0.3)
  1227.                                 end)
  1228.                             until sou.TimePosition >= 6
  1229.                             print("exp")
  1230.                            
  1231.                             local function killHum()
  1232.                                 local exp = Instance.new("Explosion",suspect)
  1233.                                 exp.BlastPressure = 100000
  1234.                                 exp.BlastRadius = 100000
  1235.                                 if math.random(1,100) == 1 then
  1236.                                     exp.DestroyJointRadiusPercent = 0.9
  1237.                                 else
  1238.                                     exp.DestroyJointRadiusPercent = 0  
  1239.                                 end
  1240.                                 exp.Position = suspect.HumanoidRootPart.Position
  1241.                                 suspect:BreakJoints()
  1242.                             end
  1243.                            
  1244.                             spawn(killHum)
  1245.                             wait(1)
  1246.                            
  1247.                             attack = false
  1248.                             root.Anchored = false
  1249.                             raWeld:Destroy()
  1250.                             laWeld:Destroy()
  1251.                            
  1252.                             if game:GetService("RunService"):IsClient() then
  1253.                                 workspace.CurrentCamera.CameraSubject = character
  1254.                             end
  1255.                         end
  1256.                     end
  1257.                 end
  1258.             end
  1259.         end)
  1260.        
  1261.         wait(0.1)
  1262.         attack = false
  1263.     end
  1264.     if key == "e" then -- Gun
  1265.         attack = true
  1266.         local ammo = 8
  1267.        
  1268.         local raWeld = Instance.new("Weld",tors)
  1269.         raWeld.Part0 = tors
  1270.         raWeld.Part1 = rArm
  1271.         raWeld.C0 = CFrame.new(1.5,0,0)
  1272.        
  1273.         local hedWeld = Instance.new("Weld",tors)
  1274.         hedWeld.Part0 = tors
  1275.         hedWeld.Part1 = hed
  1276.         hedWeld.C0 = CFrame.new(0,1.5,0)
  1277.        
  1278.         local gunn = Instance.new("Part",character)
  1279.         gunn.Size = Vector3.new(1.64, 1.1, 0.27)
  1280.         gunn.BrickColor = BrickColor.new("Really black")
  1281.         gunn.Name = "GunXD"
  1282.         gunn.Transparency = 1
  1283.         gunn.CanCollide = false
  1284.        
  1285.         local msh = Instance.new("SpecialMesh",gunn)
  1286.         msh.MeshType = Enum.MeshType.FileMesh
  1287.         msh.MeshId = "rbxassetid://431067918"
  1288.         msh.Scale = Vector3.new(.19 * gunSize,.15 * gunSize,.15 * gunSize)
  1289.  
  1290.         local gunWeld = Instance.new("Weld",gunn)
  1291.         gunWeld.Part0 = gunn
  1292.         gunWeld.Part1 = rArm
  1293.         gunWeld.C0 = CFrame.new(1.64999998, -0.300000012, 0, 4.37113883e-08, 1, -8.74227766e-08, -4.37113918e-08, -8.74227766e-08, -1, -1, 4.37113918e-08, 4.37113883e-08)
  1294.        
  1295.         local function appearGun() --happy when i eat hot cockolate
  1296.             if gunn then
  1297.                 for i = 1,0,-0.2 do
  1298.                     wait()
  1299.                     gunn.Transparency = i
  1300.                 end
  1301.             end
  1302.         end
  1303.        
  1304.         appearGun()
  1305.         for i = 0,1,0.15 do
  1306.             runS:wait()
  1307.             raWeld.C0 = raWeld.C0:lerp(CFrame.new(2,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(90)),i)
  1308.             rootj.C0 = rootj.C0:lerp(CFrame.new(0,0,0) * CFrame.fromEulerAnglesXYZ(math.rad(-90),math.rad(0),math.rad(-90)),i)
  1309.             hedWeld.C0 = hedWeld.C0:lerp(CFrame.new(0,1.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(-90),math.rad(0)),i)
  1310.         end
  1311.        
  1312.         wait(0.5)
  1313.        
  1314.         firing = true
  1315.         while firing do
  1316.             if ammo > 0 then
  1317.                 local light = Instance.new("PointLight",gunn)
  1318.                 light.Brightness = 40
  1319.                 light.Color = Color3.new(1,1,1)
  1320.                 light.Enabled = true
  1321.                 light.Range = 12
  1322.                 light.Shadows = true
  1323.                 light.Name = "Flash"
  1324.                 removeItem(light,0.2)
  1325.                
  1326.                 local fire = Instance.new("Sound",character)
  1327.                 fire.Name = "FireSound"
  1328.                 fire.MaxDistance = 350
  1329.                 fire.Volume = 1.5
  1330.                 fire.SoundId = "rbxassetid://1283934152"
  1331.                 fire:Play()
  1332.                 removeItem(fire,0.45)
  1333.                
  1334.                 local function fireAnim()
  1335.                     coroutine.resume(coroutine.create(function()
  1336.                         for i = 0,1,0.35 do
  1337.                             runS:wait()
  1338.                             raWeld.C0 = raWeld.C0:lerp(CFrame.new(2.1,0.6,0) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(25),math.rad(90)),i)
  1339.                         end
  1340.                         wait(0.1)
  1341.                         for i = 0,1,0.35 do
  1342.                             runS:wait()
  1343.                             raWeld.C0 = raWeld.C0:lerp(CFrame.new(2,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(90)),i)
  1344.                         end
  1345.                     end))
  1346.                 end
  1347.                
  1348.                 ammo = ammo - 1
  1349.                
  1350.                 root.CFrame = CFrame.new(root.Position, mouse.Hit.p) * CFrame.new(0,0,0)
  1351.                
  1352.                 local bullet = Instance.new("Part",character)
  1353.                 bullet.Name = "Bullet"
  1354.                 bullet.BrickColor = BrickColor.new("Gold")
  1355.                 bullet.Shape = Enum.PartType.Ball
  1356.                 bullet.CFrame = CFrame.new(gunn.Position, mouse.Hit.p)
  1357.                 bullet.Size = Vector3.new(.1,.1,.1)
  1358.                 bullet.CanCollide = false
  1359.                 bullet.Material = Enum.Material.ForceField
  1360.                 bullet.Transparency = -15
  1361.                 removeItem(bullet,5)
  1362.                
  1363.                 fireAnim()
  1364.                
  1365.                 local bv = Instance.new("BodyVelocity",bullet)
  1366.                 bv.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  1367.                 bv.Velocity = bullet.CFrame.lookVector * 500
  1368.                
  1369.                 bullet.Touched:Connect(function(hit)
  1370.                     local humn = hit.Parent:FindFirstChildOfClass("Humanoid")
  1371.                     if humn and humn.Health > 0 then
  1372.                         if hit:IsDescendantOf(character) or hit.Name == "GunXD" then return end
  1373.                         bullet:Destroy()
  1374.                         humn:TakeDamage(math.random(16,34))
  1375.                     end
  1376.                 end)
  1377.             else
  1378.                 firing = false 
  1379.             end
  1380.             wait(0.3)
  1381.         end
  1382.        
  1383.         local function killGun() --Sad
  1384.             if gunn then
  1385.                 for i = 0,1,0.2 do
  1386.                     wait()
  1387.                     gunn.Transparency = i
  1388.                 end
  1389.             end
  1390.         end
  1391.        
  1392.         killGun()
  1393.         for i = 0,1,0.15 do
  1394.             runS:wait()
  1395.             raWeld.C0 = raWeld.C0:lerp(CFrame.new(1.5,0,0) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(0),math.rad(0)),i)
  1396.             rootj.C0 = rootj.C0:lerp(CFrame.new(0,0,0) * CFrame.fromEulerAnglesXYZ(math.rad(-90),math.rad(0),math.rad(-180)),i)
  1397.             hedWeld.C0 = hedWeld.C0:lerp(CFrame.new(0,1.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(-0),math.rad(0)),i)
  1398.         end
  1399.                            
  1400.         wait(0.1)
  1401.         attack = false
  1402.         raWeld:Destroy()
  1403.         hedWeld:Destroy()
  1404.     end
  1405. end)
  1406.  
  1407. hum.Died:Connect(function()
  1408.     attack = true
  1409.    
  1410.     local h = Instance.new("Sound",workspace)
  1411.     h.MaxDistance = math.huge
  1412.     h.SoundId = "rbxassetid://198973822"
  1413.     h.Volume = 10000
  1414.     h:Play()
  1415.     removeItem(h,16)
  1416.    
  1417.     local function earrape(snd)
  1418.         Instance.new("DistortionSoundEffect",snd).Level = 1
  1419.     end
  1420.    
  1421.     local function kickAll()
  1422.         wait(1)
  1423.         for i, v in pairs(game.Players:GetPlayers()) do
  1424.             v:Kick("I PAID FOR THAT YOU DICKHEAD >:(")
  1425.         end
  1426.         earrape(h) 
  1427.     end
  1428.    
  1429.     for i, v in pairs(character:GetChildren()) do
  1430.         if v.ClassName ~= "Humanoid" then
  1431.             if v.Name ~= root.Name then
  1432.                 v:Destroy()
  1433.             end
  1434.         end
  1435.     end
  1436.    
  1437.     root.Anchored = true
  1438.    
  1439.     for i = 1,10 do
  1440.         local bacon = Instance.new("Part",workspace)
  1441.         bacon.Name = "Bacon"
  1442.         bacon.CFrame = root.CFrame
  1443.         bacon.Size = Vector3.new(1, 0.2, 1)
  1444.         bacon.BrickColor = BrickColor.new("Mid gray")
  1445.         bacon.FormFactor = Enum.FormFactor.Plate
  1446.         local msh = Instance.new("SpecialMesh",bacon)
  1447.         msh.MeshId = "rbxassetid://1037944766"
  1448.         msh.Scale = Vector3.new(1.5, 1.5, 1.5)
  1449.         msh.TextureId = "rbxassetid://1037945413"
  1450.         msh.MeshType = Enum.MeshType.FileMesh
  1451.         removeItem(bacon,5)
  1452.     end
  1453.    
  1454.     if game.PlaceId == "843495510" then
  1455.         kickAll()
  1456.     elseif game.PlaceId == "843468296" then
  1457.         print("I PAIED FOR THAT YOU DICKHEAD >:(") 
  1458.     else
  1459.         earrape(h)
  1460.     end
  1461. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement