Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Decompiled with the Synapse X Luau decompiler.
- local v1 = {};
- local v2 = require(script.Parent.VisualModule);
- local v3 = require(script.Parent.PlayerDataClient);
- local v4 = require(script.Parent.CategoryModule);
- local v5 = require(game.ReplicatedStorage.Modules.ShortNumber);
- local l__LocalPlayer__6 = game.Players.LocalPlayer;
- local l__UserInputService__7 = game:GetService("UserInputService");
- local l__Debris__8 = game:GetService("Debris");
- local l__Parent__9 = script.Parent.Parent;
- local v10 = require(script.Parent.SettingsModule);
- local l__Frames__11 = l__Parent__9:WaitForChild("Category"):WaitForChild("Frames");
- l__Frames__11:WaitForChild("Stats");
- local l__Backpack__12 = l__LocalPlayer__6.Backpack;
- v1.Loaded = false;
- v1.SelectedKey = nil;
- v1.Cooldown = false;
- v1.Sword = nil;
- v1.DefaultColor = Color3.fromRGB(255, 255, 255);
- v1.SelectedColor = Color3.fromRGB(157, 157, 157);
- v1.StatKeys = {
- ["1"] = "Strength",
- ["2"] = "Durability",
- ["3"] = "Chakra",
- ["4"] = "Sword",
- ["5"] = "Agility"
- };
- v1.AnimationTable = {};
- local u1 = false;
- local l__Events__2 = game.ReplicatedStorage.Events;
- local u3 = nil;
- local u4 = false;
- function v1.SelectKey(p1)
- if u1 == true then
- return;
- end;
- u1 = true;
- spawn(function()
- wait(0.2);
- u1 = false;
- end);
- if v1.Loaded == true then
- if v1.SelectedKey == nil then
- v1.SelectedKey = p1;
- v1.SelectedKey.ImageColor3 = v1.SelectedColor;
- else
- if v1.SelectedKey.Name == "4" then
- l__Events__2.GeneralEvent:FireServer("SE", false);
- end;
- if v1.SelectedKey == p1 then
- v1.SelectedKey.ImageColor3 = v1.DefaultColor;
- v1.SelectedKey = nil;
- elseif v1.SelectedKey ~= p1 then
- v1.SelectedKey.ImageColor3 = v1.DefaultColor;
- v1.SelectedKey = p1;
- v1.SelectedKey.ImageColor3 = v1.SelectedColor;
- end;
- end;
- for v13, v14 in pairs(v1.AnimationTable) do
- if v14.Name == "Pushup1" or v14.Name == "Chakra" or v14.Name == "SwordIdle" then
- v14:Stop();
- end;
- end;
- l__LocalPlayer__6.Character.Humanoid.WalkSpeed = v10.Speed;
- l__LocalPlayer__6.Character.Humanoid.JumpPower = v10.Jump;
- l__LocalPlayer__6.Character.Humanoid:UnequipTools();
- v1.Sword = nil;
- if v1.SelectedKey then
- if v1.SelectedKey.Name == "2" or v1.SelectedKey.Name == "3" then
- l__LocalPlayer__6.Character.Humanoid.WalkSpeed = 0;
- l__LocalPlayer__6.Character.Humanoid.JumpPower = 0;
- if v1.SelectedKey.Name == "2" then
- v1.AnimationTable.Pushup1:Play();
- return;
- end;
- if v1.SelectedKey.Name == "3" then
- v1.AnimationTable.Chakra:Play();
- spawn(function()
- while v1.SelectedKey and v1.SelectedKey.Name == "3" do
- wait(1.01);
- if not v1.SelectedKey then
- break;
- end;
- if v1.SelectedKey.Name ~= "3" then
- break;
- end;
- v1.ActivateKey();
- end;
- end);
- return;
- end;
- elseif v1.SelectedKey.Name == "4" then
- l__Events__2.GeneralEvent:FireServer("SE", true);
- v1.Sword = l__LocalPlayer__6.Character.SWORD;
- v1.AnimationTable.SwordIdle:Play();
- u3 = v1.Sword.HitPart.Touched:Connect(function(p2)
- if u4 and (p2.Parent ~= l__LocalPlayer__6.Character or p2.Parent.Parent ~= l__LocalPlayer__6.Character) then
- local v15 = p2.Parent:FindFirstChild("Humanoid") or p2.Parent.Parent:FindFirstChild("Humanoid");
- if v15 and v15.Health > 0 then
- u4 = false;
- l__Events__2.GeneralEvent:FireServer("HE", v15);
- v15.Parent.PrimaryPart.HitParticle:Emit(1);
- v2.ShakeCamera(1);
- end;
- end;
- end);
- end;
- end;
- end;
- end;
- function v1.RemoveKey()
- if v1.SelectedKey then
- v1.SelectedKey.ImageColor3 = v1.DefaultColor;
- v1.SelectedKey = nil;
- end;
- l__LocalPlayer__6.Character.Humanoid.WalkSpeed = v10.Speed;
- l__LocalPlayer__6.Character.Humanoid.JumpPower = v10.Jump;
- l__LocalPlayer__6.Character.Humanoid:UnequipTools();
- v1.Sword = nil;
- for v16, v17 in pairs(v1.AnimationTable) do
- if v17.Name == "Pushup1" or v17.Name == "Chakra" or v17.Name == "SwordIdle" then
- v17:Stop();
- end;
- end;
- end;
- function v1.SendToServer(p3)
- if v1.Loaded == true and l__LocalPlayer__6.Character.Humanoid.Health > 0 then
- local v18 = l__Events__2.StatFunction:InvokeServer("Stat", p3);
- if v18 ~= nil then
- v1.SuccessReturned(p3, v18);
- end;
- end;
- end;
- function v1.SuccessReturned(p4, p5)
- l__Frames__11.Stats.Container.Stats[p4].Current.Stat.Text = v5.abr(p5[1]);
- v3.Data.Stats[p4][1] = p5[1];
- local v19 = script.Example:Clone();
- v19.ImageLabel.Image = v4.GUIAspect[p4].Image;
- v19.TextLabel.Text = "+" .. v5.abr(p5[2]) .. " " .. v4.GUIAspect[p4].Text;
- v19.TextLabel.TextColor3 = v4.GUIAspect[p4].Color;
- v19.Parent = l__Parent__9;
- l__Debris__8:AddItem(v19, 1);
- v19.Position = UDim2.new(math.random(3, 7) / 10, 0, math.random(5, 7) / 10, 0);
- v19:TweenSize(UDim2.new(0.4, 0, 0.2, 0), "Out", Enum.EasingStyle.Elastic, 0.3, true);
- end;
- function v1.ActivateKey()
- if v1.Loaded == true and v1.SelectedKey and v1.StatKeys[v1.SelectedKey.Name] and v1.Cooldown == false then
- v1.Cooldown = true;
- if v1.SelectedKey.Name == "2" then
- v1.AnimationTable.Pushup2:Play();
- end;
- v1.SendToServer(v1.StatKeys[v1.SelectedKey.Name]);
- wait(1);
- v1.Cooldown = false;
- end;
- end;
- function v1.Speed()
- if l__LocalPlayer__6.Character.Humanoid.WalkSpeed > 0 then
- v1.SendToServer("Speed");
- end;
- end;
- function v1.LoadAnimations(p6)
- v1.AnimationTable = p6;
- v1.Loaded = true;
- end;
- for v20, v21 in pairs(l__Parent__9:WaitForChild("Hotkeys"):GetChildren()) do
- v21.MouseButton1Click:Connect(function()
- v1.SelectKey(v21);
- end);
- end;
- local u5 = false;
- local u6 = false;
- local u7 = false;
- local function u8()
- if v1.SelectedKey and v1.SelectedKey.Name ~= "3" then
- if v1.SelectedKey.Name == "4" then
- if v1.Sword then
- spawn(function()
- if not u5 and l__LocalPlayer__6.Character and l__LocalPlayer__6.Character.Humanoid.Health > 0 then
- u5 = true;
- ({ v1.AnimationTable.Swing1, v1.AnimationTable.Swing2 })[math.random(1, 2)]:Play();
- v1.Sword.HitPart.Swing:Play();
- u4 = true;
- wait(1);
- u4 = false;
- u5 = false;
- end;
- end);
- end;
- elseif v1.SelectedKey.Name == "1" then
- spawn(function()
- if not u6 then
- u6 = true;
- local v22 = {};
- if not l__LocalPlayer__6.Character:FindFirstChild("TITANLIMB") then
- local v23 = { l__LocalPlayer__6.Character.LeftHand, l__LocalPlayer__6.Character.RightHand };
- ({ v1.AnimationTable.PunchRight, v1.AnimationTable.PunchLeft })[math.random(1, 2)]:Play();
- else
- v23 = { l__LocalPlayer__6.Character.RightFoot, l__LocalPlayer__6.Character.RightLowerLeg };
- v1.AnimationTable.Stomp:Play();
- end;
- local v24 = {};
- u7 = true;
- for v25, v26 in pairs(v23) do
- local u9 = nil;
- u9 = v26.Touched:Connect(function(p7)
- if u7 == true and (p7.Parent ~= l__LocalPlayer__6.Character or p7.Parent.Parent ~= l__LocalPlayer__6.Character) then
- local v27 = p7.Parent:FindFirstChild("Humanoid") or p7.Parent.Parent:FindFirstChild("Humanoid");
- if v27 and v27.Health > 0 then
- u7 = false;
- l__Events__2.GeneralEvent:FireServer("HE", v27);
- v27.Parent.PrimaryPart.HitParticle:Emit(1);
- v2.ShakeCamera(1);
- v24[u9] = nil;
- u9:Disconnect();
- end;
- end;
- end);
- v24[u9] = true;
- end;
- wait(1);
- for v28, v29 in pairs(v24) do
- v28:Disconnect();
- end;
- u6 = false;
- end;
- end);
- end;
- v1.ActivateKey();
- end;
- end;
- l__UserInputService__7.TouchTap:Connect(function(p8, p9)
- if p9 then
- return;
- end;
- u8();
- end);
- l__UserInputService__7.InputBegan:Connect(function(p10, p11)
- if p11 then
- return;
- end;
- if p10.UserInputType == Enum.UserInputType.MouseButton1 then
- u8();
- end;
- end);
- local u10 = false;
- l__UserInputService__7.JumpRequest:Connect(function()
- if u10 == false and l__LocalPlayer__6.Character.Humanoid.JumpPower > 0 and l__LocalPlayer__6.Character.Humanoid:GetState() ~= Enum.HumanoidStateType.Freefall then
- u10 = true;
- spawn(function()
- wait(1.5);
- u10 = false;
- end);
- if l__LocalPlayer__6.Character.PrimaryPart.BodyPosition.MaxForce == Vector3.new(0, 0, 0) then
- v1.SendToServer("Agility");
- end;
- end;
- end);
- function v1.PlayerSpawned()
- v1.RemoveKey();
- v1.Sword = nil;
- if u3 then
- u3:Disconnect();
- u3 = nil;
- end;
- end;
- function v1.PlayerDied()
- v1.Loaded = false;
- v1.RemoveKey();
- v1.Sword = nil;
- if u3 then
- u3:Disconnect();
- u3 = nil;
- end;
- end;
- return v1;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement