Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Functions = {}
- local Environment = Arsenic.Environment
- Functions.Local = {}
- Functions.Players = {}
- Functions.Server = {}
- Functions.Vehicles = {}
- Functions.Particles = {}
- Functions.Banishment = {}
- Functions.Weapons = {}
- Functions.Structures = {}
- Functions.Cloning = {}
- local Local = Functions.Local
- local Players = Functions.Players
- local Server = Functions.Server
- local Vehicles = Functions.Vehicles
- local Particles = Functions.Particles
- local Banishment = Functions.Banishment
- local Weapons = Functions.Weapons
- local Structures = Functions.Structures
- local Cloning = Functions.Cloning
- local function FindVest(player)
- for i,v in next, player.Character:GetDescendants() do
- if v.Name == 'thisisarmor' then
- return v.Parent
- end
- end
- end
- local function WaitAsync(condition)
- repeat wait() until condition
- end
- -- Local
- function Local.SetWalkSpeed(value)
- Arsenic.Globals.walkbase = value
- Arsenic.Client.Character.Humanoid.WalkSpeed = value
- end
- function Local.SetJumpPower(value)
- Arsenic.Client.Character.Humanoid.JumpPower = value
- end
- function Local.SetZoom(value)
- Arsenic.Client.CameraMaxZoomDistance = value
- end
- function Local.SetFog(value)
- game:GetService("Lighting").FogEnd = value
- end
- local LastSpectated
- function Local.Spectate(player)
- if LastSpectated then
- Arsenic.Data[LastSpectated.Name].Toggles.Spectate = false
- end
- Arsenic.Data[player.Name].Toggles.Spectate = true
- LastSpectated = player
- workspace.CurrentCamera.CameraSubject = player.Character.Humanoid
- end
- function Local.Glowstick(toggle)
- local Character = Arsenic.Client.playerstats.character
- local Skin = game:GetService('ReplicatedStorage').skins[Character.skin.Value]
- local OldSkin = Skin.Value
- local OldVest = Character.vestcolor.Value
- Arsenic.Loops.Glowstick = toggle
- Arsenic('VehichleLightsSet', Arsenic.Client.Character, 'Neon', 0)
- Arsenic.Globals.VehichleLightsSet(Arsenic.Client.Character, 'Neon', 0)
- if not toggle then
- Arsenic('VehichleLightsSet', Arsenic.Client.Character, 'SmoothPlastic', 0)
- Arsenic.Globals.VehichleLightsSet(Arsenic.Client.Character, 'SmoothPlastic', 0)
- return
- end
- while Arsenic.Loops.Glowstick and wait(1) do
- Arsenic('ChangeValue', Skin, BrickColor.random())
- Arsenic.Remote.CheckSkin:FireServer()
- Arsenic('ChangeValue', Skin, Old)
- Arsenic('ChangeValue', Character.vestcolor, math.random(1, 26))
- Arsenic.Remote.CheckVest:FireServer()
- end
- end
- function Local.Fly(toggle)
- Arsenic.Loops.Flying = toggle
- repeat wait()
- until Arsenic.Client and Arsenic.Client.Character and Arsenic.Client.Character:FindFirstChild("Torso") and Arsenic.Client.Character:findFirstChild("Humanoid")
- local mouse = Arsenic.Client:GetMouse()
- repeat wait() until mouse
- local plr = Arsenic.Client
- local torso = plr.Character.Torso
- local deb = true
- local ctrl = {f = 0, b = 0, l = 0, r = 0}
- local lastctrl = {f = 0, b = 0, l = 0, r = 0}
- local speed = 0
- local function Fly()
- local bg = Instance.new("BodyGyro", torso)
- bg.P = 9e4
- bg.maxTorque = Vector3.new(9e9, 9e9, 9e9)
- bg.cframe = torso.CFrame
- local bv = Instance.new("BodyVelocity", torso)
- bv.velocity = Vector3.new(0,0.1,0)
- bv.maxForce = Vector3.new(9e9, 9e9, 9e9)
- repeat wait()
- plr.Character.Humanoid.PlatformStand = true
- if ctrl.l + ctrl.r ~= 0 or ctrl.f + ctrl.b ~= 0 then
- speed = speed+.5+(speed/Arsenic.Variables.FlySpeed)
- if speed > Arsenic.Variables.FlySpeed then
- speed = Arsenic.Variables.FlySpeed
- end
- elseif not (ctrl.l + ctrl.r ~= 0 or ctrl.f + ctrl.b ~= 0) and speed ~= 0 then
- speed = speed-1
- if speed < 0 then
- speed = 0
- end
- end
- if (ctrl.l + ctrl.r) ~= 0 or (ctrl.f + ctrl.b) ~= 0 then
- bv.velocity = ((game.Workspace.CurrentCamera.CoordinateFrame.lookVector * (ctrl.f+ctrl.b)) + ((game.Workspace.CurrentCamera.CoordinateFrame * CFrame.new(ctrl.l+ctrl.r,(ctrl.f+ctrl.b)*.2,0).p) - game.Workspace.CurrentCamera.CoordinateFrame.p))*speed
- lastctrl = {f = ctrl.f, b = ctrl.b, l = ctrl.l, r = ctrl.r}
- elseif (ctrl.l + ctrl.r) == 0 and (ctrl.f + ctrl.b) == 0 and speed ~= 0 then
- bv.velocity = ((game.Workspace.CurrentCamera.CoordinateFrame.lookVector * (lastctrl.f+lastctrl.b)) + ((game.Workspace.CurrentCamera.CoordinateFrame * CFrame.new(lastctrl.l+lastctrl.r,(lastctrl.f+lastctrl.b)*.2,0).p) - game.Workspace.CurrentCamera.CoordinateFrame.p))*speed
- else
- bv.velocity = Vector3.new(0,0.1,0)
- end
- bg.cframe = game.Workspace.CurrentCamera.CoordinateFrame * CFrame.Angles(-math.rad((ctrl.f+ctrl.b)*50*speed/Arsenic.Variables.FlySpeed),0,0)
- until not Arsenic.Loops.Flying
- ctrl = {f = 0, b = 0, l = 0, r = 0}
- lastctrl = {f = 0, b = 0, l = 0, r = 0}
- speed = 0
- bg:Destroy()
- bv:Destroy()
- plr.Character.Humanoid.PlatformStand = false
- end
- mouse.KeyDown:connect(function(key)
- if key:lower() == "w" then
- ctrl.f = 1
- elseif key:lower() == "s" then
- ctrl.b = -1
- elseif key:lower() == "a" then
- ctrl.l = -1
- elseif key:lower() == "d" then
- ctrl.r = 1
- end
- end)
- mouse.KeyUp:connect(function(key)
- if key:lower() == "w" then
- ctrl.f = 0
- elseif key:lower() == "s" then
- ctrl.b = 0
- elseif key:lower() == "a" then
- ctrl.l = 0
- elseif key:lower() == "d" then
- ctrl.r = 0
- end
- end)
- Fly()
- end
- function Local.VS50Walk(toggle)
- Arsenic.Loops.VS50Walk = toggle
- while Arsenic.Loops.VS50Walk and wait() do
- Arsenic.Remote.PlaceMaterial:FireServer('VS50Placed', (Arsenic.Client.Character.HumanoidRootPart.Position - game:GetService( 'Lighting').Materials.VS50Placed.Head.Position) - Vector3.new(0, 2.9, 0), true)
- end
- end
- function Local.TM46Walk(toggle)
- Arsenic.Loops.TM46Walk = toggle
- while Arsenic.Loops.TM46Walk and wait() do
- Arsenic.Remote.PlaceMaterial:FireServer('TM46Placed', (Arsenic.Client.Character.HumanoidRootPart.Position - game:GetService( 'Lighting').Materials.TM46Placed.Head.Position) - Vector3.new(0, 2.9, 0), true)
- end
- end
- function Local.C4Walk(toggle)
- Arsenic.Loops.C4Walk = toggle
- while Arsenic.Loops.C4Walk and wait() do
- Arsenic.Remote.PlaceMaterial:FireServer('C4Placed', (Arsenic.Client.Character.HumanoidRootPart.Position - game:GetService('Lighting').Materials.C4Placed.Head.Position) - Vector3.new(0, 2.9, 0), true)
- end
- end
- function Local.Autoheal(toggle)
- if toggle then
- Arsenic.Events.Autoheal = Arsenic.Client.Character.Humanoid.Changed:Connect(function(p)
- if p == 'Health' then
- Arsenic('AddHealth', 100, 0)
- end
- end)
- else
- if Arsenic.Events.Autoheal then
- Arsenic.Events.Autoheal:Disconnect()
- end
- end
- end
- -- Players
- function Players.SetPlayers(player, value)
- Arsenic('ChangeValue', player.playerstats.PlayerKill.Aggressive, value)
- end
- function Players.SetZombies(player, value)
- Arsenic('ChangeValue', player.playerstats.ZombieKill.Military, value)
- end
- function Players.SetDays(player, value)
- Arsenic('ChangeValue', player.playerstats.Days, value)
- end
- function Players.SetHunger(player, value)
- Arsenic('ChangeValue', player.playerstats.Hunger, value)
- end
- function Players.SetThirst(player, value)
- Arsenic('ChangeValue', player.playerstats.Thirst, value)
- end
- function Players.SetStamina(player, value)
- Arsenic('ChangeValue', player.Backpack.GlobalFunctions.Stamina, value)
- end
- function Players.CombatLog(player, value)
- Arsenic('ChangeValue', player.playerstats.combat, value)
- end
- function Players.ShowVest(player, toggle)
- local Character = player.Character
- local Vest = FindVest(player)
- Arsenic('ChangeParent', Vest.thisisarmor, Character)
- Character:WaitForChild('thisisarmor')
- if not toggle then
- Arsenic('VehichleLightsSet', Vest, 'SmoothPlastic', 1)
- Arsenic('ChangeParent', Character:FindFirstChild('thisisarmor'), Vest)
- return
- end
- Arsenic('VehichleLightsSet', Vest, 'SmoothPlastic', 0)
- Arsenic('ChangeParent', Character:FindFirstChild('thisisarmor'), Vest)
- end
- function Players.ShowFace(player, toggle)
- local PlayerCharacter = player.Character
- if not toggle then
- Arsenic('ChangeParent', PlayerCharacter.Head.face, PlayerCharacter)
- return
- end
- Arsenic('ChangeParent', PlayerCharacter.face, PlayerCharacter.Head)
- end
- function Players.FaceSwap(player, target)
- local PlayerFace = player.Character.Head.face
- local TargetFace = target.Character.Head.face
- Arsenic('ChangeParent', PlayerFace, target.Character.Head)
- Arsenic('ChangeParent', TargetFace, player.Character.Head)
- end
- function Players.Material(player, value)
- local Character = player.Character
- local OldTransparency = Character.Head.Transparency
- Arsenic('VehichleLightsSet', Character, value, OldTransparency)
- Arsenic.Globals.VehichleLightsSet(Character, value, OldTransparency)
- end
- function Players.Visibility(player, value)
- local Character = player.Character
- local PlayerVest = FindVest(player)
- local OldMaterial = Character.Head.Material
- local VestCheck = PlayerVest.thisisarmor
- Arsenic('VehichleLightsSet', Character, OldMaterial, value)
- Arsenic.Globals.VehichleLightsSet(Character, OldMaterial, value)
- Arsenic('ChangeParent', VestCheck, Character)
- Arsenic('ChangeParent', VestCheck, PlayerVest)
- end
- function Players.Shirt(player, id)
- local ClientShirt = Arsenic.Client.playerstats.character.shirt.ObjectID.Shirt
- local OldClientValue = ClientShirt.Value
- Arsenic("ChangeValue", ClientShirt, id)
- Arsenic.Remote.CheckShirt:FireServer()
- wait(0.25)
- if player ~= Arsenic.Client then
- local ClientShirtObject = Arsenic.Client.Character.GameShirt
- local PlayerShirtObject = player.Character.GameShirt
- Arsenic("ChangeParent", ClientShirtObject, player.Character)
- Arsenic("ChangeParent", PlayerShirtObject, Arsenic.Client.Character)
- Arsenic("ChangeValue", player.playerstats.character.shirt.ObjectID.Shirt, ClientShirt.Value)
- Arsenic("ChangeValue", ClientShirt, OldClientValue)
- Arsenic.Remote.CheckShirt:FireServer()
- end
- end
- function Players.Pants(player, id)
- local ClientPants = Arsenic.Client.playerstats.character.pants.ObjectID.Pants
- local OldClientValue = ClientPants.Value
- Arsenic("ChangeValue", ClientPants, id)
- Arsenic.Remote.CheckPants:FireServer()
- wait(0.25)
- if player ~= Arsenic.Client then
- local ClientPantsObject = Arsenic.Client.Character.GamePants
- local PlayerPantsObject = player.Character.GamePants
- Arsenic("ChangeParent", ClientPantsObject, player.Character)
- Arsenic("ChangeParent", PlayerPantsObject, Arsenic.Client.Character)
- Arsenic("ChangeValue", player.playerstats.character.pants.ObjectID.Pants, ClientPants.Value)
- Arsenic("ChangeValue", ClientPants, OldClientValue)
- Arsenic.Remote.CheckPants:FireServer()
- end
- end
- function Players.Teleport(target, destination, location)
- local Stamina = target.Backpack.GlobalFunctions.Stamina
- local OldValue = Stamina.Value
- Arsenic('ChangeValue', Stamina, 0)
- Arsenic.Remote.HurtZombie:FireServer(target.Character, 15)
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', target.Character, '', '', '')
- Arsenic.Remote.AddClothing:FireServer('driven', target.Character, '', '', '')
- Arsenic.Remote.AddClothing:FireServer('SeatPoint', target.Character.Torso, '', '', '')
- target.Character:WaitForChild('IsBuildingMaterial')
- target.Character:WaitForChild('driven')
- target.Character.Torso:WaitForChild('SeatPoint')
- Arsenic.Remote.ReplicateModel:FireServer(target.Character, target.Character.Head.CFrame + Vector3.new(0, 50, 0))
- if location then
- Arsenic.Remote.ReplicateModel:FireServer(target.Character, destination.CFrame)
- else
- Arsenic.Remote.ReplicateModel:FireServer(target.Character, destination.Character.Head.CFrame)
- end
- wait(2)
- Arsenic('ChangeParent', target.Character.IsBuildingMaterial, nil)
- Arsenic('ChangeParent', target.Character.driven, nil)
- Arsenic('ChangeParent', target.Character.Torso.SeatPoint, nil)
- Arsenic('ChangeValue', Stamina, OldValue)
- end
- function Players.SetAdmin(player, toggle)
- Arsenic.Storage.Admins[player.Name] = toggle
- end
- function Players.SetMod(player, toggle)
- Arsenic.Storage.Mods[player.Name] = toggle
- end
- -- <ext>
- local ItemCache = (function()
- local Ret = {}
- for i,v in next, game:GetService('Lighting').LootDrops:GetChildren() do
- Ret[v.Name] = i
- end
- return Ret
- end)()
- -- Server
- function Server.LootRate(value)
- Arsenic.Remote.ChangeLootModifier:FireServer(value)
- end
- function Server.Spawn(player, loot, amount)
- local Lighting = game:GetService("Lighting")
- local LootDrops = Lighting.LootDrops
- local Spawn = loot.Name
- if Environment.Place == 'Mods' then
- Spawn = loot
- end
- local Position = player.Character.HumanoidRootPart.Position - loot.PrimaryPart.Position
- if amount > 30 then
- amount = 30
- end
- for i = 1, amount do
- Arsenic('ChangeParent', loot, Lighting.Materials)
- Arsenic.Remote.PlaceMaterial:FireServer(Spawn, Position + Vector3.new(math.random(-4, 4), 0, math.random(-4, 4)), false, false)
- Arsenic('ChangeParent', loot, LootDrops)
- end
- end
- function Server.ClearLoot()
- for i,v in next, workspace:GetChildren() do
- if ItemCache[v.Name] then
- Arsenic('ChangeParent', v, nil)
- end
- end
- end
- -- Banishment
- function Banishment.Kill(player)
- Arsenic('ChangeParent', player.Character.Head, nil)
- end
- function Banishment.Loopkill(player)
- Arsenic('ChangeParent', player.Character.Head, nil)
- Arsenic.Storage.Loopkill[player] = true
- end
- function Banishment.Unloopkill(player)
- end
- function Banishment.Trip(player)
- Arsenic.Remote.HurtZombie:FireServer(player.Character, 0)
- end
- function Banishment.Kick(player)
- Arsenic('ChangeParent', player, nil)
- end
- function Banishment.Ban(player)
- Arsenic.Storage.Bans[player.Name] = true
- Banishment.Kick(player)
- end
- function Banishment.Unban(player)
- Arsenic.Storage.Bans[player] = nil
- end
- function Banishment.Punish(player)
- Arsenic('ChangeParent', player.Character, game:GetService('ReplicatedStorage'))
- end
- function Banishment.Unpunish(player)
- Arsenic('ChangeParent', game:GetService('ReplicatedStorage'):FindFirstChild(player.Name, true), workspace)
- end
- function Banishment.Crash(player)
- Arsenic.Remote.AddClothing:FireServer('PermanentBan', player, '', '', '')
- end
- function Banishment.Explode(player)
- local Offset = player.Character.HumanoidRootPart.Position - game:GetService('Lighting').Materials.C4Placed.Head.Position
- for i = 1, 4 do
- Arsenic.Remote.PlaceMaterial:FireServer('C4Placed', Offset + Vector3.new(0, -2.9, 0), true)
- local C4Added, C4
- C4Added = workspace.ChildAdded:Connect(function(child)
- if child.Name == 'C4Placed' and child:WaitForChild('Owner').Value == Arsenic.Client.Name then
- C4 = child
- Arsenic.Remote.Detonate:FireServer(C4)
- C4Added:Disconnect()
- end
- end)
- repeat wait() until C4
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', C4, '', '', '')
- Arsenic.Remote.ReplicateModel:FireServer(C4, player.Character.Head.CFrame + CFrame.new(0, 1, 0).p)
- C4Added:Disconnect()
- end
- end
- function Banishment.SetHumanoid(player, toggle)
- if toggle then
- Arsenic('ChangeParent', player.Humanoid, player.Character)
- return
- end
- Arsenic('ChangeParent', player.Character.Humanoid, player)
- end
- -- Vehicles
- function Vehicles.Speed(vehicle, value)
- Arsenic('ChangeValue', vehicle.Stats.MaxSpeed, value)
- Arsenic('ChangeValue', vehicle.Stats.MaxSpeed.Offroad, value)
- end
- function Vehicles.God(vehicle)
- for i,v in next, vehicle.Stats:GetDescendants() do
- if not string.find(v.Name, 'd') then
- Arsenic('ChangeValue', v, 133742069)
- end
- end
- end
- function Vehicles.Explode(vehicle)
- Arsenic('ChangeValue', vehicle.Stats.Engine, 0)
- end
- function Vehicles.Teleport(player, vehicle)
- local Stamina = player.Backpack.GlobalFunctions.Stamina
- local OldValue = Stamina.Value
- Arsenic('ChangeValue', Stamina, 0)
- Arsenic.Remote.HurtZombie:FireServer(player.Character, 15)
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', player.Character, '', '', '')
- Arsenic.Remote.AddClothing:FireServer('driven', player.Character, '', '', '')
- Arsenic.Remote.AddClothing:FireServer('SeatPoint', player.Character.Torso, '', '', '')
- player.Character:WaitForChild('IsBuildingMaterial')
- player.Character:WaitForChild('driven')
- player.Character.Torso:WaitForChild('SeatPoint')
- Arsenic.Remote.ReplicateModel:FireServer(player.Character, player.Character.Head.CFrame + Vector3.new(0, 50, 0))
- Arsenic.Remote.ReplicateModel:FireServer(player.Character, vehicle.Essentials.Engine.CFrame + Vector3.new(10, 0, 10))
- wait(2)
- Arsenic('ChangeParent', player.Character.IsBuildingMaterial, nil)
- Arsenic('ChangeParent', player.Character.driven, nil)
- Arsenic('ChangeParent', player.Character.Torso.SeatPoint, nil)
- Arsenic('ChangeValue', Stamina, OldValue)
- end
- function Vehicles.Bring(vehicle, player)
- if not vehicle.PrimaryPart:FindFirstChild('IsBuildingMaterial', true) then
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', vehicle.PrimaryPart, '', '', '')
- end
- vehicle.PrimaryPart:WaitForChild('IsBuildingMaterial')
- Arsenic.Remote.ReplicatePart:FireServer(vehicle.PrimaryPart, Arsenic.Client.Character.HumanoidRootPart.CFrame + Vector3.new(math.random(-20, 20), 0, math.random(-20, 20)))
- end
- function Vehicles.Clone(vehicle, player)
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', vehicle, '', '', '')
- Arsenic('ChangeParent', vehicle, game:GetService('Lighting').Materials)
- local Vehicle = vehicle.Name
- if Environment.Place == 'Mods'then
- Vehicle = vehicle
- end
- workspace.Remote.PlaceMaterial:FireServer(Vehicle, (player.Character.HumanoidRootPart.Position - vehicle.Essentials.Base.Position) + Vector3.new(math.random(-20, 20), 0, math.random(-20, 20)), true)
- Arsenic('ChangeParent', vehicle.IsBuildingMaterial, nil)
- Arsenic('ChangeParent', vehicle, workspace.Vehicles)
- local Cloned = workspace:WaitForChild(vehicle.Name)
- for i,v in next, Cloned:GetDescendants() do
- if v.Name == 'SeatWeld' or v.Name == 'IsBuildingMaterial' then
- Arsenic('ChangeParent', v, nil)
- end
- end
- Arsenic('ChangeParent', Cloned, workspace.Vehicles)
- end
- function Vehicles.Material(vehicle, material)
- local OldParent = {}
- local Opacity = vehicle.Wheels.RBWheel.Wheel.Transparency
- for i,v in next, vehicle('GetDescendants') do
- if v:IsA('Model') then
- OldParent[v] = v.Parent
- Arsenic('ChangeParent', v, vehicle.Essentials)
- if v.Name ~= 'Rails' or v.Name ~= 'Icons' then
- Arsenic('VehichleLightsSet', v, material, Opacity)
- end
- end
- end
- wait(1)
- for i,v in next, OldParent do
- Arsenic('ChangeParent', i, v)
- end
- end
- function Vehicles.Opacity(vehicle, opacity)
- local OldParent = {}
- local Material = vehicle.Wheels.RBWheel.Wheel.Material
- for i,v in next, vehicle:GetDescendants() do
- if v:IsA('Model') then
- OldParent[v] = v.Parent
- Arsenic('ChangeParent', v, vehicle.Essentials)
- if v.Name ~= 'Rails' or v.Name ~= 'Icons' then
- Arsenic('VehichleLightsSet', v, Material, opacity)
- end
- end
- end
- wait(1)
- for i,v in next, OldParent do
- Arsenic('ChangeParent', i, v)
- end
- end
- function Vehicles.Break(vehicle)
- for i,v in next, vehicle('GetDescendants') do
- if v:IsA('Weld') then
- Arsenic('ChangeParent', v, nil)
- end
- end
- end
- function Vehicles.Remove(vehicle)
- if vehicle.Parent == workspace.Vehicles then
- Arsenic('ChangeParent', vehicle, game:GetService('ReplicatedStorage').Transfer)
- end
- end
- function Vehicles.Replenish(vehicle)
- if vehicle.Parent == game:GetService('ReplicatedStorage').Transfer then
- Arsenic('ChangeParent', vehicle, workspace.Vehicles)
- end
- end
- -- Particles
- function Particles.Sparkles(player)
- local Materials = game:GetService('Lighting').Materials
- local Tip = Materials.RoadFlareLit.Tip
- local Sparkles = Tip:WaitForChild('Sparkles')
- Arsenic('ChangeParent', Sparkles, Materials.VS50Placed)
- Materials.VS50Placed:WaitForChild('Sparkles')
- Arsenic.Remote.PlaceMaterial:FireServer((function()
- if Environment.Place == 'Mods' then
- return game:GetService('Lighting').Materials.VS50Placed
- end
- return game:GetService('Lighting').Materials.VS50Placed.Name
- end)(), Vector3.new(9e9, 9e9, 9e9), true)
- Arsenic('ChangeParent', Materials.VS50Placed:WaitForChild('Sparkles'), Tip)
- for i,v in next, workspace:GetChildren() do
- if v.Name == 'VS50Placed' and v:FindFirstChild('Sparkles', true)then
- Arsenic('ChangeParent', v.Sparkles, player.Character.Torso)
- Arsenic('ChangeParent', v, nil)
- end
- end
- end
- function Particles.Fire(player)
- local Materials = game:GetService('Lighting').Materials
- local Thing = Materials.Fireplace.Thing
- local FireEffect = Thing:WaitForChild('FireEffect')
- Arsenic.Remote.SwitchEnabled:FireServer(true, FireEffect)
- Arsenic('ChangeParent', FireEffect, Materials.VS50Placed)
- Arsenic.Remote.PlaceMaterial:FireServer((function()
- if Environment.Place == 'Mods' then
- return Lighting.Materials.VS50Placed
- end
- return Lighting.Materials.VS50Placed.Name
- end)(), Vector3.new(9e9, 9e9, 9e9), true)
- Arsenic('ChangeParent', Materials.VS50Placed:WaitForChild('FireEffect'), Thing)
- for i,v in next, workspace:GetChildren() do
- if v.Name == 'VS50Placed' and v:FindFirstChild('FireEffect', true)then
- Arsenic('ChangeParent', v.FireEffect, player.Character.Torso)
- Arsenic('ChangeParent', v, nil)
- end
- end
- Arsenic.Remote.SwitchEnabled:FireServer(false, FireEffect)
- end
- function Particles.Smoke(player)
- local Lighting = game:GetService("Lighting")
- local Materials = Lighting.Materials
- local BuildingSmoke = Lighting:WaitForChild('BuildingSmoke')
- Arsenic('ChangeParent', BuildingSmoke, Materials.VS50Placed)
- Arsenic.Remote.PlaceMaterial:FireServer((function()
- if Environment.Place == 'Mods' then
- return Lighting.Materials.VS50Placed
- end
- return Lighting.Materials.VS50Placed.Name
- end)(), Vector3.new(9e9, 9e9, 9e9), true)
- wait(1)
- Arsenic('ChangeParent', Materials.VS50Placed:WaitForChild('BuildingSmoke'), Lighting)
- for i,v in next, workspace:GetChildren() do
- if v.Name == 'VS50Placed' and v:FindFirstChild('BuildingSmoke', true)then
- Arsenic('ChangeParent', v.BuildingSmoke.SmokeRemoval, nil)
- Arsenic('ChangeParent', v.BuildingSmoke, player.Character.Torso)
- Arsenic('ChangeParent', v, nil)
- end
- end
- end
- function Particles.Remove(player, particle)
- for i,v in next, player.Character.Torso:GetChildren() do
- if v.Name == particle then
- Arsenic('ChangeParent', v, nil)
- end
- end
- end
- -- Weapons
- function Weapons.SetSpread(weapon, amount)
- Environment.SetUpvalue(getsenv(weapon.Shooter).Fire, 'a', amount)
- end
- function Weapons.FireRate(weapon, amount)
- getsenv(weapon.Shooter).rato = amount
- weapon.Stats.Action.Original.Value = 3
- end
- function Weapons.SetRecoil(player, weapon, amount)
- Arsenic('ChangeValue', player.Backpack[weapon.Name].Stats.Recoil, Arsenic.Globals.Obfuscate(amount))
- end
- function Weapons.SetAmmo(player, amount)
- for i,v in next, player.playerstats.slots:GetDescendants() do
- if v.Name == 'Clip' then
- Arsenic('ChangeValue', v.MaxClip, amount)
- Arsenic('ChangeValue', v, Arsenic.Globals.Obfuscate(amount))
- end
- end
- end
- function Weapons.RefillAmmo(player)
- for i,v in next, player.playerstats.slots('GetDescendants') do
- if v.Name == 'Clip' then
- Arsenic('ChangeValue', v, Arsenic.Globals.Obfuscate(v.MaxClip.Value))
- end
- end
- end
- -- Structures
- local TrussInstance = (function()
- local Lighting = game:GetService('Lighting')
- if Environment.Place == 'Mods' then
- if not Lighting:FindFirstChild('Materials') then
- return Lighting.materials.Material7.Collect7
- end
- return Lighting.Materials.MetalTruss
- end
- return 'MetalTruss'
- end)()
- if not game:GetService("ReplicatedStorage"):FindFirstChild('Arsenic_Trusses', true) then
- Arsenic.Remote.AddClothing:FireServer('Arsenic_Trusses', game:GetService('ReplicatedStorage'), '', '','')
- for i = 1, 90 do
- Arsenic.Remote.PlaceMaterial:FireServer(TrussInstance, Vector3.new(9e9, 9e9, 9e9), false, true)
- wait()
- end
- end
- local BuildingParts = {
- Truss = {Size = Vector3.new(2, 8, 2)}
- }
- local function LoadTrusses()
- for i,v in next, workspace:GetChildren() do
- if v:IsA('TrussPart') and v:FindFirstChild('IsBuildingMaterial', true) then
- for k,x in next, BuildingParts do
- if x.Size == v.Size then
- x[v] = true
- end
- end
- end
- end
- end
- function Structures.Truss(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(idx * x, idx * y, idx * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- function Structures.TrussRX(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(math.rad(idx) * x, idx * y, idx * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- function Structures.TrussRY(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(idx * x, math.rad(idx) * y, idx * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- function Structures.TrussRZ(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(idx * x, idx * y, math.rad(idx) * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- function Structures.TrussRXY(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(math.rad(idx) * x, math.rad(idx) * y, idx * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- function Structures.TrussRXZ(player, x, y, z, diameter)
- LoadTrusses()
- local idx = 0
- for i,v in next, BuildingParts.Truss do
- if idx == 360 then break end
- Arsenic.Remote.ReplicatePart:FireServer(i, player.Character.HumanoidRootPart.CFrame * CFrame.Angles(math.rad(idx) * x, idx * y, math.rad(idx) * z) * CFrame.new(0, 0, diameter))
- idx = idx + 1
- end
- end
- -- Cloning
- function Cloning.Clone(player, city)
- local tc = workspace['Anchored Objects']['Towns/Cities']
- city = tc:FindFirstChild(city.Name)
- local function findpart()
- for i,v in next, city:GetDescendants() do
- if v:IsA('BasePart') then
- return v
- end
- end
- end
- Arsenic.Remote.AddClothing:FireServer('IsBuildingMaterial', city, '', '', '')
- repeat wait() until city:FindFirstChild('IsBuildingMaterial')
- Arsenic('ChangeParent', city, game:GetService('Lighting').Materials)
- Arsenic.Remote.PlaceMaterial:FireServer(city.Name, player.Character.HumanoidRootPart.Position - findpart(city).Position, false)
- Arsenic('ChangeParent', city, tc)
- Arsenic('ChangeParent', city.IsBuildingMaterial, nil)
- end
- return Functions
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement