-- LocalScript ClientWeaponSystem (via decompile) local ContextActionService_1 = game:GetService("ContextActionService") local ReplicatedStorage_1 = game:GetService("ReplicatedStorage") local CollectionService_1 = game:GetService("CollectionService") local UserInputService_1 = game:GetService("UserInputService") local ContentProvider_1 = game:GetService("ContentProvider") local SoundService_1 = game:GetService("SoundService") local RunService_1 = game:GetService("RunService") local GuiService_upv_1 = game:GetService("GuiService") local Players_1 = game:GetService("Players") local Debris_1 = game:GetService("Debris") local v1 = Color3.new(1, 1, 1) local LocalPlayer_upv_1 = Players_1.LocalPlayer local PlayerGui_1 = LocalPlayer_upv_1.PlayerGui local v2 = LocalPlayer_upv_1.Character or (LocalPlayer_upv_1.CharacterAdded:Wait()) local Humanoid_1 = v2:WaitForChild("Humanoid") local CurrentCamera_upv_1 = workspace.CurrentCamera local Server_upv_1 = ReplicatedStorage_1.Server local GameEvents_1 = ReplicatedStorage_1:WaitForChild("GameEvents") script:SetAttribute("Lean", script:GetAttribute("Lean") or 0) script:SetAttribute("Movement", script:GetAttribute("Movement") or "Standing") script:SetAttribute("ThrowablePreviewActive", false) script:SetAttribute("ThrowablePreviewToolName", "") script:SetAttribute("SwapInProgress", false) script:SetAttribute("WeaponPresentationReady", false) script:SetAttribute("WeaponFullyReady", false) script:SetAttribute("WeaponReady", false) script:SetAttribute("InitialEquipReady", false) local Modules_1 = script:WaitForChild("Modules") local Keybinds_1 = require(ReplicatedStorage_1:WaitForChild("Modules"):WaitForChild("Keybinds")) local CameraSensitivity_1 = require(ReplicatedStorage_1:WaitForChild("Modules"):WaitForChild("CameraSensitivity")) local v3 = Keybinds_1.updateKeybinds() CameraSensitivity_1:AdjustSensitivity(v3.CameraSensitivity) local tbl_upv_1 = {} tbl_upv_1.Constants = {FP_SPECTATE_CAMERA_ATTRIBUTE = "FirstPersonSpectateActive", WHITE = v1} tbl_upv_1.Services = {ContextActionService = ContextActionService_1, ReplicatedStorage = ReplicatedStorage_1, CollectionService = CollectionService_1, UserInputService = UserInputService_1, ContentProvider = ContentProvider_1, SoundService = SoundService_1, RunService = RunService_1, GuiService = GuiService_upv_1, Players = Players_1, Debris = Debris_1} tbl_upv_1.Refs = {Player = LocalPlayer_upv_1, PlayerGui = PlayerGui_1, Character = v2, Humanoid = Humanoid_1, Camera = CurrentCamera_upv_1, Script = script, ServerFolder = Server_upv_1, TournamentFolder = Server_upv_1.Tournament, GameEvents = GameEvents_1} tbl_upv_1.Modules = { Types = require(ReplicatedStorage_1.Modules.TypeModules.Types), Components = require(ReplicatedStorage_1:WaitForChild("ComponentsManager")), SetupMod = require(ReplicatedStorage_1.Components.SetupModule), Config = require(ReplicatedStorage_1:WaitForChild("Config")), CShakeModule = require(ReplicatedStorage_1.Components.CameraShaker), GameMenu = require(ReplicatedStorage_1.Components.GameMenu), WeaponComponent = require(script:WaitForChild("Components"):WaitForChild("Weapon")), Throwable = require(ReplicatedStorage_1.Components.Throwable), HelperFunctions = require(Modules_1:WaitForChild("HelperFunctions")), Constants = require(ReplicatedStorage_1:WaitForChild("Modules"):WaitForChild("Constants")), Utility = require(ReplicatedStorage_1.Modules.Utility), WeaponSlotResolver = require(ReplicatedStorage_1.Modules.WeaponSlotResolver), GameModes = require(ReplicatedStorage_1.Modules.GameModes), CameraSens = CameraSensitivity_1, KeybindsModule = Keybinds_1 } tbl_upv_1.State = {} tbl_upv_1.API = {} local PlayerData_1 = LocalPlayer_upv_1:WaitForChild("PlayerData") local Settings_1 = PlayerData_1:WaitForChild("Settings") tbl_upv_1.State.ClientData = { Recoil = CFrame.new(), Ray_Ignore = {v2, CurrentCamera_upv_1}, GameHUD = PlayerGui_1.GameHUD, PlayerHUD = PlayerGui_1.GameHUD.PlayerHUD, CameraY = 0, CameraLast = CurrentCamera_upv_1.CFrame, MobileControlsMenu = script:WaitForChild("Prefabs"):WaitForChild("MobileControlsMenu"), LastInputType = nil, PlayersMovementSyncData = {}, MouseHeld = nil, RunningHold = nil, CrouchingHold = nil, CrouchingHoldTimer = nil, ForwardMovement = nil, AimingToggleOff = nil, ADSInputHeld = false, EnemyBarrier = nil, EnemyColor = nil, TeamBarrier = nil, TeamColor = nil, ThumbstickStart = nil, ThumbstickEnd = nil, JoystickTouch = nil, JoystickTouchPosition = nil, MobileMovementVector = Vector2.zero, JoystickBaseCenter = nil, JoystickBaseRadius = nil, JoystickSprint = false, ShootTouch = nil, ShootStaticTouch = nil, TouchMovementControlsDisabled = false, TouchMovementControls = nil, ScopeAiming = 0, ProneCooldown = false, PlayerHUDVisibilityConfigured = false, MobileControlsVisibilityConfigured = false } tbl_upv_1.State.PlayerData = PlayerData_1 tbl_upv_1.State.PlayerSettings = Settings_1 tbl_upv_1.State.Keybinds = v3 tbl_upv_1.State.ADSToggle = v3.ADSToggle tbl_upv_1.State.LeanToggle = v3.LeanToggle tbl_upv_1.State.Ping = {CanPing = true, Cooldown = 0.1, MaxDistance = 500} tbl_upv_1.State.Presentation = {InitialEquipRetryInProgress = false, InitialWeaponEquipVisualized = false, InitialWeaponEquipCompleted = false} tbl_upv_1.State.WeaponAction = {ThrowableRecoveryActive = false, SwapFinalizing = false, QuickThrowPreviousWeaponIndex = 0, QuickThrowHoldActive = false, SwapGeneration = 0, ADSUnlockAt = 0, LastNonThrowableWeaponIndex = 1, BufferedADSSwapGeneration = 0, BufferedADSIntent = false} tbl_upv_1.State.Movement = {WasActivelyMoving = false, PendingSprintExitActive = false, PrevMovementState = "", IsMoving = false, PrevMoving = false, MovementStartTweenDuration = 0.75, PendingSprintExitResumeAt = 0, LastAppliedWalkState = script:GetAttribute("Movement") or "Standing"} tbl_upv_1.State.Runtime = { CameraShake = nil, BobbleDebounce = false, ScopeSwaySin = 0, ScopeSwayCos = 0, ArmSin = 0, ArmSin2 = 0, ArmLerp = 0, ArmZ = 0, NextLeanAngle = 0, NextLeanDirection = 0, AdditionalRotation = 0, PreviousRotation = 0, PreviousCharacterCFrame = CFrame.new(0, 0, 0), PreviousSpectateCameraCFrame = CFrame.new(0, 0, 0), CharacterCFrameDistance = 0.08, CharacterCFrameAngleDifference = 1.25, RemoteMovementBufferDelay = 0.1, RemoteMovementMaxExtrapolation = 0.15, RemoteMovementBlendAlpha = 0.18, RemoteMovementWarpDistance = 6, RemoteMovementStaleAfter = 1, LastLookRotationSend = 0, LastSpectateCameraSend = 0, LookRotationRate = 0.03333333333333333, SpectateCameraLookRotationRate = 0.02, ReplaySpectateCameraRate = 0.02, PreviousLaserTarget = nil, PreviousLaserActive = false, LaserTargetSendThreshold = 0.15, LaserSampleDistance = 500, SampledLaserTarget = nil, ActiveLocalLaserWeaponModel = nil, LastHeldShoulderRotation = nil, LastMapZoneCheck = 0, MapZoneCheckRate = 0.15, SwayRotation = CFrame.new(), SwayAxis = {Y = 0, X = 0, XSpringVal = 0, Z = 0, MovementX = 0, YSpringVal = 0, MovementZ = 0}, SwayAngle = 20, SwaySpeed = 5, rotX = 0, rotY = 0, ConsoleRotX = 0, ConsoleRotY = 0, StickIsCenter = true, InZone = true } tbl_upv_1.State.Character = {RoundEndCleanupTriggered = false, PreviousHealth = Humanoid_1.Health} tbl_upv_1.State.Helpers = {} function tbl_upv_1.State.Helpers.IsFirstPersonSpectateCameraActive() --[[ name: IsFirstPersonSpectateCameraActive line: 226 upvalues: CurrentCamera_upv_1 (copy, index: 1) ]] local v4 = CurrentCamera_upv_1:GetAttribute("FirstPersonSpectateActive") == true return v4 end function tbl_upv_1.State.Helpers.ResolveCurrentSpectateMode() --[[ name: ResolveCurrentSpectateMode line: 230 upvalues: Server_upv_1 (copy, index: 1) tbl_upv_1 (copy, index: 2) ]] local v5 = Server_upv_1:GetAttribute("GameMode") local v6 = (v5 == "Custom") and (Server_upv_1:GetAttribute("SpectateFirstPerson") == true) return tbl_upv_1.Modules.GameModes.ResolveSpectateMode(v5, v6) end tbl_upv_1.State.Helpers.ShouldReceiveFirstPersonSpectateSync = function() --[[ line: 239 upvalues: Server_upv_1 (copy, index: 1) tbl_upv_1 (copy, index: 2) ]] local v7 = Server_upv_1:GetAttribute("GameMode") local v8 = (v7 == "Custom") and (Server_upv_1:GetAttribute("SpectateFirstPerson") == true) local v9 if tbl_upv_1.Modules.GameModes.ResolveSpectateMode(v7, v8) == tbl_upv_1.Modules.GameModes.SpectateModes.FirstPerson then v9 = true else v9 = false end return v9 end tbl_upv_1.State.Helpers.HasFirstPersonSpectators = function() --[[ line: 242 upvalues: LocalPlayer_upv_1 (copy, index: 1) ]] local ServerData_1 = LocalPlayer_upv_1:FindFirstChild("ServerData") local v10 = (ServerData_1 ~= nil) and (ServerData_1:GetAttribute("HasFirstPersonSpectators") == true) return v10 end tbl_upv_1.State.Helpers.getGuiInset = function() --[[ line: 246 upvalues: GuiService_upv_1 (copy, index: 1) ]] return -(GuiService_upv_1:GetGuiInset().Y / 2) end tbl_upv_1.State.WeaponDataNew = tbl_upv_1.Modules.WeaponComponent.new(LocalPlayer_upv_1) tbl_upv_1.State.Runtime.CameraShake = tbl_upv_1.Modules.CShakeModule.new( Enum.RenderPriority.Camera.Value, function(a1) --[[ line: 252 upvalues: CurrentCamera_upv_1 (copy, index: 1) ]] local v11 = CurrentCamera_upv_1:GetAttribute("FirstPersonSpectateActive") == true if v11 == true then return end CurrentCamera_upv_1.CFrame = CurrentCamera_upv_1.CFrame * a1 end ) tbl_upv_1.State.Runtime.CameraShake:Start() local PresentationController_1 = require(Modules_1:WaitForChild("PresentationController")) local MovementController_1 = require(Modules_1:WaitForChild("MovementController")) local WeaponActionController_1 = require(Modules_1:WaitForChild("WeaponActionController")) local InputController_1 = require(Modules_1:WaitForChild("InputController")) local RuntimeController_1 = require(Modules_1:WaitForChild("RuntimeController")) local CharacterController_1 = require(Modules_1:WaitForChild("CharacterController")) tbl_upv_1.API.Presentation = PresentationController_1.init(tbl_upv_1) tbl_upv_1.API.Movement = MovementController_1.init(tbl_upv_1) tbl_upv_1.API.WeaponAction = WeaponActionController_1.init(tbl_upv_1) tbl_upv_1.API.Input = InputController_1.init(tbl_upv_1) tbl_upv_1.API.Runtime = RuntimeController_1.init(tbl_upv_1) tbl_upv_1.API.Character = CharacterController_1.init(tbl_upv_1)