Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --https://github.com/Mokiros/roblox-FE-compatibility
- if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
- local Player,game,owner = owner,game
- local RealPlayer = Player
- do
- print("FE Compatibility code V2 by Mokiros")
- local RealPlayer = RealPlayer
- script.Parent = RealPlayer.Character
- --Fake event to make stuff like Mouse.KeyDown work
- local Disconnect_Function = function(this)
- this[1].Functions[this[2]] = nil
- end
- local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
- local FakeEvent_Metatable = {__index={
- Connect = function(this,f)
- local i = tostring(math.random(0,10000))
- while this.Functions[i] do
- i = tostring(math.random(0,10000))
- end
- this.Functions[i] = f
- return setmetatable({this,i},Disconnect_Metatable)
- end
- }}
- FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
- local function fakeEvent()
- return setmetatable({Functions={}},FakeEvent_Metatable)
- end
- --Creating fake input objects with fake variables
- local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
- FakeMouse.keyUp = FakeMouse.KeyUp
- FakeMouse.keyDown = FakeMouse.KeyDown
- local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
- local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
- CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
- end}
- --Merged 2 functions into one by checking amount of arguments
- CAS.UnbindAction = CAS.BindAction
- --This function will trigger the events that have been :Connect()'ed
- local function TriggerEvent(self,ev,...)
- for _,f in pairs(self[ev].Functions) do
- f(...)
- end
- end
- FakeMouse.TriggerEvent = TriggerEvent
- UIS.TriggerEvent = TriggerEvent
- --Client communication
- local Event = Instance.new("RemoteEvent")
- Event.Name = "UserInput_Event"
- Event.OnServerEvent:Connect(function(plr,io)
- if plr~=RealPlayer then return end
- FakeMouse.Target = io.Target
- FakeMouse.Hit = io.Hit
- if not io.isMouse then
- local b = io.UserInputState == Enum.UserInputState.Begin
- if io.UserInputType == Enum.UserInputType.MouseButton1 then
- return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
- end
- if io.UserInputType == Enum.UserInputType.MouseButton2 then
- return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
- end
- for _,t in pairs(CAS.Actions) do
- for _,k in pairs(t.Keys) do
- if k==io.KeyCode then
- t.Function(t.Name,io.UserInputState,io)
- end
- end
- end
- FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
- UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
- end
- end)
- Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
- local Mouse = owner:GetMouse()
- local UIS = game:GetService("UserInputService")
- local input = function(io,RobloxHandled)
- if RobloxHandled then return end
- --Since InputObject is a client-side instance, we create and pass table instead
- Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
- end
- UIS.InputBegan:Connect(input)
- UIS.InputEnded:Connect(input)
- local h,t
- --Give the server mouse data every second frame, but only if the values changed
- --If player is not moving their mouse, client won't fire events
- local HB = game:GetService("RunService").Heartbeat
- while true do
- if h~=Mouse.Hit or t~=Mouse.Target then
- h,t=Mouse.Hit,Mouse.Target
- Event:FireServer({isMouse=true,Target=t,Hit=h})
- end
- --Wait 2 frames
- for i=1,2 do
- HB:Wait()
- end
- end]==],script)
- ----Sandboxed game object that allows the usage of client-side methods and services
- --Real game object
- local RealGame = game
- --Metatable for fake service
- local FakeService_Metatable = {
- __index = function(self,k)
- local s = rawget(self,"_RealService")
- if s then
- return typeof(s[k])=="function"
- and function(_,...)return s[k](s,...)end or s[k]
- end
- end,
- __newindex = function(self,k,v)
- local s = rawget(self,"_RealService")
- if s then s[k]=v end
- end
- }
- local function FakeService(t,RealService)
- t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
- return setmetatable(t,FakeService_Metatable)
- end
- --Fake game object
- local FakeGame = {
- GetService = function(self,s)
- return rawget(self,s) or RealGame:GetService(s)
- end,
- Players = FakeService({
- LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
- },"Players"),
- UserInputService = FakeService(UIS,"UserInputService"),
- ContextActionService = FakeService(CAS,"ContextActionService"),
- RunService = FakeService({
- _btrs = {},
- RenderStepped = RealGame:GetService("RunService").Heartbeat,
- BindToRenderStep = function(self,name,_,fun)
- self._btrs[name] = self.Heartbeat:Connect(fun)
- end,
- UnbindFromRenderStep = function(self,name)
- self._btrs[name]:Disconnect()
- end,
- },"RunService")
- }
- rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
- FakeGame.service = FakeGame.GetService
- FakeService(FakeGame,game)
- --Changing owner to fake player object to support owner:GetMouse()
- game,owner = FakeGame,FakeGame.Players.LocalPlayer
- end
- --if i where u leaking that thing. il call the fbi.
- ---So dont leak this plssssss
- --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")
- Part3 = Instance.new("Part")
- Script4 = Instance.new("Script")
- Part5 = Instance.new("Part")
- Decal6 = Instance.new("Decal")
- Script7 = Instance.new("Script")
- Script8 = Instance.new("Script")
- Decal9 = Instance.new("Decal")
- Decal10 = Instance.new("Decal")
- Script11 = Instance.new("Script")
- Part12 = Instance.new("Part")
- Decal13 = Instance.new("Decal")
- Script14 = Instance.new("Script")
- Script15 = Instance.new("Script")
- Decal16 = Instance.new("Decal")
- Script17 = Instance.new("Script")
- Sound18 = Instance.new("Sound")
- DistortionSoundEffect19 = Instance.new("DistortionSoundEffect")
- Animation20 = Instance.new("Animation")
- LocalScript21 = Instance.new("LocalScript")
- Sound22 = Instance.new("Sound")
- DistortionSoundEffect23 = Instance.new("DistortionSoundEffect")
- Tool0.Name = "ban"
- Tool0.Parent = mas
- Tool0.TextureId = "http://www.roblox.com/asset/?id=10684453"
- Tool0.Grip = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Tool0.GripPos = Vector3.new(0, -1, 0)
- Part1.Name = "Handle"
- Part1.Parent = Tool0
- Part1.CFrame = CFrame.new(-6.13871098, 2.26852894, -11.4352541, -9.28728914e-05, -0.677499533, -0.735523343, 0.0380967073, 0.734986424, -0.677010179, 0.999273837, -0.0280841347, 0.0257421304)
- Part1.Orientation = Vector3.new(42.6100006, -88, 2.97000003)
- Part1.Position = Vector3.new(-6.13871098, 2.26852894, -11.4352541)
- Part1.Rotation = Vector3.new(87.8199997, -47.3499985, 90.0100021)
- Part1.Color = Color3.new(0.388235, 0.372549, 0.384314)
- Part1.Transparency = 345
- Part1.Size = Vector3.new(1, 5.20000029, 1)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.BrickColor = BrickColor.new("Dark stone grey")
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Part1.brickColor = BrickColor.new("Dark stone grey")
- Part1.FormFactor = Enum.FormFactor.Plate
- Part1.formFactor = Enum.FormFactor.Plate
- Script2.Name = "qPerfectionWeld"
- Script2.Parent = Part1
- table.insert(cors,sandbox(Script2,function()
- -- Created by Quenty (@Quenty, follow me on twitter).
- -- Should work with only ONE copy, seamlessly with weapons, trains, et cetera.
- -- Parts should be ANCHORED before use. It will, however, store relatives values and so when tools are reparented, it'll fix them.
- --[[ INSTRUCTIONS
- - Place in the model
- - Make sure model is anchored
- - That's it. It will weld the model and all children.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- THIS SCRIPT SHOULD BE USED ONLY BY ITSELF. THE MODEL SHOULD BE ANCHORED.
- 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.
- ]]
- --[[ DOCUMENTATION
- - 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.
- - Will work in PBS servers
- - Will work as long as it starts out with the part anchored
- - Stores the relative CFrame as a CFrame value
- - Takes careful measure to reduce lag by not having a joint set off or affected by the parts offset from origin
- - Utilizes a recursive algorith to find all parts in the model
- - Will reweld on script reparent if the script is initially parented to a tool.
- - Welds as fast as possible
- ]]
- -- qPerfectionWeld.lua
- -- Created 10/6/2014
- -- Author: Quenty
- -- Version 1.0.3
- -- Updated 10/14/2014 - Updated to 1.0.1
- --- Bug fix with existing ROBLOX welds ? Repro by asimo3089
- -- Updated 10/14/2014 - Updated to 1.0.2
- --- Fixed bug fix.
- -- Updated 10/14/2014 - Updated to 1.0.3
- --- Now handles joints semi-acceptably. May be rather hacky with some joints. :/
- 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).
- local function CallOnChildren(Instance, FunctionToCall)
- -- Calls a function on each of the children of a certain object, using recursion.
- FunctionToCall(Instance)
- for _, Child in next, Instance:GetChildren() do
- CallOnChildren(Child, FunctionToCall)
- end
- end
- local function GetNearestParent(Instance, ClassName)
- -- Returns the nearest parent of a certain class, or returns nil
- local Ancestor = Instance
- repeat
- Ancestor = Ancestor.Parent
- if Ancestor == nil then
- return nil
- end
- until Ancestor:IsA(ClassName)
- return Ancestor
- end
- local function GetBricks(StartInstance)
- local List = {}
- -- if StartInstance:IsA("BasePart") then
- -- List[#List+1] = StartInstance
- -- end
- CallOnChildren(StartInstance, function(Item)
- if Item:IsA("BasePart") then
- List[#List+1] = Item;
- end
- end)
- return List
- end
- local function Modify(Instance, Values)
- -- Modifies an Instance by using a table.
- assert(type(Values) == "table", "Values is not a table");
- for Index, Value in next, Values do
- if type(Index) == "number" then
- Value.Parent = Instance
- else
- Instance[Index] = Value
- end
- end
- return Instance
- end
- local function Make(ClassType, Properties)
- -- Using a syntax hack to create a nice way to Make new items.
- return Modify(Instance.new(ClassType), Properties)
- end
- local Surfaces = {"TopSurface", "BottomSurface", "LeftSurface", "RightSurface", "FrontSurface", "BackSurface"}
- local HingSurfaces = {"Hinge", "Motor", "SteppingMotor"}
- local function HasWheelJoint(Part)
- for _, SurfaceName in pairs(Surfaces) do
- for _, HingSurfaceName in pairs(HingSurfaces) do
- if Part[SurfaceName].Name == HingSurfaceName then
- return true
- end
- end
- end
- return false
- end
- local function ShouldBreakJoints(Part)
- --- We do not want to break joints of wheels/hinges. This takes the utmost care to not do this. There are
- -- definitely some edge cases.
- if NEVER_BREAK_JOINTS then
- return false
- end
- if HasWheelJoint(Part) then
- return false
- end
- local Connected = Part:GetConnectedParts()
- if #Connected == 1 then
- return false
- end
- for _, Item in pairs(Connected) do
- if HasWheelJoint(Item) then
- return false
- elseif not Item:IsDescendantOf(script.Parent) then
- return false
- end
- end
- return true
- end
- local function WeldTogether(Part0, Part1, JointType, WeldParent)
- --- Weld's 2 parts together
- -- @param Part0 The first part
- -- @param Part1 The second part (Dependent part most of the time).
- -- @param [JointType] The type of joint. Defaults to weld.
- -- @param [WeldParent] Parent of the weld, Defaults to Part0 (so GC is better).
- -- @return The weld created.
- JointType = JointType or "Weld"
- local RelativeValue = Part1:FindFirstChild("qRelativeCFrameWeldValue")
- local NewWeld = Part1:FindFirstChild("qCFrameWeldThingy") or Instance.new(JointType)
- Modify(NewWeld, {
- Name = "qCFrameWeldThingy";
- Part0 = Part0;
- Part1 = Part1;
- C0 = CFrame.new();--Part0.CFrame:inverse();
- C1 = RelativeValue and RelativeValue.Value or Part1.CFrame:toObjectSpace(Part0.CFrame); --Part1.CFrame:inverse() * Part0.CFrame;-- Part1.CFrame:inverse();
- Parent = Part1;
- })
- if not RelativeValue then
- RelativeValue = Make("CFrameValue", {
- Parent = Part1;
- Name = "qRelativeCFrameWeldValue";
- Archivable = true;
- Value = NewWeld.C1;
- })
- end
- return NewWeld
- end
- local function WeldParts(Parts, MainPart, JointType, DoNotUnanchor)
- -- @param Parts The Parts to weld. Should be anchored to prevent really horrible results.
- -- @param MainPart The part to weld the model to (can be in the model).
- -- @param [JointType] The type of joint. Defaults to weld.
- -- @parm DoNotUnanchor Boolean, if true, will not unachor the model after cmopletion.
- for _, Part in pairs(Parts) do
- if ShouldBreakJoints(Part) then
- Part:BreakJoints()
- end
- end
- for _, Part in pairs(Parts) do
- if Part ~= MainPart then
- WeldTogether(MainPart, Part, JointType, MainPart)
- end
- end
- if not DoNotUnanchor then
- for _, Part in pairs(Parts) do
- Part.Anchored = false
- end
- MainPart.Anchored = false
- end
- end
- local function PerfectionWeld()
- local Tool = GetNearestParent(script, "Tool")
- local Parts = GetBricks(script.Parent)
- 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]
- if PrimaryPart then
- WeldParts(Parts, PrimaryPart, "Weld", false)
- else
- warn("qWeld - Unable to weld part")
- end
- return Tool
- end
- local Tool = PerfectionWeld()
- if Tool and script.ClassName == "Script" then
- --- Don't bother with local scripts
- script.Parent.AncestryChanged:connect(function()
- PerfectionWeld()
- end)
- end
- -- Created by Quenty (@Quenty, follow me on twitter).
- end))
- Part3.Parent = Part1
- Part3.CFrame = CFrame.new(-6.4283433, 3.0345633, -11.1899986, 0.64278698, -0.766044974, 0, 0.766044974, 0.64278698, 0, 0, 0, 1)
- Part3.Orientation = Vector3.new(0, 0, 50)
- Part3.Position = Vector3.new(-6.4283433, 3.0345633, -11.1899986)
- Part3.Rotation = Vector3.new(0, 0, 50)
- Part3.Size = Vector3.new(0.919999838, 5.29000044, 0.700000048)
- Part3.BottomSurface = Enum.SurfaceType.Smooth
- Part3.CanCollide = false
- Part3.TopSurface = Enum.SurfaceType.Smooth
- Script4.Parent = Part3
- table.insert(cors,sandbox(Script4,function()
- while true do
- script.Parent.Color = Color3.new(math.random(), math.random(), math.random())
- wait(0.0)
- end
- end))
- Part5.Parent = Part1
- Part5.CFrame = CFrame.new(-9.61050034, 5.73734903, -11.3000069, 0.64278698, -0.766044974, 0, 0.766044974, 0.64278698, 0, 0, 0, 1)
- Part5.Orientation = Vector3.new(0, 0, 50)
- Part5.Position = Vector3.new(-9.61050034, 5.73734903, -11.3000069)
- Part5.Rotation = Vector3.new(0, 0, 50)
- Part5.Color = Color3.new(0.172549, 0.396078, 0.113725)
- Part5.Size = Vector3.new(6.70999813, 3.09999943, 2.35999703)
- Part5.BottomSurface = Enum.SurfaceType.Smooth
- Part5.BrickColor = BrickColor.new("Parsley green")
- Part5.CanCollide = false
- Part5.TopSurface = Enum.SurfaceType.Smooth
- Part5.brickColor = BrickColor.new("Parsley green")
- Decal6.Parent = Part5
- Decal6.Texture = "http://www.roblox.com/asset/?id=1092111742"
- Script7.Name = "Decal Changer"
- Script7.Parent = Decal6
- table.insert(cors,sandbox(Script7,function()
- --put this script inside the decal you want to change
- --to find the decal texture, insert the decal you want on a brick. Look into the brick and click the decal. Scroll Down and it says texture.
- --copy the url into the "insert texture here" spot
- while true do --Loop
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111447"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111742"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112007"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111742"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111447"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112712"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092113091"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112712"
- wait(0.14)
- end
- end))
- Script8.Parent = Part5
- table.insert(cors,sandbox(Script8,function()
- d=script.Parent.Decal
- while true do
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=13581260"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=16963225"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=14917794"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=6372899"
- wait(2)
- d.Texture="http://www.roblox.com/asset/?id=2013078"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=5853457"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=3403063"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=10724873"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=10217998"
- end
- end))
- Decal9.Parent = Part5
- Decal9.Texture = "http://www.roblox.com/asset/?id=16963225"
- Decal9.Face = Enum.NormalId.Left
- Decal10.Parent = Part5
- Decal10.Texture = "http://www.roblox.com/asset/?id=497226125"
- Decal10.Face = Enum.NormalId.Back
- Script11.Parent = Part5
- table.insert(cors,sandbox(Script11,function()
- while true do
- script.Parent.Color = Color3.new(math.random(), math.random(), math.random())
- wait(0.0)
- end
- end))
- Part12.Parent = Part1
- Part12.CFrame = CFrame.new(-11.2516012, 6.97079611, -11.310009, 0.64278698, -0.766044974, 0, 0.766044974, 0.64278698, 0, 0, 0, 1)
- Part12.Orientation = Vector3.new(0, 0, 50)
- Part12.Position = Vector3.new(-11.2516012, 6.97079611, -11.310009)
- Part12.Rotation = Vector3.new(0, 0, 50)
- Part12.Color = Color3.new(0.34902, 0.133333, 0.34902)
- Part12.Size = Vector3.new(0.989999652, 1, 2)
- Part12.BottomSurface = Enum.SurfaceType.Smooth
- Part12.BrickColor = BrickColor.new("Mulberry")
- Part12.CanCollide = false
- Part12.TopSurface = Enum.SurfaceType.Smooth
- Part12.brickColor = BrickColor.new("Mulberry")
- Decal13.Parent = Part12
- Decal13.Texture = "http://www.roblox.com/asset/?id=1092111742"
- Script14.Name = "Decal Changer"
- Script14.Parent = Decal13
- table.insert(cors,sandbox(Script14,function()
- --put this script inside the decal you want to change
- --to find the decal texture, insert the decal you want on a brick. Look into the brick and click the decal. Scroll Down and it says texture.
- --copy the url into the "insert texture here" spot
- while true do --Loop
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111447"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111742"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112007"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111742"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092111447"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112712"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092113091"
- wait(0.14)
- script.Parent.Texture = "http://www.roblox.com/asset/?id=1092112712"
- wait(0.14)
- end
- end))
- Script15.Parent = Part12
- table.insert(cors,sandbox(Script15,function()
- d=script.Parent.Decal
- while true do
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=13581260"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=16963225"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=14917794"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=6372899"
- wait(2)
- d.Texture="http://www.roblox.com/asset/?id=2013078"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=5853457"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=3403063"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=10724873"
- wait(0)
- d.Texture="http://www.roblox.com/asset/?id=10217998"
- end
- end))
- Decal16.Parent = Part12
- Decal16.Texture = "http://www.roblox.com/asset/?id=16963225"
- Decal16.Face = Enum.NormalId.Left
- Script17.Parent = Part12
- table.insert(cors,sandbox(Script17,function()
- while true do
- script.Parent.Color = Color3.new(math.random(), math.random(), math.random())
- wait(0.0)
- end
- end))
- Sound18.Name = "a"
- Sound18.Parent = Part1
- Sound18.Looped = true
- Sound18.Playing = true
- Sound18.SoundId = "rbxassetid://2794883088"
- Sound18.Volume = 4
- DistortionSoundEffect19.Parent = Sound18
- Animation20.Parent = Tool0
- Animation20.AnimationId = "http://www.roblox.com/twohandswordwithswingout-item?id=32659706"
- LocalScript21.Name = "main"
- LocalScript21.Parent = Tool0
- table.insert(cors,sandbox(LocalScript21,function()
- --Impletion [awful coding i know]
- wait()
- explode=false
- soundlock=false
- lock=false
- script.Parent.Activated:connect(function(click)
- if lock==false then
- lock=true
- local char=script.Parent.Parent
- local anim=char.Humanoid:LoadAnimation(script.Parent.Animation)
- anim:Play()
- wait(1.1)
- lock=false
- end
- end)
- script.Parent.Handle.Touched:connect(function(hit)
- local gethum=hit.Parent:GetChildren()
- for i=1,#gethum do
- if gethum[i].ClassName=="Humanoid" and gethum[i] ~= nil and hit.Parent.Name ~= game.Players.LocalPlayer.Name and lock==true then
- local hum=gethum[i]
- hum.Sit=true
- if soundlock==false then
- soundlock=true
- script.Parent.Smash:Play()
- end
- local character=hit.Parent
- local b=character:GetChildren()
- for i=1,#b do
- if b[i]:IsA("Part") and b[i] ~= nil then
- b[i].CanCollide=false
- b[i].Anchored=false
- end
- end
- local torso=hit.Parent:findFirstChild("Torso")
- character.Torso.Velocity=game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 1200
- character.Torso.Velocity=character.Torso.Velocity + Vector3.new(0,300,0)
- wait(1.2)
- if explode==false then
- explode=true
- local expl=Instance.new("Explosion", workspace)
- expl.BlastPressure=9000000
- expl.BlastRadius=100
- expl.Position=torso.Position
- character:BreakJoints()
- local p=game.Players:GetPlayerFromCharacter(character)
- character:Destroy()
- if p ~= nil then
- p:Destroy()
- end
- end
- end
- end
- wait(1)
- soundlock=false
- explode=false
- end)
- script.Parent.Equipped:connect(function(equip)
- game.Players.LocalPlayer.Character.Humanoid.MaxHealth=math.huge
- game.Players.LocalPlayer.Character.Humanoid.Health=math.huge
- game.Players.LocalPlayer.Character.Humanoid.WalkSpeed=60
- local Victim='xVortex_ray'
- local A=Instance.new'Animation'
- A.AnimationId='rbxassetid://33796059'
- local P=game:GetService'Players'.LocalPlayer
- local C=P.Character or P.CharacterAdded:Wait()
- local H=C:WaitForChild'Humanoid':LoadAnimation(A)
- H:Play()
- H:AdjustSpeed(1000000)
- while wait(0.1) do
- C:WaitForChild'HumanoidRootPart'.CFrame=CFrame.new(game:GetService'Players':FindFirstChild(Victim).Character:WaitForChild'HumanoidRootPart'.Position)
- end
- ---last script part
- end)
- plr = game.Players.LocalPlayer.Name
- meshes = {"Brick","Cylinder","Head","Sphere","Torso","Wedge"}
- h = game.Workspace[plr].Head.Mesh
- t = Instance.new("SpecialMesh",game.Workspace[plr].Torso)
- la = Instance.new("SpecialMesh",game.Workspace[plr]["Left Arm"])
- ra = Instance.new("SpecialMesh",game.Workspace[plr]["Right Arm"])
- ll = Instance.new("SpecialMesh",game.Workspace[plr]["Left Leg"])
- rl = Instance.new("SpecialMesh",game.Workspace[plr]["Right Leg"])
- while true do
- wait(0)
- h.MeshType = meshes[math.random(1,#meshes)]
- h.Parent.BrickColor = BrickColor.Random()
- t.MeshType = meshes[math.random(1,#meshes)]
- t.Parent.BrickColor = BrickColor.Random()
- la.MeshType = meshes[math.random(1,#meshes)]
- la.Parent.BrickColor = BrickColor.Random()
- ra.MeshType = meshes[math.random(1,#meshes)]
- ra.Parent.BrickColor = BrickColor.Random()
- ll.MeshType = meshes[math.random(1,#meshes)]
- ll.Parent.BrickColor = BrickColor.Random()
- rl.MeshType = meshes[math.random(1,#meshes)]
- rl.Parent.BrickColor = BrickColor.Random()
- end
- end))
- Sound22.Name = "Smash"
- Sound22.Parent = Tool0
- Sound22.Pitch = 0.80000001192093
- Sound22.PlaybackSpeed = 0.80000001192093
- Sound22.SoundId = "rbxassetid://147722910"
- Sound22.Volume = 1
- DistortionSoundEffect23.Parent = Sound22
- DistortionSoundEffect23.Level = 0.86000001430511
- 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