From f8076b4f802efca482901bbe338b514cb6d86cfb Mon Sep 17 00:00:00 2001 From: notderpaul <62160886+notderpaul@users.noreply.github.com> Date: Thu, 19 Oct 2023 13:55:10 +0200 Subject: [PATCH] Update Addict.lua --- AddictScript/Addict.lua | 3953 +-------------------------------------- 1 file changed, 6 insertions(+), 3947 deletions(-) diff --git a/AddictScript/Addict.lua b/AddictScript/Addict.lua index b835980..c6accce 100644 --- a/AddictScript/Addict.lua +++ b/AddictScript/Addict.lua @@ -8,9 +8,10 @@ util.require_natives("natives-1663599433") guidedMissile = require "ToxTool" local addict = menu -local addict_version = 1.41 -local gta_version = "v3028" -local dev_mode = false -- Disables some stuff like Updates [true/false] +local addict_version = 1.42 +local gta_version = "v3028" +local dcinv = "fg6Ex4PbkJ" +local dev_mode = false -- Disables stuff like Updates [true/false] -- Add all SE's here for quicker updates local se = { @@ -72,7 +73,7 @@ local function vector3(x, y, z) end local github = addict.list(addict.my_root(), "Updates", {"addictupdates"}) -addict.hyperlink(github, "Addict Discord", "https://discord.gg/zwdPY4jn") +addict.hyperlink(github, "Addict Discord", "https://discord.gg/" .. dcinv) async_http.init("raw.githubusercontent.com","/Addict0919/Addict-Script/main/AddictScript/AddictScriptChangelog",function(b) response=true; @@ -26168,3946 +26169,4 @@ addict.trigger_commands("clicktaostranslatorcrash" .. players.get_name(pid)) util.yield(10) addict.trigger_commands("clicktaostranslator2crash" .. players.get_name(pid)) util.yield(10) -addict.trigger_commands("clicktenniscoachcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickwadecrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickshophighcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickfranklincrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicklazlowcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicksiemoncrash" .. players.get_name(pid)) -util.yield(1000) -else -addict.trigger_commands("clickcombat" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickbeverlycrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickfabiencrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickmanuelcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicktaostranslatorcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicktaostranslator2crash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicktenniscoachcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickwadecrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickshophighcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clickfranklincrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicklazlowcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("clicksiemoncrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("superc") -util.yield(10) -addict.trigger_commands("superc") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - - -addict.action(oxtypecrashclick, "Combat Crash", {"clickcombat"}, "", function() -local mdl = util.joaat('A_F_M_ProlHost_01') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_COMBATMG'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Beverly Crash", {"clickbeverlycrash"}, "", function() -local mdl = util.joaat('cs_beverly') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 1, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Fabien Crash", {"clickfabiencrash"}, "", function() -local mdl = util.joaat('cs_fabien') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, 1), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Manuel Crash", {"clickmanuelcrash"}, "", function() -local mdl = util.joaat('cs_manuel') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 3, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - - -addict.action(oxtypecrashclick, "Taostranslator Crash", {"clicktaostranslatorcrash"}, "", function() -local mdl = util.joaat('cs_taostranslator') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Taostranslator2 Crash", {"clicktaostranslator2crash"}, "", function() -local mdl = util.joaat('cs_taostranslator2') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, 3), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Tenniscoach Crash", {"clicktenniscoachcrash"}, "", function() -local mdl = util.joaat('cs_tenniscoach') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), -1, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Wade Crash", {"clickwadecrash"}, "", function() -local mdl = util.joaat('cs_wade') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, -1, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Shop HIGH Crash", {"clickshophighcrash"}, "", function() -local mdl = util.joaat('S_F_M_Shop_HIGH') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, -1), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Franklin Crash", {"clickfranklincrash"}, "", function() -local mdl = util.joaat('P_Franklin_02') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), -3, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Lazlow Crash", {"clicklazlowcrash"}, "", function() -local mdl = util.joaat('CS_Lazlow') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, -3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(oxtypecrashclick, "Siemon Crash", {"clicksiemoncrash"}, "", function() -local mdl = util.joaat('IG_SiemonYetarian') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, -3), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -local oxtypecrashtoggle = addict.list(oxtypecrash, "Ox addict Type Crashes Toggled", {}, "From Nightfall") - -addict.toggle(oxtypecrashtoggle, "All Ox addict Type Crashes", {"toggleoxallcrash"}, "Use Panic Mode If Needed.", function(on_toggle) -if on_toggle then -addict.trigger_commands("togglecombat" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("beverlycrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("fabiencrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("manuelcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("taostranslatorcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("taostranslator2crash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("tenniscoachcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("wadecrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("shophighcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("franklincrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("lazlowcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("siemoncrash" .. players.get_name(pid)) -util.yield(10) -else -addict.trigger_commands("togglecombat" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("beverlycrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("fabiencrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("manuelcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("taostranslatorcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("taostranslator2crash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("tenniscoachcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("wadecrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("shophighcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("franklincrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("lazlowcrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("siemoncrash" .. players.get_name(pid)) -util.yield(10) -addict.trigger_commands("superc") -util.yield(10) -addict.trigger_commands("superc") -end -end) - - -addict.toggle_loop(oxtypecrashtoggle, "Combat Crash", {"togglecombat"}, "", function(on_toggle) - -local mdl = util.joaat('A_F_M_ProlHost_01') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_COMBATMG'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end -end) - -addict.toggle_loop(oxtypecrashtoggle, "Beverly Crash", {"beverlycrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_beverly') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 1, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end -end) - -addict.toggle_loop(oxtypecrashtoggle, "Fabien Crash", {"fabiencrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_fabien') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, 1), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end -end) - -addict.toggle_loop(oxtypecrashtoggle, "Manuel Crash", {"manuelcrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_manuel') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 3, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - - -addict.toggle_loop(oxtypecrashtoggle, "Taostranslator Crash", {"taostranslatorcrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_taostranslator') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Taostranslator2 Crash", {"taostranslator2crash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_taostranslator2') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, 3), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Tenniscoach Crash", {"tenniscoachcrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_tenniscoach') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), -1, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Wade Crash", {"wadecrash"}, "", function(on_toggle) - -local mdl = util.joaat('cs_wade') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, -1, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Shop HIGH Crash", {"shophighcrash"}, "", function(on_toggle) - -local mdl = util.joaat('S_F_M_Shop_HIGH') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, -1), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Franklin Crash", {"franklincrash"}, "", function(on_toggle) - -local mdl = util.joaat('P_Franklin_02') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), -3, 0, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Lazlow Crash", {"lazlowcrash"}, "", function(on_toggle) - -local mdl = util.joaat('CS_Lazlow') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, -3, 0), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - -addict.toggle_loop(oxtypecrashtoggle, "Siemon Crash", {"siemoncrash"}, "", function(on_toggle) - -local mdl = util.joaat('IG_SiemonYetarian') -if request_model(mdl, 2) then -local pos = players.get_position(pid) -util.yield(1) -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -ped1 = entities.create_ped(26, mdl, ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER.GET_PLAYER_PED(pid), 0, 0, -3), 0) -local coords = ENTITY.GET_ENTITY_COORDS(ped1, true) -WEAPON.GIVE_WEAPON_TO_PED(ped1, util.joaat('WEAPON_HOMINGLAUNCHER'), 9999, true, true) -local obj -repeat -obj = WEAPON.GET_CURRENT_PED_WEAPON_ENTITY_INDEX(ped1, 0) -until obj ~= 0 or util.yield() -ENTITY.DETACH_ENTITY(obj, true, true) -util.yield(1) -FIRE.ADD_EXPLOSION(coords.x, coords.y, coords.z, 0, 1.0, false, true, 0.0, true) -entities.delete_by_handle(ped1) -util.yield(1) -else -util.toast("Failed to load model. :/") - -end - -end) - ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- - -local function random_args(id, amount) -local args = {id} -if not amount or amount == 0 then -return args -else -for i = 2, amount + 1 do -args[i] = math.random(-2147483647, 2147483647) -end -return args -end -end - -addict.divider(standcrash, "Stand Crash Loops") - - -addict.toggle_loop(standcrash, "Elegant", {"togglecrash"}, "Blocked by most addicts.", function() -addict.trigger_commands("crash" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "BDSM", {"togglechoke"}, "Blocked by popular addicts.", function(on_loop) -addict.trigger_commands("choke" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "Indecent Exposure", {"toggleflashcrash"}, "Blocked by popular addicts.", function(on_loop) -addict.trigger_commands("flashcrash" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "Next-Gen", {"togglengcrash"}, "Blocked by popular addicts.", function(on_loop) -addict.trigger_commands("ngcrash" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "Steamroller", {"togglesteamroll"}, "Note: This crash will also affect other players close to your target.", function(on_loop) -addict.trigger_commands("steamroll" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "Burger King Foot Lettuce", {"togglefootlettuce"}, "Can't be blocked without consequences, but the target might karma you for using it.", function(on_loop) -addict.trigger_commands("footlettuce" .. players.get_name(pid)) -util.yield(1000) -end) - -addict.toggle_loop(standcrash, "Vehicular Manslaughter", {"toggleslaughter"}, "A discrete kick that won't tell the target who did it. Unblockable when you are the host.", function(on_loop) -addict.trigger_commands("slaughter" .. players.get_name(pid)) -util.yield(1000) -end) - - - -addict.divider(crash, "Before Crashes") - -addict.toggle(crash, "Panic Mode", {"panicmode"}, "This will render you basically uncrashable at the cost of disrupting all gameplay", function(on_toggle) -local BlockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Enabled") -local UnblockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Disabled") -local BlockIncSyncs = addict.ref_by_path("Online>Protections>Syncs>Incoming>Any Incoming Sync>Block>Enabled") -local UnblockIncSyncs = addict.ref_by_path("Online>Protections>Syncs>Incoming>Any Incoming Sync>Block>Disabled") -if on_toggle then -addict.trigger_commands("desyncall on") -addict.trigger_command(BlockIncSyncs) -addict.trigger_command(BlockNetEvents) -addict.trigger_commands("anticrashcamera on") -else -addict.trigger_commands("desyncall off") -addict.trigger_command(UnblockIncSyncs) -addict.trigger_command(UnblockNetEvents) -addict.trigger_commands("anticrashcamera off") -end -end) - -addict.toggle(crash, "Block Player", {"block"}, "Shortcut to blocking the player join reaction ", function() -addict.trigger_commands("historyblock" .. players.get_name(pid)) -end) - -end - --------------------------------------- - - -local function get_transition_state(pid) -return memory.read_int(memory.script_global(((glob.player + 1) + (pid * 453)) + 230)) -end - -local function get_interior_player_is_in(pid) -return memory.read_int(memory.script_global(((glob.player + 1) + (pid * 453)) + 243)) -end - - -local unreleased_vehicles = { -"virtue", -"eudora", -"boor", -"broadway", -"everon2", -"manchez3", -"panthere2", -} - -local modded_vehicles = { -"dune2", -"tractor", -"dilettante2", -"asea2", -"cutter", -"mesa2", -"jet", -"policeold1", -"policeold2", -"armytrailer2", -"towtruck", -"towtruck2", -"cargoplane", -} - -local modded_weapons = { -"weapon_railgun", -"weapon_stungun", -"weapon_digiscanner", -"weapon_emplauncher", -"weapon_digiscanner", -"weapon_raypistol", -"weapon_firework", -"weapon_stungun", -"weapon_flare", -} - -local all_weapons = { -"weapon_railgun", -"weapon_stungun", -"weapon_digiscanner", -"weapon_emplauncher", -"weapon_digiscanner", -"weapon_raypistol", -"weapon_firework", -"weapon_flare", -"WEAPON_KNIFE", -"WEAPON_NIGHTSTICK", -"weapon_bottle", -"weapon_unarmed", -"WEAPON_HAMMER", -"WEAPON_BAT", -"WEAPON_GOLFCLUB", -"WEAPON_CROWBAR", -"WEAPON_PISTOL", -"WEAPON_COMBATPISTOL", -"WEAPON_APPISTOL", -"WEAPON_PISTOL50", -"WEAPON_MICROSMG", -"WEAPON_SMG", -"WEAPON_ASSAULTSMG", -"WEAPON_ASSAULTRIFLE", -"weapon_hatchet", -"weapon_knuckle", -"weapon_machete", -"weapon_dagger", -"weapon_switchblade", -"weapon_wrench", -"weapon_battleaxe", -"weapon_poolcue", -"weapon_pistol_mk2", -"weapon_snspistol", -"weapon_snspistol_mk2", -"weapon_heavypistol", -"weapon_vintagepistol", -"weapon_flaregun", -"weapon_marksmanpistol", -"weapon_revolver", -"weapon_revolver_mk2", -"weapon_doubleaction", -"weapon_ceramicpistol", -"weapon_navyrevolver", -"weapon_smg_mk2", -"weapon_combatpdw", -"weapon_machinepistol", -"weapon_minismg", -"weapon_raycarbine", -"weapon_pumpshotgun", -"weapon_pumpshotgun_mk2", -"weapon_sawnoffshotgun", -"weapon_assaultshotgun", -"weapon_bullpupshotgun", -"weapon_musket", -"weapon_heavyshotgun", -"weapon_dbshotgun", -"weapon_autoshotgun", -"weapon_assaultrifle", -"weapon_assaultrifle_mk2", -"weapon_carbinerifle", -"weapon_carbinerifle_mk2", -"weapon_advancedrifle", -"weapon_specialcarbine", -"weapon_specialcarbine_mk2", -"weapon_bullpuprifle", -"weapon_bullpuprifle_mk2", -"weapon_compactrifle", -"weapon_mg", -"weapon_combatmg", -"weapon_combatmg_mk2", -"weapon_gusenberg", -"weapon_sniperrifle", -"weapon_heavysniper", -"weapon_heavysniper_mk2", -"weapon_marksmanrifle", -"weapon_marksmanrifle_mk2", -"weapon_rpg", -"weapon_grenadelauncher", -"weapon_grenadelauncher_smoke", -"weapon_minigun", -"weapon_hominglauncher", -"weapon_compactlauncher", -"weapon_rayminigun", -"weapon_grenade", -"weapon_bzgas", -"weapon_molotov", -"weapon_proxmine", -"weapon_snowball", -"weapon_pipebomb", -"weapon_ball", -"weapon_smokegrenade", -"weapon_stickybomb", -"weapon_petrolcan", -"weapon_parachute", -"weapon_fireextinguisher", -"weapon_hazardcan", -} - - -local proofs = { -bullet = {name="Bullets",on=false}, -fire = {name="Fire",on=false}, -explosion = {name="Explosions",on=false}, -collision = {name="Collision",on=false}, -melee = {name="Melee",on=false}, -steam = {name="Steam",on=false}, -drown = {name="Drowning",on=false}, -} - - -local values = { -[0] = 0, -[1] = 50, -[2] = 88, -[3] = 160, -[4] = 208, -} - -local interior_stuff = {0, 233985, 169473, 169729, 169985, 170241, 177665, 177409, 185089, 184833, 184577, 163585, 167425, 167169} - -local self_protections = addict.list(addict.my_root(), "Protections", {}, "") - -addict.divider(self_protections, "Addict Protections") - -local proofsList = addict.list(self_protections, "Godmode Editor", {}, "") -local immortalityCmd = addict.ref_by_path("Self>Immortality") -for _,data in pairs(proofs) do -addict.toggle(proofsList, data.name, {data.name:lower().."proof"}, "Makes you invulnerable to "..data.name:lower()..".", function(toggle) -data.on = toggle -end) -end -util.create_tick_handler(function() -local player = players.user_ped() -if not addict.get_value(immortalityCmd) then -ENTITY.SET_ENTITY_PROOFS(player, proofs.bullet.on, proofs.fire.on, proofs.explosion.on, proofs.collision.on, proofs.melee.on, proofs.steam.on, false, proofs.drown.on) -end -end) - - -local ghost = false -local ghostCmd -local ghostCmd = addict.toggle(proofsList, "Auto Ghost Godmode Players", {}, "", function(toggle) -ghost = toggle - -if not ghost then -for _, pid in ipairs(players.list(false, true, true)) do -NETWORK._SET_RELATIONSHIP_TO_PLAYER(pid, false) -end -return end - - -while ghost do -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -for i, interior in ipairs(interior_stuff) do -if (players.is_godmode(pid) or not ENTITY._GET_ENTITY_CAN_BE_DAMAGED(ped)) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -NETWORK._SET_RELATIONSHIP_TO_PLAYER(pid, true) -break -end -end -end -util.yield() -end -end) - -addict.toggle_loop(proofsList, "Stealth Vehicle Godmode On", {}, "Won't be detected as vehicle godmode by most addicts. Note: Save your profile now to keep it on.", function() -ENTITY.SET_ENTITY_PROOFS(entities.get_user_vehicle_as_handle(), true, true, true, true, true, 0, 0, true) -end, function() ENTITY.SET_ENTITY_PROOFS(PED.GET_VEHICLE_PED_IS_IN(players.user(), false), false, false, false, false, false, 0, 0, false) -end) - -addict.toggle_loop(proofsList, "Stealth Vehicle Godmode Off", {}, "Turns off Godmode for the vehicle", function() -ENTITY.SET_ENTITY_PROOFS(entities.get_user_vehicle_as_handle(), false, false, false, false, false, 0, 0, false) -end, function() ENTITY.SET_ENTITY_PROOFS(PED.GET_VEHICLE_PED_IS_IN(players.user(), true), true, true, true, true, true, 0, 0, true) -end) - -local anti_bounty = addict.list(self_protections, "Anti-Bounty's") - -addict.action(anti_bounty, "Anti-Bounty", {"bountyoff"}, "Turns off bounty's.", function() -if memory.read_int(memory.script_global(glob.player_bounty + 4 + 1 + (players.user() * 3))) == 1 then -memory.write_int(memory.script_global(glob.bounty1 + 1856 + 17), -1) -memory.write_int(memory.script_global((glob.slot + 1) + 5149 + 13), 2880000) -else -util.toast("You don't currently have a bounty bitch! xD.") -end -end) - -addict.toggle_loop(anti_bounty, "Anti-Bounty's", {"bountysoff"}, "Turns off bounty's. Keep toggled if bounty's persist", function() -if memory.read_int(memory.script_global(glob.player_bounty + 4 + 1 + (players.user() * 3))) == 1 then -memory.write_int(memory.script_global(glob.bounty1 + 1856 + 17), -1) -memory.write_int(memory.script_global((glob.slot + 1) + 5149 + 13), 2880000) -else -end -end) - -local anti_mugger = addict.list(self_protections, "Block Muggers") - -addict.toggle_loop(anti_mugger, "Anti-Mugger", {}, "Prevents you from being mugged", function() -- thx nowiry for improving my method :D -if NETWORK.NETWORK_IS_SCRIPT_ACTIVE("am_gang_call", 0, true, 0) then -local ped_netId = memory.script_local("am_gang_call", 63 + 10 + (0 * 7 + 1)) -local sender = memory.script_local("am_gang_call", 287) -local target = memory.script_local("am_gang_call", 288) -local player = players.user() - -util.spoof_script("am_gang_call", function() -if (memory.read_int(sender) ~= player and memory.read_int(target) == player -and NETWORK.NETWORK_DOES_NETWORK_ID_EXIST(memory.read_int(ped_netId)) -and NETWORK.NETWORK_REQUEST_CONTROL_OF_NETWORK_ID(memory.read_int(ped_netId))) then -local mugger = NETWORK.NET_TO_PED(memory.read_int(ped_netId)) -entities.delete_by_handle(mugger) -util.toast("Blocked mugger from " .. players.get_name(memory.read_int(sender))) -end -end) -end -end) - -addict.toggle_loop(anti_mugger, "Someone Else", {}, "Prevents others from being mugged.", function() -if NETWORK.NETWORK_IS_SCRIPT_ACTIVE("am_gang_call", 0, true, 0) then -local ped_netId = memory.script_local("am_gang_call", 63 + 10 + (0 * 7 + 1)) -local sender = memory.script_local("am_gang_call", 287) -local target = memory.script_local("am_gang_call", 288) -local player = players.user() - -util.spoof_script("am_gang_call", function() -if memory.read_int(target) ~= player and memory.read_int(sender) ~= player -and NETWORK.NETWORK_DOES_NETWORK_ID_EXIST(memory.read_int(ped_netId)) -and NETWORK.NETWORK_REQUEST_CONTROL_OF_NETWORK_ID(memory.read_int(ped_netId)) then -local mugger = NETWORK.NET_TO_PED(memory.read_int(ped_netId)) -entities.delete_by_handle(mugger) -util.toast("Block mugger sent by " .. players.get_name(memory.read_int(sender)) .. " to " .. players.get_name(memory.read_int(target))) -end -end) -end -end) - -local Cleansers = addict.list(self_protections, "Cleansers", {"cleansers"}) - -addict.action(Cleansers, "Remove Attachments", {"remove attachments"}, "Cleans your ped of all attachments by regenerating it", function() -if PED.IS_PED_MALE(PLAYER.PLAYER_PED_ID()) then -addict.trigger_commands("mpmale") -else -addict.trigger_commands("mpfemale") -end -end) - -supercleanse = addict.action(Cleansers, "Super Cleanse", {"cleanrope"}, "Cleans everything including ropes.", function(click_type) -local ct = 0 -for k,ent in pairs(entities.get_all_vehicles_as_handles()) do -local driver = VEHICLE.GET_PED_IN_VEHICLE_SEAT(ent, -1) -if not PED.IS_PED_A_PLAYER(driver) then -entities.delete_by_handle(ent) -ct += 1 -end -end -for k,ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -entities.delete_by_handle(ent) -end -ct += 1 -end -for k,ent in pairs(entities.get_all_objects_as_handles()) do -entities.delete_by_handle(ent) -ct += 1 -end -local rope_alloc = memory.alloc(4) -for i=0, 100 do -memory.write_int(rope_alloc, i) -if PHYSICS.DOES_ROPE_EXIST(rope_alloc) then -PHYSICS.DELETE_ROPE(rope_alloc) -ct += 1 -end -end -util.toast("Super Cleanse has cleaned " .. ct .. " entities!") -end, function() -util.toast("Aborted.") -end) - -supercleanse = addict.toggle_loop(Cleansers, "Super Cleanse Toggle", {"cleanropeloop"}, "Cleans everything including ropes.", function(click_type) -util.show_corner_help("Be careful; using this can possibly crash your game or break a mission if important entities get deleted. Proceed?\n(NOTE: If you have skip warnings on, this won't show again.)") -local ct = 0 -for k,ent in pairs(entities.get_all_vehicles_as_handles()) do -local driver = VEHICLE.GET_PED_IN_VEHICLE_SEAT(ent, -1) -if not PED.IS_PED_A_PLAYER(driver) then -entities.delete_by_handle(ent) -ct += 1 -end -end -for k,ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -entities.delete_by_handle(ent) -end -ct += 1 -end -for k,ent in pairs(entities.get_all_objects_as_handles()) do -entities.delete_by_handle(ent) -ct += 1 -end -local rope_alloc = memory.alloc(4) -for i=0, 100 do -memory.write_int(rope_alloc, i) -if PHYSICS.DOES_ROPE_EXIST(rope_alloc) then -PHYSICS.DELETE_ROPE(rope_alloc) -ct += 1 -end -end -end, function() -util.toast("Everything cleaned including ropes.") -end) - -addict.action(Cleansers, "No Entity Spawn", {"clean"}, "Attempt to fuck every single entity without exception. Not recommended but fuck it.", function(on_click) -local ct = 0 -for k,ent in pairs(entities.get_all_vehicles_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) - -ct = ct + 1 -end -for k,ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) - -end -ct = ct + 1 -end -for k,ent in pairs(entities.get_all_objects_as_handles()) do -if ent ~= PLAYER.PLAYER_PED_ID() then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -ct = ct + 1 -end -end -for k,ent in pairs(entities.get_all_pickups_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -return -end -end, nil, nil, COMMANDPERM_FRIENDLY) - -addict.toggle_loop(Cleansers, "No Entity Spawn Toggled", {"noentities"}, "Attempt to fuck every single entity without exception. Not recommended but fuck it.", function(on_loop) -local ct = 0 -for k,ent in pairs(entities.get_all_vehicles_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) - -ct = ct + 1 -end -for k,ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) - -end -ct = ct + 1 -end -for k,ent in pairs(entities.get_all_objects_as_handles()) do -if ent ~= PLAYER.PLAYER_PED_ID() then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -ct = ct + 1 -end -end -for k,ent in pairs(entities.get_all_pickups_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -return -end -end) - -addict.toggle_loop(Cleansers, "Clear Shit Up Toggled", {"supercloop"}, "Every 1 second deletes all owned entities.", function (on_toggle) -addict.trigger_commands("superc") -util.yield(750) -end) - -addict.click_slider(Cleansers,"Clear Shit Up", {"superc"}, "5 = peds, 4 = vehicles, 3 = objects, 2 = pickups, 1 = all \nNote: This excludes players and their vehicles.", 1, 5, 1, 1, function(on_change) -if on_change == 5 then -local count = 0 -for k,ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -count = count + 1 - -end -end ---util.toast("Fucked off " .. count .. " Peds removed. :)") -end -if on_change == 4 then -local count = 0 -for k, ent in pairs(entities.get_all_vehicles_as_handles()) do -local PedInSeat = VEHICLE.GET_PED_IN_VEHICLE_SEAT(ent, -1, false) -if not PED.IS_PED_A_PLAYER(PedInSeat) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -count = count + 1 -end -end ---util.toast("Fucked off " .. count .. " Vehicles removed. :)") -return -end -if on_change == 3 then -local count = 0 -for k,ent in pairs(entities.get_all_objects_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -count = count + 1 -util.yield() -end -return ---util.toast("Fucked off " .. count .. " Objects removed. :)") -end -if on_change == 2 then -local count = 0 -for k, ent in pairs(entities.get_all_pickups_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -count = count + 1 -util.yield() -end -return ---util.toast("Fucked off " .. count .. " Pickups removed. :)") -end -if on_change == 1 then -local count = 0 -for k, ent in pairs(entities.get_all_peds_as_handles()) do -if not PED.IS_PED_A_PLAYER(ent) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -count = count + 1 -end -end -for k, ent in pairs(entities.get_all_vehicles_as_handles()) do -local PedInSeat = VEHICLE.GET_PED_IN_VEHICLE_SEAT(ent, -1, false) -if not PED.IS_PED_A_PLAYER(PedInSeat) then -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -util.yield() -count = count + 1 -end -end -for k,ent in pairs(entities.get_all_objects_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -count = count + 1 -util.yield() -end -for k,ent in pairs(entities.get_all_pickups_as_handles()) do -ENTITY.SET_ENTITY_AS_MISSION_ENTITY(ent, false, false) -entities.delete_by_handle(ent) -count = count + 1 -util.yield() -end -return ---util.toast("Fucked Everything off " .. count .. " Entities removed. :)") -end -end) - -addict.toggle_loop(self_protections, "Force Stop all sound events", {"stopsounds"}, "", function() -for i=-1,100 do -AUDIO.STOP_SOUND(i) -AUDIO.RELEASE_SOUND_ID(i) -end -end) - -addict.toggle(self_protections, "Toggle Block all Network Events", {}, "This breaks the game, so only leave it on if you are worried about an incoming modder attack", function(on_toggle) -local BlockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Enabled") -local UnblockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Disabled") -if on_toggle then -addict.trigger_command(BlockNetEvents) -else -addict.trigger_command(UnblockNetEvents) -end -end) - - -addict.toggle(self_protections, "Toggle Block all Incoming Syncs", {}, "This breaks the game, so only leave it on if you are worried about an incoming modder attack", function(on_toggle) -local BlockIncSyncs = addict.ref_by_path("Online>Protections>Syncs>Incoming>Any Incoming Sync>Block>Enabled") -local UnblockIncSyncs = addict.ref_by_path("Online>Protections>SyPanicncs>Incoming>Any Incoming Sync>Block>Disabled") -if on_toggle then -addict.trigger_command(BlockIncSyncs) -else -addict.trigger_command(UnblockIncSyncs) -end -end) - -addict.toggle(self_protections, "Toggle Block all Outgoing Syncs", {}, "This breaks the game, and other players will not receive any updates from your client", function(on_toggle) -if on_toggle then -addict.trigger_commands("desyncall on") -else -addict.trigger_commands("desyncall off") -end -end) - -addict.toggle(self_protections, "Toggle Anticrashcam", {"acc"}, "Put this here for redundancy", function(on_toggle) -if on_toggle then -addict.trigger_commands("anticrashcam on") -addict.trigger_commands("potatomode on") -else -addict.trigger_commands("anticrashcam off") -addict.trigger_commands("potatomode off") -end -end) - -addict.toggle(self_protections, "Toggle Panic Mode", {"panic"}, "Uses all of the above. This will render you basically uncrashable at the cost of disrupting all gameplay", function(on_toggle) -local BlockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Enabled") -local UnblockNetEvents = addict.ref_by_path("Online>Protections>Events>Raw Network Events>Any Event>Block>Disabled") -local BlockIncSyncs = addict.ref_by_path("Online>Protections>Syncs>Incoming>Any Incoming Sync>Block>Enabled") -local UnblockIncSyncs = addict.ref_by_path("Online>Protections>Syncs>Incoming>Any Incoming Sync>Block>Disabled") -if on_toggle then -addict.trigger_commands("desyncall on") -addict.trigger_command(BlockIncSyncs) -addict.trigger_command(BlockNetEvents) -addict.trigger_commands("anticrashcamera on") -else -addict.trigger_commands("desyncall off") -addict.trigger_command(UnblockIncSyncs) -addict.trigger_command(UnblockNetEvents) -addict.trigger_commands("anticrashcamera off") -end -end) - - -addict.toggle_loop(self_protections, "Block Clones", {"blockclones"}, "Detects And Blocks Clones.", function() -for i, ped in ipairs(entities.get_all_peds_as_handles()) do -if ENTITY.GET_ENTITY_MODEL(ped) == ENTITY.GET_ENTITY_MODEL(players.user_ped()) and not PED.IS_PED_A_PLAYER(ped) and not util.is_session_transition_active() then -util.toast("Clone model detected. Clearing...") -entities.delete_by_handle(ped) -util.yield(100) -end -end -end) - -addict.toggle_loop(self_protections, "Remove Stickys From Car", {"removestickys"}, "", function(toggle) -local car = PED.GET_VEHICLE_PED_IS_IN(players.user_ped(PLAYER.PLAYER_PED_ID(pid), true)) -NETWORK.REMOVE_ALL_STICKY_BOMBS_FROM_ENTITY(car) -end) - -local values = { -[0] = 0, -[1] = 50, -[2] = 88, -[3] = 160, -[4] = 208, -} - - -addict.toggle_loop(self_protections, "Admin Bail", {}, "If it detects an R* admin it changes your session.", function(on) -bailOnAdminJoin = on -end) - -if bailOnAdminJoin then -if players.is_marked_as_admin(player_id) then -util.toast(players.get_name(player_id) .. " If there is an admin, for another session.") -addict.trigger_commands("quickbail") -return -end -end - - -addict.toggle_loop(self_protections, "Block PFTX/Particulate Lag", {}, "", function() -local coords = ENTITY.GET_ENTITY_COORDS(players.user_ped() , false); -GRAPHICS.REMOVE_PARTICLE_FX_IN_RANGE(coords.x, coords.y, coords.z, 400) -GRAPHICS.REMOVE_PARTICLE_FX_FROM_ENTITY(players.user_ped()) -end) - - -addict.toggle_loop(self_protections, "Ghost PvP Players", {}, "", function() -for _, pid in ipairs(players.list(false, true, true)) do -if PLAYER.IS_PLAYER_FREE_AIMING(pid) then -NETWORK.SET_REMOTE_PLAYER_AS_GHOST(pid, true) -else -NETWORK.SET_REMOTE_PLAYER_AS_GHOST(pid, false) -end -end -end) - -local detections = addict.list(addict.my_root(), "Modder Detections", {}, "") - ---[[ -addict.toggle_loop(detections, "Get IP's", {}, "Log's IP's", function() -for _, pid in ipairs(players.list(false, true, true)) do -local print_ip = players.get_connect_ip(pid) -if print_ip == util.joaat(print_ip) then -util.draw_debug_text(players.get_connect_ip(pid) .. "(" .. print_ip .. ")") -util.log(players.get_name(pid) .. "(" .. print_ip .. ")") -end -end -end) - -addict.toggle_loop(detections, "Focused in the addict", {}, "Detects stuff", function() -for _, pid in ipairs(players.list(false, true, true)) do -local focused = players.get_focused(pid) -if focused == util.joaat(focused) then -util.draw_debug_text(players.get_name(pid) .. " name is focused in the addict") -end -end -end) - -addict.toggle_loop(detections, "Rockstar id", {}, "Detects stuff", function() -for _, pid in ipairs(players.list(false, true, true)) do -local rockstar_id = players.get_rockstar_id(pid) -if rockstar_id == util.joaat(rockstar_id) then -util.draw_debug_text(players.get_name(players.get_rockstar_id(pid)) .. " Rockstar id") -end -end -end) - -addict.toggle_loop(detections, "Get money", {}, "Detects stuff", function() -for _, pid in ipairs(players.list(false, true, true)) do -local get_bank = players.get_bank(pid) -if get_bank == util.joaat(get_bank) then -util.draw_debug_text(players.get_name(players.get_bank(pid)) .. " Get money") -end -end -end) - -addict.toggle_loop(detections, "Player is using controller", {}, "Detects stuff", function() -for _, pid in ipairs(players.list(false, true, true)) do -local is_using_controller = players.is_using_controller(pid) -if is_using_controller == util.joaat(is_using_controller) then -util.draw_debug_text(players.get_name(players.is_using_controller(pid)) .. " Player is using controller") -end -end -end) -]] - -local auto_punish = addict.list(detections, "Aim Punishments", {}, "") - -local aim_det = addict.list(detections, "Aim Detection", {}, "") - -local autohost = addict.list(detections, "Host Detection", {}, "") - -addict.toggle_loop(aim_det, "Aim Detection", {}, "Detects if someone is aiming a weapon at you.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(all_weapons) do -local weapon_hash = util.joaat(hash) -if PLAYER.IS_PLAYER_FREE_AIMING(pid, ped, weapon_hash) and PLAYER.IS_PLAYER_TARGETTING_ENTITY(pid, ped, weapon_hash) then -util.draw_debug_text(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.log(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -else -util.yield(100) -end -end -end -end) - -addict.toggle_loop(auto_punish, "Auto Snipe", {}, "Detects if someone is aiming a weapon at you, then shoots them back them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(all_weapons) do -local weapon_hash = util.joaat(hash) -if PLAYER.IS_PLAYER_FREE_AIMING(pid, ped, weapon_hash) and PLAYER.IS_PLAYER_TARGETTING_ENTITY(pid, ped, weapon_hash) then -addict.trigger_commands("osnipel" .. players.get_name(pid)) -util.yield(1000) -addict.trigger_commands("osnipel" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.log(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -else -util.yield(100) -end -end -end -end) - -addict.toggle_loop(auto_punish, "Auto Firework", {}, "Detects if someone is aiming a weapon at you, then shoots fireworks at them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(all_weapons) do -local weapon_hash = util.joaat(hash) -if PLAYER.IS_PLAYER_FREE_AIMING(pid, ped, weapon_hash) and PLAYER.IS_PLAYER_TARGETTING_ENTITY(pid, ped, weapon_hash) then -addict.trigger_commands("fireworkon" .. players.get_name(pid)) -util.yield(1000) -addict.trigger_commands("fireworkon" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.log(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -else -util.yield(100) -end -end -end -end) - -addict.toggle_loop(auto_punish, "Auto Atomizer", {}, "Detects if someone is aiming a weapon at you, then shoots atomizer at them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(all_weapons) do -local weapon_hash = util.joaat(hash) -if PLAYER.IS_PLAYER_FREE_AIMING(pid, ped, weapon_hash) and PLAYER.IS_PLAYER_TARGETTING_ENTITY(pid, ped, weapon_hash) then -addict.trigger_commands("atomizeron" .. players.get_name(pid)) -util.yield(1000) -addict.trigger_commands("atomizeron" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -util.log(players.get_name(pid) .. " Is Aiming A Weapon" .. "(" .. hash .. ")") -else -util.yield(100) -end -end -end -end) - -addict.toggle_loop(autohost, "Is Host", {}, "Detects if someone host", function() -util.draw_debug_text(players.get_name(players.get_host()) .. " Is Host") -end) - -addict.toggle_loop(autohost, "Auto Kick Host", {}, "Detects if someone host, then kicks them this is best for basic and regular users.", function() -util.draw_debug_text(players.get_name(players.get_host()) .. " Is Host") -addict.trigger_commands("blast" .. players.get_name(players.get_host())) -end) - -local gdmedits = addict.list(detections, "Godmode", {}, "") -addict.toggle_loop(gdmedits, "Godmode", {}, "Detects if someone is using godmode.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -for i, interior in ipairs(interior_stuff) do -if (players.is_godmode(pid) or not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(ped)) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -util.draw_debug_text(players.get_name(pid) .. " Is In Godmode") -break -end -end -end -end) - -addict.toggle_loop(gdmedits, "Godmode Auto Kick", {}, "Detects if someone is using godmode, blocks there joins and kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -for i, interior in ipairs(interior_stuff) do -if (players.is_godmode(pid) or not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(ped)) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is In Godmode") -util.toast(players.get_name(pid) .. "Is In Godmode") -break -end -end -end -end) - -local vehgdm = addict.list(detections, "Vehicle Godmode", {}, "") -addict.toggle_loop(vehgdm, "Vehicle Godmode", {}, "Detects if someone is using a vehicle that is in godmode.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -local player_veh = PED.GET_VEHICLE_PED_IS_USING(ped) -if PED.IS_PED_IN_ANY_VEHICLE(ped, false) then -for i, interior in ipairs(interior_stuff) do -if not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(player_veh) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -util.draw_debug_text(players.get_name(pid) .. " Is In Vehicle Godmode") -break -end -end -end -end -end) - -addict.toggle_loop(vehgdm, "Vehicle Godmode Auto Kick", {}, "Detects if someone is using a vehicle that is in godmode, blocks there joins and kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -local player_veh = PED.GET_VEHICLE_PED_IS_USING(ped) -if PED.IS_PED_IN_ANY_VEHICLE(ped, false) then -for i, interior in ipairs(interior_stuff) do -if not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(player_veh) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. "Is In Vehicle Godmode") -util.toast(players.get_name(pid) .. "Is In Vehicle Godmode") -break -end -end -end -end -end) - -addict.toggle_loop(vehgdm, "Vehicle Godmode Auto Slingshot", {}, "Detects if someone is using a vehicle that is in godmode, then slingshots there vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -local player_veh = PED.GET_VEHICLE_PED_IS_USING(ped) -if PED.IS_PED_IN_ANY_VEHICLE(ped, false) then -for i, interior in ipairs(interior_stuff) do -if not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(player_veh) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -addict.trigger_commands("slingshot" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. "Is In Vehicle Godmode") -util.toast(players.get_name(pid) .. "Is In Vehicle Godmode") -break -end -end -end -end -end) - -addict.toggle_loop(vehgdm, "Vehicle Godmode Auto Kick Them Out", {}, "Detects if someone is using a vehicle that is in godmode, then kicks them out of the vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local pos = ENTITY.GET_ENTITY_COORDS(ped, false) -local player_veh = PED.GET_VEHICLE_PED_IS_USING(ped) -if PED.IS_PED_IN_ANY_VEHICLE(ped, false) then -for i, interior in ipairs(interior_stuff) do -if not ENTITY.GET_ENTITY_CAN_BE_DAMAGED(player_veh) and not NETWORK.NETWORK_IS_PLAYER_FADING(pid) and ENTITY.IS_ENTITY_VISIBLE(ped) and get_transition_state(pid) ~= 0 and get_interior_player_is_in(pid) == interior then -addict.trigger_commands("vehkick" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. "Is In Vehicle Godmode") -util.toast(players.get_name(pid) .. "Is In Vehicle Godmode") -break -end -end -end -end -end) - -local unrelveh = addict.list(detections, "Unreleased Vehicle", {}, "") -addict.toggle_loop(unrelveh, "Unreleased Vehicle", {}, "Detects if someone is using a vehicle that has not been released yet.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(unreleased_vehicles) do -if modelHash == util.joaat(name) then -util.draw_debug_text(players.get_name(pid) .. " Is Driving An Unreleased Vehicle " .. "(" .. name .. ")") -end -end -end -end) - -addict.toggle_loop(unrelveh, "Unreleased Vehicle Auto Kick", {}, "Detects if someone is using a vehicle that has not been released yet, blocks there joins and buttplug kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(unreleased_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving An Unreleased Vehicle " .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving An Unreleased Vehicle" .. "(" .. name .. ")") -end -end -end -end) - -addict.toggle_loop(unrelveh, "Unreleased Car Auto Slingshot", {}, "Detects if someone is using a vehicle that has not been released yet, then slingshots there vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(unreleased_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("slingshot" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving An Unreleased Vehicle " .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving An Unreleased Vehicle" .. "(" .. name .. ")") -end -end -end -end) - -addict.toggle_loop(unrelveh, "Unreleased Car Auto Kick Them Out", {}, "Detects if someone is using a vehicle that has not been released yet, then Kicks them out.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(unreleased_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("vehkick" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving An Unreleased Vehicle " .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving An Unreleased Vehicle" .. "(" .. name .. ")") -end -end -end -end) - -local modhack = addict.list(detections, "It's a hacker", {}, "") -addict.toggle_loop(modhack, "It's a hacker", {}, "Detects if the player is about to ban", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -local reason = NETWORK.NETWORK_PLAYER_GET_CHEATER_REASON(player_id) -if NETWORK.NETWORK_PLAYER_IS_CHEATER(player_id) then -util.draw_debug_text(players.get_name(player_id) .. " They are about to ban him :u, reason:", reason) -util.toast(players.get_name(pid) .. " Is a hacker!" .. "(" .. name .. ")") -break -end -end -end) - -addict.toggle_loop(modhack, "It's a hacker Auto Kick", {}, "Detects if the player is about to ban, blocks there joins and buttplug kicks them.", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -local reason = NETWORK.NETWORK_PLAYER_GET_CHEATER_REASON(player_id) -if NETWORK.NETWORK_PLAYER_IS_CHEATER(player_id) then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(player_id) .. " They are about to ban him :u, reason:", reason) -util.toast(players.get_name(pid) .. " Is a hacker is being kicked now!" .. "(" .. name .. ")") -break -end -end -end) - -addict.toggle_loop(modhack, "It's a hacker Auto Crash", {}, "Detects if the player is about to banned, then blocks there joins and sends Attach Crash to annoy them :).", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -local reason = NETWORK.NETWORK_PLAYER_GET_CHEATER_REASON(player_id) -if NETWORK.NETWORK_PLAYER_IS_CHEATER(player_id) then -addict.trigger_commands("attachcrash" .. players.get_name(pid)) -addict.trigger_commands("historyblock" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(player_id) .. " They are about to ban him :u, reason:", reason) -util.toast(players.get_name(pid) .. " Is a hacker and is being Attach Crashed!" .. "(" .. name .. ")") -break -end -end -end) - - -local modweps = addict.list(detections, "Weapon In Interior", {}, "") -addict.toggle_loop(modweps, "Weapon In Interior", {}, "Detects if you use a gun indoors", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -if players.is_in_interior(player_id) and WEAPON.IS_PED_ARMED(player, 7) then -util.draw_debug_text(players.get_name(player_id) .. " Has a gun indoors") -break -end -end -end) - -addict.toggle_loop(modweps, "Weapon In Interior Auto Kick", {}, "Detects if you use a gun indoors, then blocks there joins and buttplug kicks them.", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -if players.is_in_interior(player_id) and WEAPON.IS_PED_ARMED(player, 7) then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(player_id) .. " Has a gun indoors") -util.toast(players.get_name(pid) .. " Weapon In Interior Auto Kicking..." .. "(" .. name .. ")") -break -end -end -end) - -addict.toggle_loop(modweps, "Weapon In Interior Auto Disarm", {}, "Detects if you use a gun indoors, then disarms them.", function() -for _, player_id in ipairs(players.list(false, true, true)) do -local player = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(player_id) -if players.is_in_interior(player_id) and WEAPON.IS_PED_ARMED(player, 7) then -addict.trigger_commands("disarm" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(player_id) .. " Has a gun indoors") -util.toast(players.get_name(pid) .. " Weapon In Interior Auto Kicking..." .. "(" .. name .. ")") -break -end -end -end) - - -local modwep = addict.list(detections, "Modded Weapon", {}, "") -addict.toggle_loop(modwep, "Modded Weapon", {}, "Detects if someone is using a weapon that can not be obtained in online.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(modded_weapons) do -local weapon_hash = util.joaat(hash) -if WEAPON.HAS_PED_GOT_WEAPON(ped, weapon_hash, false) and (WEAPON.IS_PED_ARMED(ped, 7) or TASK.GET_IS_TASK_ACTIVE(ped, 8) or TASK.GET_IS_TASK_ACTIVE(ped, 9)) then -util.draw_debug_text(players.get_name(pid) .. " Is Using A Modded Weapon" .. "(" .. hash .. ")") -break -end -end -end -end) - -addict.toggle_loop(modwep, "Modded Weapon Auto Kick", {}, "Detects if someone is using a weapon that can not be obtained in online, blocks there joins and buttplug kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(modded_weapons) do -local weapon_hash = util.joaat(hash) -if WEAPON.HAS_PED_GOT_WEAPON(ped, weapon_hash, false) and (WEAPON.IS_PED_ARMED(ped, 7) or TASK.GET_IS_TASK_ACTIVE(ped, 8) or TASK.GET_IS_TASK_ACTIVE(ped, 9)) then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Using A Modded Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Using A Modded Weapon" .. "(" .. hash .. ")") -break -end -end -end -end) - -addict.toggle_loop(modwep, "Modded Weapon Auto Disarm", {}, "Detects if someone is using a weapon that can not be obtained in online, then disarms them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -for i, hash in ipairs(modded_weapons) do -local weapon_hash = util.joaat(hash) -if WEAPON.HAS_PED_GOT_WEAPON(ped, weapon_hash, false) and (WEAPON.IS_PED_ARMED(ped, 7) or TASK.GET_IS_TASK_ACTIVE(ped, 8) or TASK.GET_IS_TASK_ACTIVE(ped, 9)) then -addict.trigger_commands("disarm" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Using A Modded Weapon" .. "(" .. hash .. ")") -util.toast(players.get_name(pid) .. " Is Using A Modded Weapon" .. "(" .. hash .. ")") -break -end -end -end -end) - -local modveh = addict.list(detections, "Modded Vehicle", {}, "") -addict.toggle_loop(modveh, "Modded Vehicle", {}, "Detects if someone is using a vehicle that can not be obtained in online.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(modded_vehicles) do -if modelHash == util.joaat(name) then -util.draw_debug_text(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -break -end -end -end -end) - -addict.toggle_loop(modveh, "Modded Vehicle Auto Kick", {}, "Detects if someone is using a vehicle that can not be obtained in online, blocks there joins and buttplug kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(modded_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -break -end -end -end -end) - -addict.toggle_loop(modveh, "Modded Vehicle Auto Slingshot", {}, "Detects if someone is using a vehicle that can not be obtained in online, then slingshots vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(modded_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("slingshot" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -break -end -end -end -end) - -addict.toggle_loop(modveh, "Modded Vehicle Auto Kick Them Out", {}, "Detects if someone is using a vehicle that can not be obtained in online, then kicks them out of the vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local modelHash = players.get_vehicle_model(pid) -for i, name in ipairs(modded_vehicles) do -if modelHash == util.joaat(name) then -addict.trigger_commands("vehkick" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -util.toast(players.get_name(pid) .. " Is Driving A Modded Vehicle" .. "(" .. name .. ")") -break -end -end -end -end) - - -local detsuperd = addict.list(detections, "Super Drive", {}, "") -addict.toggle_loop(detsuperd, "Super Drive", {}, "Detects if the player is using super drive.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local vehicle = PED.GET_VEHICLE_PED_IS_USING(ped) -local veh_speed = (ENTITY.GET_ENTITY_SPEED(vehicle)* 2.236936) -local class = VEHICLE.GET_VEHICLE_CLASS(vehicle) -if class ~= 15 and class ~= 16 and veh_speed >= 180 and VEHICLE.GET_PED_IN_VEHICLE_SEAT(vehicle, -1) and players.get_vehicle_model(pid) ~= util.joaat("oppressor") then -- not checking opressor mk1 cus its stinky -util.draw_debug_text(players.get_name(pid) .. " Is Using Super Drive") -break -end -end -end) - -addict.toggle_loop(detsuperd, "Super Drive Auto Kick", {}, "Detects if the player is using super drive, blocks there joins and buttplug kicks them.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local vehicle = PED.GET_VEHICLE_PED_IS_USING(ped) -local veh_speed = (ENTITY.GET_ENTITY_SPEED(vehicle)* 2.236936) -local class = VEHICLE.GET_VEHICLE_CLASS(vehicle) -if class ~= 15 and class ~= 16 and veh_speed >= 180 and VEHICLE.GET_PED_IN_VEHICLE_SEAT(vehicle, -1) and players.get_vehicle_model(pid) ~= util.joaat("oppressor") then -- not checking opressor mk1 cus its stinky -addict.trigger_commands("blast" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Using Super Drive") -util.toast(players.get_name(pid) .. " Is Using Super Drive") -break -end -end -end) - -addict.toggle_loop(detsuperd, "Super Drive Auto Slingshot", {}, "Detects if the player is using super drive, then slinghsots there vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local vehicle = PED.GET_VEHICLE_PED_IS_USING(ped) -local veh_speed = (ENTITY.GET_ENTITY_SPEED(vehicle)* 2.236936) -local class = VEHICLE.GET_VEHICLE_CLASS(vehicle) -if class ~= 15 and class ~= 16 and veh_speed >= 180 and VEHICLE.GET_PED_IN_VEHICLE_SEAT(vehicle, -1) and players.get_vehicle_model(pid) ~= util.joaat("oppressor") then -- not checking opressor mk1 cus its stinky -addict.trigger_commands("slingshot" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Using Super Drive") -util.toast(players.get_name(pid) .. " Is Using Super Drive") -break -end -end -end) - -addict.toggle_loop(detsuperd, "Super Drive Auto Kick Them Out", {}, "Detects if the player is using super drive, then kicks them out of the vehicle.", function() -for _, pid in ipairs(players.list(false, true, true)) do -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(pid) -local vehicle = PED.GET_VEHICLE_PED_IS_USING(ped) -local veh_speed = (ENTITY.GET_ENTITY_SPEED(vehicle)* 2.236936) -local class = VEHICLE.GET_VEHICLE_CLASS(vehicle) -if class ~= 15 and class ~= 16 and veh_speed >= 180 and VEHICLE.GET_PED_IN_VEHICLE_SEAT(vehicle, -1) and players.get_vehicle_model(pid) ~= util.joaat("oppressor") then -- not checking opressor mk1 cus its stinky -addict.trigger_commands("vehkick" .. players.get_name(pid)) -util.draw_debug_text(players.get_name(pid) .. " Is Using Super Drive") -util.toast(players.get_name(pid) .. " Is Using Super Drive") -break -end -end -end) - --------------------------------------- - -addict.action(addict.my_root(), "Yeet", {"ye"}, "Instantly sending yourself to desktop.", function() -MISC.QUIT_GAME() -- os.exit() not working? -end) - -addict.action(addict.my_root(), "Yeet Roulette", {"yeetroulette"}, "Take a chance by instantly sending yourself to desktop or use the Restart GTA V Option.", function() -local pick = math.random(6) -if pick == 4 then -util.toast("I loose.") -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1.0) -util.yield(300) -MISC.QUIT_GAME() -- os.exit() not working? -else -util.toast("Lucky Bastard ;)") -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1.0) -util.yield(200) -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1.0) -end -end, nil, nil, COMMANDPERM_AGGRESSIVE) - -addict.action(addict.my_root(), "Restart GTA V", {"restartgta"}, "Restarts your game, closes it Online. You will need to reinject (duh).", function(on_click) -MISC.RESTART_GAME() -end) - -addict.action(addict.my_root(), "Restart Script", {"restartaddictlua"}, "Restarts the script to check for updates. Or you may prefer it on hotkey to make it the first script in players list making spectate option faster to find.", function () -util.restart_script() -end) - -focusref = {} -isfocused = false -selectedcoloraddict = 0 -colorselec = 1 -allchatlabel = util.get_label_text("MP_CHAT_ALL") -teamchatlabel = util.get_label_text("MP_CHAT_TEAM") - -function save() -configfile = io.open(filesystem.store_dir().."chat_translator//config.txt", "w+") -configfile:write("colorselec = "..colorselec..string.char(10)..'teamchatlabel = "'..teamchatlabel..'"'..string.char(10)..'allchatlabel = "'..allchatlabel..'"') -configfile:close() -end - -if not filesystem.exists(filesystem.store_dir().."chat_translator//config.txt") then -filesystem.mkdir(filesystem.store_dir().."chat_translator//") -configfile = io.open(filesystem.store_dir().."chat_translator//config.txt", "w+") -configfile:write("colorselec = "..colorselec..string.char(10)..'teamchatlabel = "'..util.get_label_text("MP_CHAT_TEAM")..'"'..string.char(10)..'allchatlabel = "'..util.get_label_text("MP_CHAT_ALL")..'"') -configfile:close() -colorselec = 1 -else -configfile = io.open(filesystem.store_dir().."chat_translator//config.txt") -configfiledata = configfile:read("*all") -configfile:close() -load(configfiledata)() -end - -util.ensure_package_is_installed("lua/ScaleformLib") -local sfchat = require("lib.ScaleformLib")("multiplayer_chat") -sfchat:draw_fullscreen() - -local Languages = { -{ Name = "Afrikaans", Key = "af" }, -{ Name = "Albanian", Key = "sq" }, -{ Name = "Arabic", Key = "ar" }, -{ Name = "Azerbaijani", Key = "az" }, -{ Name = "Basque", Key = "eu" }, -{ Name = "Belarusian", Key = "be" }, -{ Name = "Bengali", Key = "bn" }, -{ Name = "Bulgarian", Key = "bg" }, -{ Name = "Catalan", Key = "ca" }, -{ Name = "Chinese Simplified", Key = "zh-cn" }, -{ Name = "Chinese Traditional", Key = "zh-tw" }, -{ Name = "Croatian", Key = "hr" }, -{ Name = "Czech", Key = "cs" }, -{ Name = "Danish", Key = "da" }, -{ Name = "Dutch", Key = "nl" }, -{ Name = "English", Key = "en" }, -{ Name = "Esperanto", Key = "eo" }, -{ Name = "Estonian", Key = "et" }, -{ Name = "Filipino", Key = "tl" }, -{ Name = "Finnish", Key = "fi" }, -{ Name = "French", Key = "fr" }, -{ Name = "Galician", Key = "gl" }, -{ Name = "Georgian", Key = "ka" }, -{ Name = "German", Key = "de" }, -{ Name = "Greek", Key = "el" }, -{ Name = "Gujarati", Key = "gu" }, -{ Name = "Haitian Creole", Key = "ht" }, -{ Name = "Hebrew", Key = "iw" }, -{ Name = "Hindi", Key = "hi" }, -{ Name = "Hungarian", Key = "hu" }, -{ Name = "Icelandic", Key = "is" }, -{ Name = "Indonesian", Key = "id" }, -{ Name = "Irish", Key = "ga" }, -{ Name = "Italian", Key = "it" }, -{ Name = "Japanese", Key = "ja" }, -{ Name = "Kannada", Key = "kn" }, -{ Name = "Korean", Key = "ko" }, -{ Name = "Latin", Key = "la" }, -{ Name = "Latvian", Key = "lv" }, -{ Name = "Lithuanian", Key = "lt" }, -{ Name = "Macedonian", Key = "mk" }, -{ Name = "Malay", Key = "ms" }, -{ Name = "Maltese", Key = "mt" }, -{ Name = "Norwegian", Key = "no" }, -{ Name = "Persian", Key = "fa" }, -{ Name = "Polish", Key = "pl" }, -{ Name = "Portuguese", Key = "pt" }, -{ Name = "Romanian", Key = "ro" }, -{ Name = "Russian", Key = "ru" }, -{ Name = "Serbian", Key = "sr" }, -{ Name = "Slovak", Key = "sk" }, -{ Name = "Slovenian", Key = "sl" }, -{ Name = "Spanish", Key = "es" }, -{ Name = "Swahili", Key = "sw" }, -{ Name = "Swedish", Key = "sv" }, -{ Name = "Tamil", Key = "ta" }, -{ Name = "Telugu", Key = "te" }, -{ Name = "Thai", Key = "th" }, -{ Name = "Turkish", Key = "tr" }, -{ Name = "Ukrainian", Key = "uk" }, -{ Name = "Urdu", Key = "ur" }, -{ Name = "Vietnamese", Key = "vi" }, -{ Name = "Welsh", Key = "cy" }, -{ Name = "Yiddish", Key = "yi" }, -} - -local LangKeys = {} -local LangName = {} -local LangIndexes = {} -local LangLookupByName = {} -local LangLookupByKey = {} -local PlayerSpooflist = {} -local PlayerSpoof = {} - -for i=1,#Languages do -local Language = Languages[i] -LangKeys[i] = Language.Name -LangName[i] = Language.Name -LangIndexes[Language.Key] = i -LangLookupByName[Language.Name] = Language.Key -LangLookupByKey[Language.Key] = Language.Name -end - -table.sort(LangKeys) - -function encode(text) -return string.gsub(text, "%s", "+") -end -function decode(text) -return string.gsub(text, "%+", " ") -end - -local maxpl = addict.list(Net_Shit, "Max Players To 32") - -addict.slider(maxpl, "Max Players To 32", {"maxplayers"}, "Set the maximum number of players in a session (only works when you are the host)", 1, 32, 32, 1, function (value) -if Stand_internal_script_can_run then -NETWORK.NETWORK_SESSION_SET_MATCHMAKING_GROUP_MAX(0, value) -util.toast("Slots are now free :)") -end -end) - -addict.slider(maxpl, "Max Spectators", {"maxSpectators"}, "Set the maximum number of observers (only works when you are the host)", 0, 2, 2, 1, function (value) -if Stand_internal_script_can_run then -NETWORK.NETWORK_SESSION_SET_MATCHMAKING_GROUP_MAX(4, value) -util.toast("Slots are now free :)") -end -end) - -local chat_trans = addict.list(Net_Shit, "Chat Translator") - -settingtrad = addict.list(chat_trans, "Settings for traduction") -colortradtrad = addict.list(chat_trans, "PLayer name color") -addict.on_focus(colortradtrad, function() -util.yield(50) -isfocused = false -end) -selectaddict = addict.action(colortradtrad, "Selectioned : ".."Color : "..colorselec, {}, "this will be saved to a config file", function() -addict.focus(focusref[tonumber(colorselec)]) -end) -addict.on_focus(selectaddict, function() -util.yield(50) -isfocused = false -end) -for i = 1, 234 do -focusref[i] = addict.action(colortradtrad, "Color : "..i, {}, "this will be saved to a config file", function() -addict.set_addict_name(selectaddict, "Selectioned : ".."Color : "..i) -colorselec = i -save() -end) -addict.on_focus(focusref[i], function() -isfocused = false -util.yield(50) -isfocused = true -while isfocused do -if not addict.is_open() then -isfocused = false -end -ptr1 = memory.alloc() -ptr2 = memory.alloc() -ptr3 = memory.alloc() -ptr4 = memory.alloc() -HUD.GET_HUD_COLOUR(i, ptr1, ptr2, ptr3, ptr4) -directx.draw_text(0.5, 0.5, "exemple", 5, 0.75, {r = memory.read_int(ptr1)/255, g = memory.read_int(ptr2)/255, b =memory.read_int(ptr3)/255, a= memory.read_int(ptr4)/255}, true) -util.yield() -end -end) -end - - -addict.text_input(settingtrad, "Custom label for ["..string.upper(util.get_label_text("MP_CHAT_TEAM")).."] translation message", {"labelteam"}, "leaving it blank will revert it to the original label", function(s, click_type) -if (s == "") then -teamchatlabel = util.get_label_text("MP_CHAT_TEAM") -else -teamchatlabel = s -end -if not (click_type == 4) then -save() -end -end) -if not (teamchatlabel == util.get_label_text("MP_CHAT_TEAM")) then -addict.trigger_commands("labelteam "..teamchatlabel) -end - - -addict.text_input(settingtrad, "Custom label for ["..string.upper(util.get_label_text("MP_CHAT_ALL")).."] translation message", {"labelall"}, "leaving it blank will revert it to the original label", function(s, click_type) -if (s == "") then -allchatlabel = util.get_label_text("MP_CHAT_ALL") -else -allchatlabel = s -end -if not (click_type == 4) then -save() -end -end) -if not (teamchatlabel == util.get_label_text("MP_CHAT_TEAM")) then -addict.trigger_commands("labelall "..allchatlabel) -end - -targetlangaddict = addict.slider_text(chat_trans, "Target Language", {}, "You need to click to aply change", LangName, function(s) -targetlang = LangLookupByName[LangKeys[s]] -end) - -tradlocaaddict = addict.slider_text(settingtrad, "Location of Traducted Message", {}, "You need to click to aply change", {"Global Chat networked", "Global Chat not networked", "Team Chat not networked", "Team Chat networked", "notification"}, function(s) -Tradloca = s -end) - -traductself = false -addict.toggle(settingtrad, "Traduct Yourself", {}, "", function(on) -traductself = on -end) -traductsamelang = false -addict.toggle(settingtrad, "Traduct even if the language is the same as the desired one", {}, "might not work correctly because google is dumb", function(on) -traductsamelang = on -end) -oldway = false -addict.toggle(settingtrad, "Use the old method", {}, players.get_name(players.user()).." [ALL] player_sender : their message", function(on) -oldway = on -end) -traduct = false -addict.toggle(chat_trans, "Translator On/Off", {}, "", function(on) -traduct = on -end, false) - -traductmymessage = addict.list(chat_trans, "Send Traducted message") -finallangaddict = addict.slider_text(traductmymessage, "Final Language", {"finallang"}, "Final Languge of your message. You need to click to aply change", LangName, function(s) -targetlangmessagesend = LangLookupByName[LangKeys[s]] -end) - -addict.action(traductmymessage, "Send Message", {"Sendmessage"}, "Input the text For your message", function(on_click) -util.toast("Please input your message") -addict.show_command_box("Sendmessage ") -end, function(on_command) -mytext = on_command -async_http.init("translate.googleapis.com", "/translate_a/single?client=gtx&sl=auto&tl="..targetlangmessagesend.."&dt=t&q="..encode(mytext), function(Sucess) -if Sucess ~= "" then -translation, original, sourceLang = Sucess:match("^%[%[%[\"(.-)\",\"(.-)\",.-,.-,.-]],.-,\"(.-)\"") -for _, pId in ipairs(players.list()) do -chat.send_targeted_message(pId, players.user(), string.gsub(translation, "%+", " "), false) -end -end -end) -async_http.dispatch() -end) -botsend = false -chat.on_message(function(packet_sender, message_sender, text, team_chat) -if not botsend then -if not traductself and (packet_sender == players.user()) then -else -if traduct then -async_http.init("translate.googleapis.com", "/translate_a/single?client=gtx&sl=auto&tl="..targetlang.."&dt=t&q="..encode(text), function(Sucess) -if Sucess ~= "" then -translation, original, sourceLang = Sucess:match("^%[%[%[\"(.-)\",\"(.-)\",.-,.-,.-]],.-,\"(.-)\"") -if not traductsamelang and (sourceLang == targetlang)then - -else -if oldway then -sender = players.get_name(players.user()) -translationtext = players.get_name(packet_sender).." : "..decode(translation) -colorfinal = 1 -else -sender = players.get_name(packet_sender) -translationtext = decode(translation) -colorfinal = colorselec -end -if (Tradloca == 1) then -sfchat.ADD_MESSAGE(sender, translationtext, teamchatlabel, false, colorfinal) -end if (Tradloca == 2) then - botsend = true - chat.send_message(players.get_name(packet_sender).." : "..decode(translation), true, false, true) - sfchat.ADD_MESSAGE(sender, translationtext, teamchatlabel, false, colorfinal) - end if (Tradloca == 3) then - sfchat.ADD_MESSAGE(sender, translationtext, allchatlabel, false, colorfinal) - end if (Tradloca == 4) then - botsend = true - chat.send_message(players.get_name(packet_sender).." : "..decode(translation), false, false, true) - sfchat.ADD_MESSAGE(sender, translationtext, allchatlabel, false, colorfinal) - end if (Tradloca == 5) then - util.toast(players.get_name(packet_sender).." : "..decode(translation), TOAST_ALL) - end - end - end - end) - async_http.dispatch() -end -end -end -botsend = false -end) - - -run = 0 -while run<10 do -Tradloca = addict.get_value(tradlocaaddict) -targetlangmessagesend = LangLookupByName[LangKeys[addict.get_value(finallangaddict)]] -targetlang = LangLookupByName[LangKeys[addict.get_value(targetlangaddict)]] -util.yield() -run = run+1 -end - -addict.action(detections,"Check Stats", {"check stats"}, "Weak",function(on) -for pid = 0, 31 do -local rp = players.get_rank(pid) -local money = players.get_money(pid) -local kd = players.get_kd(pid) -if rp == 120 or rp == 720 or rp >= 1000 then -end -if money >= 500000000 then -end -if kd <= -1 or kd >= 50 then -end -end -end) - -faketype = addict.list(Net_Shit, "Spoof Typing indicator", {}, "", function(); end) - -addict.action(faketype, "Start Fake Typing", {}, "Will show a typing indicator above your nickname and also make other addicts think that you're typing in chat", function() -addict.trigger_commands("hidetyping off") -for pids = 0, 31 do -if players.exists(pids) and pids ~= players.user() then -send_script_event(se.startfaketyping, pids, {players.user(), pids, 6769}) -end -end -end) - -addict.action(faketype, "Stop Fake Typing", {}, "", function() -for pids = 0, 31 do -if players.exists(pids) and pids ~= players.user() then -send_script_event(se.stopfaketyping, pids, {players.user(), pids, 7556}) -end -end -end) - -addict.toggle(faketype, "Anti-Type", {}, "AKA 'Suppress Typing Indicator', hides the fact that you're typing", function(on) -if on then -addict.trigger_commands("hidetyping on") -else -addict.trigger_commands("hidetyping off") -end -end) - -addict.toggle_loop(Net_Shit, "Clear All Notifications", {"clearnotifs"}, "I recommend you use nextConsole Script made by lance so you can see the log on screen when people try to crash you with this enabled.", function() -Clear_Stand_Notifs = addict.ref_by_path("Stand>Clear Notifications") -Clear_Minimap_Notifs = addict.ref_by_path("Game>Remove Notifications Above Minimap") -addict.trigger_command(Clear_Stand_Notifs) -addict.trigger_command(Clear_Minimap_Notifs) -util.yield(1000) -end) - -addict.toggle_loop(Net_Shit, "Accept Joins & Transaction Errors!", {"accepterrors"}, "Automatically accept join screens and transaction errors.", function() -local mess_hash = HUD.GET_WARNING_SCREEN_MESSAGE_HASH() -if mess_hash == -896436592 then -util.toast("This player left the session.") -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1) -elseif mess_hash == 1575023314 then -util.toast("Session timeout.") -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1) -elseif mess_hash == 1446064540 then -util.toast("You are already in the session.") -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1) --- transaction error join session join session leave session leave online -elseif mess_hash == -991495373 or mess_hash == -587688989 or mess_hash == 15890625 or mess_hash == 99184332 or mess_hash == 1246147334 then -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1) -elseif mess_hash ~= 0 then -util.toast(mess_hash, TOAST_CONSOLE) -end -util.yield() -end) - -addict.toggle_loop(Net_Shit, "Accept Joins", {"autojoin"}, "Automatically accept join screens reliably.", function() -local message_hash = HUD.GET_WARNING_SCREEN_MESSAGE_HASH() -if message_hash == 15890625 or message_hash == -398982408 or message_hash == -587688989 then -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1.0) -util.yield(200) -end -end, true) - -menu.toggle_loop(Net_Shit, "Auto Host", {"autohost"}, "Great for basic and regular users.", function() -- Credits to funmenu -if not (players.get_host() == PLAYER.PLAYER_ID()) and not util.is_session_transition_active() then -if not (PLAYER.GET_PLAYER_NAME(players.get_host()) == "**Invalid**") then -menu.trigger_commands("kick"..PLAYER.GET_PLAYER_NAME(players.get_host())) -util.yield(200) -end -end -end) - -addict.toggle_loop(Net_Shit, "Auto Enter", {"autoenter"}, "Automatically hits enter.", function() -HUD.GET_WARNING_SCREEN_MESSAGE_HASH() -PAD.SET_CONTROL_VALUE_NEXT_FRAME(2, 201, 1.0) -util.yield(100) -end) - -players.dispatch_on_join() - -addict.toggle(Net_Shit, "Stand User Identification", {}, "Identifies other Stand users but also allows them to identify you.", function(on_toggle) -local standid = addict.ref_by_path("Online>Protections>Detections>Stand User Identification") -if on_toggle then -addict.trigger_command(standid, "on") -else -addict.trigger_command(standid, "off") -end -end) - -addict.toggle_loop(Net_Shit, 'Increase Kosatka Missile Range', {'krange'}, 'You can use it anywhere in the map now', function () -if util.is_session_started() then -memory.write_float(memory.script_global(glob.base + 30176), 200000.0) -end -end) - ---[[ -joining_log = false -joining_toast = false - -addict.toggle(Net_Shit, "Join/leave notifications", {}, "", function(on_toggle) -if on_toggle then -joining_log = true -joining_toast = true -else -joining_log = false -joining_toast = false -end -end) - -players.on_join(function(pid) -while true do ---if joining_toast then --- util.log(PLAYER.GET_PLAYER_NAME(pid) .. " joined") ---end ---if joining_log then --- util.toast(PLAYER.GET_PLAYER_NAME(pid) .. " joined") ---end -util.yield() -end -end) - -players.on_leave(function(pid) -while true do ---if leave_toast then --- util.log(PLAYER.GET_PLAYER_NAME(pid) .. " left") ---end ---if leave_log then --- util.toast(PLAYER.GET_PLAYER_NAME(pid) .. " left") ---end -util.yield() -end -end) -]] - -local InitialPlayersList = players.list(true, true, true) -- Obtain list of players from Stand API -for i=1, #InitialPlayersList do -- Loop through the received player list -GenerateFeatures(InitialPlayersList[i]) -- Generate Features for every player -end -InitialPlayersList = nil - -players.on_join(function(pid) -while true do -util.yield() -end -end) - -players.on_join(GenerateFeatures) -players.on_leave(update_leave) -players.on_join(update_join) - - --- for car drifting -util.create_thread(function() -while true do -if drift then -local veh = entities.get_user_vehicle_as_handle() -if veh then - if PAD.IS_CONTROL_PRESSED(1, 61) then - VEHICLE.SET_VEHICLE_REDUCE_GRIP(veh, true) - else - VEHICLE.SET_VEHICLE_REDUCE_GRIP(veh, false) - end -end -end -util.yield() -end -end) - - - ---for oppressor blacklist -util.create_thread(function() -while true do -if oppressor_kick_players then -local cur_players = players.list(target_self,target_friends,true) -for k,v in pairs(cur_players) do - local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(v) - local vehicle = PED.GET_VEHICLE_PED_IS_IN(ped, false) - if vehicle then - local hash = util.joaat("oppressor2") - if VEHICLE.IS_VEHICLE_MODEL(vehicle, hash) then - addict.trigger_commands("vehkick" .. PLAYER.GET_PLAYER_NAME(v)) - if lock_vehicle then - VEHICLE.SET_VEHICLE_DOORS_LOCKED_FOR_ALL_PLAYERS(vehicle, true) - end - end - end -end -end -util.yield() -end -end) - ---for lazer blacklist -util.create_thread(function() -while true do -if lazer_kick_players then -local cur_players = players.list(target_self,target_friends,true) -for k,v in pairs(cur_players) do - local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(v) - local vehicle = PED.GET_VEHICLE_PED_IS_IN(ped, false) - if vehicle then - local hash = util.joaat("lazer") - if VEHICLE.IS_VEHICLE_MODEL(vehicle, hash) then - addict.trigger_commands("vehkick" .. PLAYER.GET_PLAYER_NAME(v)) - if lock_vehicle then - VEHICLE.SET_VEHICLE_DOORS_LOCKED_FOR_ALL_PLAYERS(vehicle, true) - end - end - end -end -end -util.yield() -end -end) - ---for kosatka blacklist -util.create_thread(function() -while true do -if kosatka_kick_players then -local cur_players = players.list(target_self,target_friends,true) -for k,v in pairs(cur_players) do - local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(v) - local vehicle = PED.GET_VEHICLE_PED_IS_IN(ped, false) - if vehicle then - local hash = util.joaat("kosatka") - if VEHICLE.IS_VEHICLE_MODEL(vehicle, hash) then - addict.trigger_commands("vehkick" .. PLAYER.GET_PLAYER_NAME(v)) - if lock_vehicle then - VEHICLE.SET_VEHICLE_DOORS_LOCKED_FOR_ALL_PLAYERS(vehicle, true) - end - end - end -end -end -util.yield() -end -end) - ---for hydra blacklist -util.create_thread(function() -while true do -if hydra_kick_players then -local cur_players = players.list(target_self,target_friends,true) -for k,v in pairs(cur_players) do - local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(v) - local vehicle = PED.GET_VEHICLE_PED_IS_IN(ped, false) - if vehicle then - local hash = util.joaat("hydra") - if VEHICLE.IS_VEHICLE_MODEL(vehicle, hash) then - addict.trigger_commands("vehkick" .. PLAYER.GET_PLAYER_NAME(v)) - if lock_vehicle then - VEHICLE.SET_VEHICLE_DOORS_LOCKED_FOR_ALL_PLAYERS(vehicle, true) - end - end - end -end -end -util.yield() -end -end) - ---for khanjali blacklist -util.create_thread(function() -while true do -if khanjali_kick_players then -local cur_players = players.list(target_self,target_friends,true) -for k,v in pairs(cur_players) do - local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(v) - local vehicle = PED.GET_VEHICLE_PED_IS_IN(ped, false) - if vehicle then - local hash = util.joaat("khanjali") - if VEHICLE.IS_VEHICLE_MODEL(vehicle, hash) then - addict.trigger_commands("vehkick" .. PLAYER.GET_PLAYER_NAME(v)) - if lock_vehicle then - VEHICLE.SET_VEHICLE_DOORS_LOCKED_FOR_ALL_PLAYERS(vehicle, true) - end - end - end -end -end -util.yield() -end -end) - -sexscript = addict.list(funfun, "Animation Script", {}, "", function(); end) - -SCRIPT_SOURCE = "REPO" -SCRIPT_BRANCH = "release" -BRANCH_LAST_COMMIT = "d26731ac7ca2bf1339315b3eb8d5f26b378691f3" -SCRIPT_BRANCH_IDS = {"jackzscript","master","release"} -SCRIPT_BRANCH_NAMES = {{"jackzscript"},{"dev"},{"release"}} --- END AUTOGENERATED CODE -- - --- Actions --- Created By Jackz --- SOURCE CODE: https://github.com/Jackzmc/lua-scripts -SCRIPT = "actions" -VERSION = "1.10.10" -ANIMATIONS_DATA_FILE = filesystem.resources_dir() .. "/addict_actions/animations.txt" -ANIMATIONS_DATA_FILE_VERSION = "1.0" -SPECIAL_ANIMATIONS_DATA_FILE_VERSION = "1.0.0" -- target version of addict_action - - --- TEMPLATE: release/log.lua -- -Log = {} -if SCRIPT_DEBUG == nil then -SCRIPT_DEBUG = false -end -function Log._log(prefix, ...) -mod = debug.getinfo(3, "n").name or debug.getinfo(4, "n").name or "_anon_func" -msg = "" -for _, a in ipairs(...) do -if a == nil then a = "" end -if type(a) == "table" then a = dumpTable(a) end -msg = msg .. tostring(a) .. "\t" -end -if prefix then prefix = "[" .. prefix .. "] " -else prefix = "" end -util.log(string.format("%s%s:%s/%s: %s", prefix, SCRIPT_NAME, SCRIPT_SOURCE or "DEV", mod, msg)) -end -function Log.debug(...) -if SCRIPT_DEBUG then -arg = {...} -Log._log("debug", arg) -end -end -function Log.debugTable(table) -if SCRIPT_DEBUG then -mod = debug.getinfo(3, "n").name or debug.getinfo(4, "n").name or "_anon_func" -util.log(string.format("%s:%s/%s: %s", SCRIPT_NAME, SCRIPT_SOURCE or "DEV", mod, dumpTable(table))) -end -end -function Log.warn(...) -arg = {...} -Log._log("Warn", arg) -end -function Log.error(...) -arg = {...} -Log._log("Error", arg) -end -function Log.severe(...) -arg = {...} -Log._log("Severe", arg) -util.stop_script() -end -function Log.log(...) -arg = {...} -Log._log(nil, arg) -end - -function dumpTable(o) -if type(o) == 'table' then -s = '{ ' -for k,v in pairs(o) do - if type(k) ~= 'number' then k = '"'..k..'"' end - s = s .. '['..k..'] = ' .. dumpTable(v) .. ',' -end -return s .. '} ' -elseif type(o) == "string" then -return '"' .. o .. "'" -else -return tostring(o) -end -end --- END TEMPLATE -- --- TEMPLATE: release/repo.lua -- -function download_resources_update(filepath, destOverwritePath) -lockPath = filesystem.scripts_dir() .. "/lib/" .. filepath .. ".lock" -if filesystem.exists(lockPath) then -util.log(SCRIPT_NAME .. ": Skipping resource update \" .. lib .. \", found update lockfile") -end -lock = io.open(lockPath, "w") -if lock == nil then -util.toast(SCRIPT_NAME .. ": Could not create lockfile, skipping update", TOAST_ALL) -return -end -lock:close() -async_http.init("jackz.me", "/stand/get-lua.php?script=resources/" .. filepath .. "&source=" .. SCRIPT_SOURCE .. "&branch=" .. (SCRIPT_BRANCH or "master"), function(result, res_headers, status_code) -os.remove(lockPath) -if status_code ~= 200 or result:startswith("<") then -util.toast("Resource returned invalid response for \"" .. filepath .. "\"\nSee logs for details") -util.log(string.format("%s: Resource \"%s\" returned: %s", SCRIPT_NAME, filepath, result)) -return -end -file = io.open(filesystem.resources_dir() .. (destOverwritePath or filepath), "w") -if file == nil then -util.toast("Could not write resource file for: " .. filepath .. "\nSee logs for details") -util.log(string.format("%s: Resource \"%s\" file could not be created.", SCRIPT_NAME, filepath)) -return -end -Log.log("Updated resource ", filepath, "for", SCRIPT_NAME, "to branch", SCRIPT_BRANCH or "master") -file:write(result:gsub("\r", "") .. "\n") -file:close() -util.toast(SCRIPT .. ": Automatically updated resource '" .. filepath .. "'") -end, function(e) -os.remove(lockPath) -util.toast(SCRIPT .. " cannot load: Library files are missing. (" .. filepath .. ")", 10) -util.stop_script() -end) -async_http.dispatch() -end - --- END TEMPLATE -- --- TEMPLATE: release/common.lua -- --- People keep trying to run stuff on non-stand -if not filesystem.stand_dir then -print("Unsupported. Only stand is supported") -return -end ----------------------------------------------------------------- --- Version Check -function get_version_info(version) -if not version then error("Missing version", 2) end -major, minor, patch = version:match("(%d+)%.(%d+)%.(%d+)") -return { -major = tonumber(major) or 0, -minor = tonumber(minor) or 0, -patch = tonumber(patch) or 0 -} -end -function compare_version(a, b) -av = get_version_info(a) -bv = get_version_info(b) -if not av or not bv then error("Missing versions to compare") end -if av.major > bv.major then return 1 -elseif av.major < bv.major then return -1 -elseif av.minor > bv.minor then return 1 -elseif av.minor < bv.minor then return -1 -elseif av.patch > bv.patch then return 1 -elseif av.patch < bv.patch then return -1 -else return 0 end -end -if SCRIPT_BRANCH and SCRIPT_BRANCH == "release" then -VERSION_FILE_PATH = filesystem.store_dir() .. "jackz_versions.txt" -if not filesystem.exists(VERSION_FILE_PATH) then -versionFile = io.open(VERSION_FILE_PATH, "w") -if versionFile then - versionFile:close() -end -end -versionFile = io.open(VERSION_FILE_PATH, "r+") -if versionFile then -versions = {} -for line in versionFile:lines("l") do - script, version = line:match("(%g+): (%g+)") - if script then - versions[script] = version - end -end -if versions[SCRIPT_NAME] == nil or compare_version(VERSION, versions[SCRIPT_NAME]) == 1 then - if versions[SCRIPT_NAME] ~= nil then - async_http.init("jackz.me", "/stand/changelog.php?raw=1&script=" .. SCRIPT_NAME .. "&since=" .. versions[SCRIPT_NAME] .. "&branch=" .. (SCRIPT_BRANCH or "master"), function(result) - util.toast("Changelog for " .. SCRIPT_NAME .. " version " .. VERSION .. ":\n" .. result) - end, function() util.log(SCRIPT_NAME ..": Could not get changelog") end) - async_http.dispatch() - end - versions[SCRIPT_NAME] = VERSION - versionFile:seek("set", 0) - versionFile:write("# DO NOT EDIT ! File is used for changelogs\n") - for script, version in pairs(versions) do - versionFile:write(script .. ": " .. version .. "\n") - end -end -versionFile:close() -else -util.log(SCRIPT_NAME .. ": Failed to access to version file") -end -end --- END Version Check ------------------------------------------------------------------- -function show_busyspinner(text) -HUD.BEGIN_TEXT_COMMAND_BUSYSPINNER_ON("STRING") -HUD.ADD_TEXT_COMPONENT_SUBSTRING_PLAYER_NAME(text) -HUD.END_TEXT_COMMAND_BUSYSPINNER_ON(2) -end - -SCRIPT_META_LIST = addict.list(sexscript, "Script Meta") -addict.divider(SCRIPT_META_LIST, SCRIPT_NAME .. " V" .. VERSION) -addict.hyperlink(SCRIPT_META_LIST, "View full changelog", "https://jackz.me/stand/changelog?html=1&reverse=1&script=" .. SCRIPT_NAME) -addict.hyperlink(SCRIPT_META_LIST, "Jackz's Guilded", "https://www.guilded.gg/i/k8bMDR7E?cid=918b2f61-989c-41c4-ba35-8fd0e289c35d&intent=chat", "Get help, submit suggestions, report bugs, or be with other users of my scripts") -addict.hyperlink(SCRIPT_META_LIST, "Github Source", "https://github.com/Jackzmc/lua-scripts", "View all my lua scripts on github") -if SCRIPT_SOURCE == "MANUAL" then -addict.list_select(SCRIPT_META_LIST, "Release Channel", {SCRIPT_NAME.."channel"}, "Sets the release channel for updates for this script.\nChanging the channel from release may result in bugs.", SCRIPT_BRANCH_NAMES, 1, function(index, name) -show_busyspinner("Downloading update...") -download_script_update(SCRIPT_BRANCH_IDS[index], function() -HUD.BUSYSPINNER_OFF() -util.log(SCRIPT_NAME .. ": Released channel changed to " .. SCRIPT_BRANCH_IDS[index]) -util.toast("Release channel changed to " .. name .. " (" .. SCRIPT_BRANCH_IDS[index] .. ")\nReload to apply changes") -end, function() -util.toast("Failed to download latest version for release channel.") -end) -end) -else -addict.readonly(SCRIPT_META_LIST, "Release Channel", "Use the manual version from https://jackz.me/stand/get-latest-zip to change the release channel.") -end -if _lang ~= nil then -addict.hyperlink(SCRIPT_META_LIST, "Help Translate", "https://jackz.me/stand/translate/?script=" .. SCRIPT, "If you wish to help translate, this script has default translations fed via google translate, but you can edit them here:\nOnce you make changes, top right includes a save button to get a -CHANGES.json file, send that my way.") -_lang.add_language_selector_to_addict(SCRIPT_META_LIST) -end -addict.readonly(SCRIPT_META_LIST, "Build Commit", BRANCH_LAST_COMMIT and BRANCH_LAST_COMMIT:sub(1,10) or "Dev Build") -addict.action(SCRIPT_META_LIST, "Upload Logs", {}, "Uploads the last ~20 lines of your stand log (%appdata%\\Stand\\Log.txt) to hastebin.com.\nHastebin posts expire in upto 7 days.\n\nUploaded log can be accessed from \"Open Uploaded Log\" button below once pressed", function() -logs = io.open(filesystem.stand_dir() .. "Log.txt", "r") -if logs then -show_busyspinner("Uploading logs....") -async_http.init("hastebin.com", "/documents", function(body) -HUD.BUSYSPINNER_OFF() -url = "https://hastebin.com/" .. body:sub(9, -3) -util.toast("Uploaded: " .. url) -addict.hyperlink(SCRIPT_META_LIST, "Open Uploaded Log", url) -end, function() -util.toast("Failed to submit logs, network error") -HUD.BUSYSPINNER_OFF() -end) -logs:seek("end", -3072) -content = logs:read("*a") -async_http.set_post("text/plain", -string.format("Script: %s\nSource: %s\nBranch: %s\nVersion: %s\nCommit: %s\n%s", SCRIPT_NAME, SCRIPT_SOURCE or "UNK", SCRIPT_BRANCH or "UNK", VERSION or "UNK", BRANCH_LAST_COMMIT or "DEV BUILD", content) -) -async_http.dispatch() -logs:close() -else -util.toast("Could not read your stand log file") -end -end) - -SCRIPT_DEBUG = SCRIPT_SOURCE == nil - -function try_require(name, isOptional) -status, data = pcall(require, name) -if status then -return data -else -if data then - util.toast(name .. ": " .. data, TOAST_ALL) -end -if SCRIPT_SOURCE == "REPO" then - if isOptional then - Log.debug("Missing optional dependency: " .. name) - else - util.toast("Missing a required depencency (\"" .. name .. "\"). Please install this from the repo > dependencies list") - Log.severe("Missing required dependency:", name) - end -elseif download_lib_update then - lockPath = download_lib_update(name, function() - Log.log("Downloaded ", isOptional and "optional" or "required", "library:", name) - end) - while filesystem.exists(lockPath) do - util.yield(500) - end - return require(name) -end -return nil -end -end --- END TEMPLATE -- - -if metaList then -addict.divider(metaList, "-- Credits --") -addict.hyperlink(metaList, "dpemotes", "https://github.com/andristum/dpemotes/", "For the special animations section, code was modified from repository") -end - --- Iterates in consistent order a Key/Value -function pairsByKeys(t, f) -a = {} -for n in pairs(t) do -table.insert(a, n) -end -table.sort(a, f) -i = 0 -- iterator variable -iter = function() --- iterator function -i = i + 1 -if a[i] == nil then -return nil -else -return a[i], t[a[i]] -end -end -return iter -end -status = pcall(require, 'resources/addict_actions/addict_action') -if not status then -util.toast("Failed to load resource file: addict_actions/addict_action.lua") -util.stop_script() -end -if ANIMATION_DATA_VERSION ~= SPECIAL_ANIMATIONS_DATA_FILE_VERSION then -if SCRIPT_SOURCE == "MANUAL" then -download_resources_update("addict_actions/addict_action.min.lua", "addict_actions/addict_action.lua") -util.toast("Restart script to use updated resource file") -else -util.toast("addict_actions: Warn: Outdated or missing addict_action. Version: " .. (ANIMATION_DATA_VERSION or "")) -util.stop_script() -end -end - --- Messy Globals -scenarioCount = 0 - -clearActionImmediately = true -favorites = {} -favoritesActions = {} -recents = {} -animFlags = AnimationFlags.ANIM_FLAG_REPEAT | AnimationFlags.ANIM_FLAG_ENABLE_PLAYER_CONTROL -allowControl = true -affectType = 0 ------------------------ --- SCENARIOS ----------------------- - -addict.action(sexscript, "Stop All Actions", {"stopself"}, "Stops the current scenario or animation", function(v) -clear_anim_props() -ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(players.user()) -if clearActionImmediately then -TASK.CLEAR_PED_TASKS_IMMEDIATELY(ped) -else -TASK.CLEAR_PED_TASKS(ped) -end -if affectType > 0 then -peds = entities.get_all_peds_as_handles() -for _, npc in ipairs(peds) do -if not PED.IS_PED_A_PLAYER(npc) and not PED.IS_PED_IN_ANY_VEHICLE(npc, true) then -NETWORK.NETWORK_REQUEST_CONTROL_OF_ENTITY(npc) -if clearActionImmediately then - TASK.CLEAR_PED_TASKS_IMMEDIATELY(npc) -else - TASK.CLEAR_PED_TASKS(npc) -end -end -end -end -end) -addict.toggle(sexscript, "Clear Action Immediately", {"clearimmediately"}, "If enabled, will immediately stop the animation / scenario that is playing when activating a new one. If false, you will transition smoothly to the next action.", function(on) -lclearActionImmediately = on -end, clearActionImmediately) -addict.list_select(sexscript, "Action Targets", {"actiontarget"}, "The entities that will play this action.\n0 = Only yourself\n1 = Only NPCs\n2 = Both you and NPCS", { { "Only yourself" }, { "Only NPCs" }, {"Both you and NPCS"} }, 1, function(index) -affectType = index - 1 -end) - -function onControllablePress(value) -if value then -animFlags = AnimationFlags.ANIM_FLAG_REPEAT | AnimationFlags.ANIM_FLAG_ENABLE_PLAYER_CONTROL -else -animFlags = AnimationFlags.ANIM_FLAG_REPEAT -end -end -function generateAnimationAction(key, data) -return function() -util.toast("Playing anim: " .. data[3] or key) -util.log(string.format("dict=%s anim=%s name=%s", data[1], data[2], data[3])) -play_animation(data[1], data[2], false, data) -end -end - -addict.divider(sexscript, "Stuff") -specialAnimationsaddict = addict.list(sexscript, "Special Animations", {}, "Special animations that can use props") -addict.toggle(specialAnimationsaddict, "Controllable", {"animationcontrollable"}, "Should the animation allow player control?", onControllablePress, allowControl) -animationsaddict = addict.list(sexscript, "Animations", {}, "List of animations you can play") -addict.toggle(animationsaddict, "Controllable", {"animationcontrollable"}, "Should the animation allow player control?", onControllablePress, allowControl) - - -for category, rows in pairsByKeys(SPECIAL_ANIMATIONS) do -cataddict = addict.list(specialAnimationsaddict, category, {}) -for key, data in pairsByKeys(rows) do -addict.action( -cataddict, -data[3] or key, -{"playanim"..key}, -string.format("%s %s\nPlay this animation\nAnimation Id: %s", data[1], data[2], key), -generateAnimationAction(key, data) -) -end -end - - ------------------------ --- ANIMATIONS ----------------------- -animLoaded = false -animAttachments = {} -function clear_anim_props() -for ent, shouldDelete in pairs(animAttachments) do -if shouldDelete then -entities.delete(ent) -else -ENTITY.DETACH_ENTITY(ent, false) -end -end -end -function delete_anim_props() -for ent, _ in pairs(animAttachments) do -entities.delete(ent) -end -end - -animaddictData = {} -resultaddicts = {} -cloudFavoritesaddict = addict.list(animationsaddict, "Cloud Favorites", {}, "View categorized saved favorites from other users, or store your own.") -favoritesaddict = addict.list(animationsaddict, "Favorites", {}, "List of all your favorited animations. Hold SHIFT to add or remove from favorites.") -cloudFavoritesUploadaddict = addict.list(cloudFavoritesaddict, "Upload", {}, "Add your own cloud animation favorites. BETA.") -cloudUploadFromFavorites = addict.list(cloudFavoritesUploadaddict, "From Favorites", {}, "Browse your favorite played animations to upload them", function() populate_cloud_list(true) end) -cloudUploadFromRecent = addict.list(cloudFavoritesUploadaddict, "From Recent", {}, "Browse your recently played animations to upload them", function() populate_cloud_list(false) end) -cloudFavoritesBrowseaddict = addict.list(cloudFavoritesaddict, "Browse", {}, "Browse all uploaded cloud animation favorites") - -cloudUsers = {} -- Record} -cloud_loading = false -function cloudvehicle_fetch_error(code) -return function() -cloud_loading = false -util.toast("An error occurred fetching cloud data. Code: " .. code, TOAST_ALL) -HUD.BUSYSPINNER_OFF() -end -end -cloud_list = {} -function upload_animation(group, animation, alias) -show_busyspinner("Uploading animation") -async_http.init('jackz.me', -string.format( -'/stand/cloud/actions/manage?scname=%s&hash=%d&alias=%s&dict=%s&anim=%s', -SOCIALCLUB._SC_GET_NICKNAME(), -addict.get_activation_key_hash(), -alias or '', -group, -animation -), -function(body) -if body == "OK" then -util.toast("Upload successful for " .. group .. "/" .. animation) -elseif body == "Conflict" then -util.toast("Animation already uploaded") -else -util.toast("Upload failed for " .. group .. "/" .. animation .. ": " .. body) -end -HUD.BUSYSPINNER_OFF() -end -) -async_http.set_post('text/plain', '') -async_http.dispatch() -end -function populate_cloud_list(useFavorites) -listaddict = useFavorites and cloudUploadFromFavorites or cloudUploadFromRecent -tuple = useFavorites and favorites or recents -for _, m in ipairs(cloud_list) do -addict.delete(m) -end -cloud_list = {} -for _, favorite in ipairs(tuple) do -name = favorite[2] --- if favorite[3] then --- name = favorite[3] .. " (" .. favorite[2] .. ")" --- end -action = addict.action(listaddict, name, {}, "Upload the " .. favorite[2] .. " from group " .. favorite[1] .. " to the cloud", function(v) -upload_animation(favorite[1], favorite[2], nil) -end) -table.insert(cloud_list, action) -end -end -function populate_user_dict(user, dictionary) -show_busyspinner("Fetching animations for " .. dictionary) -while cloud_loading do -util.yield() -end -cloud_loading = true -async_http.init('jackz.me', '/stand/cloud/actions/list?method=actions&scname=' .. user .. "&dict=" .. dictionary, function(body) -cloud_loading = false -if body:sub(1, 1) == "<" then -util.toast("Ratelimited, try again in a few seconds.") -addict.divider(cloudUsers[user].categories[dictionary].addict, "Ratelimited, try again in a few seconds") -return -end -for _, animation in ipairs(cloudUsers[user].categories[dictionary].animations) do -pcall(addict.delete, animation) -end -cloudUsers[user].categories[dictionary].animations = {} -count = 0 -for animation in string.gmatch(body, "[^\r\n]+") do -count = count + 1 -action = addict.action(cloudUsers[user].categories[dictionary].addict, animation, {}, dictionary .. " " .. animation, function(_) -play_animation(dictionary, animation) -end) -table.insert(cloudUsers[user].categories[dictionary].animations, action) -end -addict.set_addict_name(cloudUsers[user].categories[dictionary].addict, dictionary .. " (" .. count .. ")") -HUD.BUSYSPINNER_OFF() -end, cloudvehicle_fetch_error("FETCH_USER_ANIMS")) -async_http.dispatch() -end -addict.on_focus(cloudFavoritesBrowseaddict, function() -show_busyspinner("Fetching users") -while cloud_loading do -util.yield() -end -cloud_loading = true -async_http.init('jackz.me', '/stand/cloud/actions/list?method=users', function(body) -cloud_loading = false -if body:sub(1, 1) == "<" then -cloudvehicle_fetch_error("RATELIMITED") -return -end -for user, udata in pairs(cloudUsers) do -pcall(addict.delete, udata.addict) -for dictionary, cdata in pairs(udata.categories) do -pcall(addict.delete, cdata.addict) -for i, animation in ipairs(cdata.animations) do -pcall(addict.delete, animation) -cdata.animations[i] = nil -end -udata.categories[dictionary] = nil -end -cloudUsers[user].addict = nil -end -for user in string.gmatch(body, "[^\r\n]+") do -useraddict = addict.list(cloudFavoritesBrowseaddict, user, {}, "All action categories favorited by " .. user) -cloudUsers[user] = { -addict = useraddict, -categories = {} -} --- TODO: Move from on_focus to on click -addict.on_focus(useraddict, function(_) -show_busyspinner("Fetching dictionaries for " .. user) -while cloud_loading do -util.yield() -end -cloud_loading = true -async_http.init('jackz.me', '/stand/cloud/actions/list?method=dicts&scname=' .. user, function(body) -cloud_loading = false -if body:sub(1, 1) == "<" then -cloudvehicle_fetch_error("RATELIMITED") -return -end -for dictionary, cdata in pairs(cloudUsers[user].categories) do -pcall(addict.delete, cdata.addict) -for animation in ipairs(cdata.animations) do -pcall(addict.delete, animation) -end -end -cloudUsers[user].categories = {} -count = 0 -for dictionary in string.gmatch(body, "[^\r\n]+") do -count = count + 1 -dictaddict = addict.list(useraddict, dictionary, {}, "All actions in " .. dictionary .. " favorited by " .. user, function() populate_user_dict(user, dictionary) end) -cloudUsers[user].categories[dictionary] = { -addict = dictaddict, -animations = {} -} -end -addict.set_addict_name(useraddict, user .. " (" .. count .. ")") -HUD.BUSYSPINNER_OFF() -end, cloudvehicle_fetch_error("FETCH_USER_CATEGORIES")) -async_http.dispatch() -end) -end -HUD.BUSYSPINNER_OFF() -end, cloudvehicle_fetch_error("FETCH_USERS")) -async_http.dispatch() -end) -recentsaddict = addict.list(animationsaddict, "Recents", {}, "List of all your recently played animations") -addict.divider(animationsaddict, "Raw Animations") -searchaddict = addict.list(animationsaddict, "Search", {}, "Search for animation groups") -addict.action(searchaddict, "Search Animation Groups", {"searchanim"}, "Searches all animation groups for the inputted text", function() -addict.show_command_box("searchanim ") -end, function(args) --- Delete existing results -for _, m in ipairs(resultaddicts) do -pcall(addict.delete, m) -end -resultaddicts = {} --- Find all possible groups -results = {} --- loop ANIMATIONS by heading then subheading then insert based on result -if not filesystem.exists(ANIMATIONS_DATA_FILE) then -download_animation_data() -end --- Parse the file -isHeaderRead = false --- Possibly recurse down categories splitting on _ and @ -for line in io.lines(ANIMATIONS_DATA_FILE) do -if isHeaderRead then - -i, j = line:find(args) -if i then -chunks = {} -- [ category, anim ] -for substring in string.gmatch(line, "%S+") do -table.insert(chunks, substring) -end --- Add the distance: -chunks[3] = j - i -table.insert(results, chunks) -end --- TODO: Add back organization to list -else -version = line:sub(2) -if version ~= ANIMATIONS_DATA_FILE_VERSION then -util.toast("Animation data out of date, updating...") -download_animation_data() -end -isHeaderRead = true -end -end --- Sort by distance -table.sort(results, function(a, b) return a[3] > b[3] end) --- Messy, but no way to call a list group, so recreate all animations in a sublist: -for i = 1, 201 do -if results[i] then --- m = addict.list(searchaddict, group, {}, "All animations for " .. group) -m = addict.action(searchaddict, results[i][2], {"animate" .. results[i][1] .. " " .. results[i][2]}, "Plays the " .. results[i][2] .. " animation from group " .. results[i][1], function(v) -play_animation(results[i][1], results[i][2], false) -end) -table.insert(resultaddicts, m) -end -end -end) -browseaddict = addict.list(animationsaddict, "Browse Animations", {}, "WARNING: Will cause a freeze when exiting, stand does not like unloading 15,000 animations. Use search if your pc cannot handle.", function() setup_animation_list() end) -addict.on_focus(browseaddict, function() -if animLoaded then -util.toast("WARN: Unloading animation browse list, prepare for lag.") -util.yield(100) -destroy_animations_data() -end -end) -show_busyspinner("Loading addicts...") - - -scenariosaddict = addict.list(sexscript, "Scenarios", {}, "List of scenarios you can play\nSome scenarios only work on certain genders, example AA Coffee only works on male peds.") -for group, scenarios in pairs(SCENARIOS) do -subaddict = addict.list(scenariosaddict, group, {}, "All " .. group .. " scenarios") -for _, scenario in ipairs(scenarios) do -scenarioCount = scenarioCount + 1 -addict.action(subaddict, scenario[2], {"scenario"}, "Plays the " .. scenario[2] .. " scenario", function(v) -ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(players.user()) - --- Play scenario on all npcs if enabled: -if affectType > 0 then -peds = entities.get_all_peds_as_handles() -for _, npc in ipairs(peds) do -if not PED.IS_PED_A_PLAYER(npc) and not PED.IS_PED_IN_ANY_VEHICLE(npc, true) then -NETWORK.NETWORK_REQUEST_CONTROL_OF_ENTITY(npc) -if clearActionImmediately then - TASK.CLEAR_PED_TASKS_IMMEDIATELY(npc) -end -TASK.TASK_START_SCENARIO_IN_PLACE(npc, scenario[1], 0, true); -end -end -end --- Play scenario on self if enabled: -if affectType == 0 or affectType == 2 then -if clearActionImmediately then -TASK.CLEAR_PED_TASKS_IMMEDIATELY(ped) -end -TASK.TASK_START_SCENARIO_IN_PLACE(ped, scenario[1], 0, true); -end -end) -end -end - -HUD.BUSYSPINNER_OFF() - ------------------------ --- Animation Functions ----------------------- --- Maybe smart deletion but eh -function populate_favorites() -for _, action in ipairs(favoritesActions) do -addict.delete(action) -end -favoritesActions = {} -for _, favorite in ipairs(favorites) do -name = favorite[2] -if favorite[3] then -name = favorite[3] .. " (" .. favorite[2] .. ")" -end -local a -a = addict.action(favoritesaddict, name, {}, "Plays " .. favorite[2] .. " from group " .. favorite[1], function(v) -if PAD.IS_CONTROL_PRESSED(2, 209) then -addict.show_warning(a, 2, "Are you sure you want to remove this animation from your favorites", function() -play_animation(favorite[1], favorite[2], false, nil, true) -end) -else -play_animation(favorite[1], favorite[2], false) -end -end) -table.insert(favoritesActions, a) -end -end - -function is_anim_in_recent(group, anim) -for _, recent in ipairs(recents) do -if recent[1] == group and recent[2] == anim then -return true -end -end -return false -end - -function add_anim_to_recent(group, anim) -if #recents >= 20 then -addict.delete(recents[1][3]) -table.remove(recents, 1) -end -local action = addict.action(recentsaddict, anim, {"animate" .. group .. " " .. anim}, "Plays the " .. anim .. " animation from group " .. group, function(v) -play_animation(group, anim, true) -end) -table.insert(recents, { group, anim, action }) -end -function download_animation_data() -local loading = true -show_busyspinner("Downloading animation data") -async_http.init("jackz.me", "/stand/resources/addict_actions/animations.txt", function(result) -local file = io.open(ANIMATIONS_DATA_FILE, "w") -file:write(result:gsub("\r", "")) -file:close() -util.log(SCRIPT .. ": Downloaded resource file successfully") -HUD.BUSYSPINNER_OFF() -loading = false -end, function() -util.toast(SCRIPT .. ": Failed to automatically download animations data file. Please download latest file manually.") -util.stop_script() -loading = false -end) -async_http.dispatch() -while loading do -util.yield() -end -HUD.BUSYSPINNER_OFF() -end -function destroy_animations_data() -for category, data in pairs(animaddictData) do -pcall(addict.delete, data.list) -end -animaddictData = {} -animLoaded = false -addict.collect_garbage() -end -function setup_category_animations(category) -animaddictData[category].addicts = {} -for _, animation in ipairs(animaddictData[category].animations) do -local action = addict.action(animaddictData[category].list, animation, {"animate" .. category .. " " .. animation}, "Plays the " .. animation .. " animation from group " .. category, function(v) -play_animation(category, animation, false) -end) -table.insert(animaddictData[category].addicts, action) -end -end -function setup_animation_list() -if animLoaded then -return -end --- Download animation file if does not exist -if not filesystem.exists(ANIMATIONS_DATA_FILE) then -download_animation_data() -end --- Parse the file -local isHeaderRead = false --- Possibly recurse down categories splitting on _ and @ -for line in io.lines(ANIMATIONS_DATA_FILE) do -if isHeaderRead then -chunks = {} -- [ category, anim ] -for substring in string.gmatch(line, "%S+") do -table.insert(chunks, substring) -end -if #chunks == 2 then -local category = chunks[1] -if animaddictData[category] == nil then -animaddictData[category] = { - animations = {}, -} -local list = addict.list(browseaddict, category, {}, "", function() setup_category_animations(category) end -, function() -if animaddictData[category].addicts then - for _, m in ipairs(animaddictData[category].addicts) do - pcall(addict.delete, m) - end - animaddictData[category].addicts = nil -end -end) -animaddictData[category].list = list -end -table.insert(animaddictData[chunks[1]].animations, chunks[2]) -end -else -local version = line:sub(2) -if version ~= ANIMATIONS_DATA_FILE_VERSION then -util.toast("Animation data out of date, updating...") -download_animation_data() -end -isHeaderRead = true -end -end -animLoaded = true -end - -function play_animation(group, anim, doNotAddRecent, data, remove) -local flags = animFlags -- Keep legacy animation flags -local duration = -1 -local props -if data ~= nil then -flags = AnimationFlags.ANIM_FLAG_NORMAL -if data.AnimationOptions ~= nil then -if data.AnimationOptions.Loop then -flags = flags | AnimationFlags.ANIM_FLAG_REPEAT -end -if data.AnimationOptions.Controllable then -flags = flags | AnimationFlags.ANIM_FLAG_ENABLE_PLAYER_CONTROL | AnimationFlags.ANIM_FLAG_UPPERBODY -end -if data.AnimationOptions.EmoteDuration then -duration = data.AnimationOptions.EmoteDuration -end -end -if data.AnimationOptions and data.AnimationOptions.Props then -props = data.AnimationOptions.Props -end -end -if remove then -for i, favorite in ipairs(favorites) do -if favorite[1] == group and favorite[2] == anim then -table.remove(favorites, i) -populate_favorites() -save_favorites() -util.toast("Removed " .. group .. "\n" .. anim .. " from favorites") -return -end -end -table.insert(favorites, { group, anim }) -populate_favorites() -save_favorites() -util.toast("Added " .. group .. "\n" .. anim .. " to favorites") -else -clear_anim_props() -STREAMING.REQUEST_ANIM_DICT(group) -while not STREAMING.HAS_ANIM_DICT_LOADED(group) do -util.yield(100) -end -local ped = PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(players.user()) - - -if not is_anim_in_recent(group, anim) and not doNotAddRecent then -add_anim_to_recent(group, anim) -end - --- Play animation on all npcs if enabled: -if affectType > 0 then -local peds = entities.get_all_peds_as_handles() -for _, npc in ipairs(peds) do -if not PED.IS_PED_A_PLAYER(npc) and not PED.IS_PED_IN_ANY_VEHICLE(npc, true) then -_play_animation(npc, group, anim, flags, duration, props) -end -end -end --- Play animation on self if enabled: -if affectType == 0 or affectType == 2 then -_play_animation(ped, group, anim, flags, duration, props) -end -STREAMING.REMOVE_ANIM_DICT(group) -end -end - -function _play_animation(ped, group, animation, flags, duration, props) -if clearActionImmediately then -TASK.CLEAR_PED_TASKS_IMMEDIATELY(ped) -end -if props ~= nil then -local pos = ENTITY.GET_ENTITY_COORDS(ped) -for _, propData in ipairs(props) do -local boneIndex = PED.GET_PED_BONE_INDEX(ped, propData.Bone) -local hash = util.joaat(propData.Prop) -STREAMING.REQUEST_MODEL(hash) -while not STREAMING.HAS_MODEL_LOADED(hash) do -util.yield() -end -local object = entities.create_object(hash, pos) -animAttachments[object] = propData.DeleteOnEnd ~= nil -ENTITY.ATTACH_ENTITY_TO_ENTITY( -object, ped, boneIndex, -propData.Placement[1] or 0.0, -propData.Placement[2] or 0.0, -propData.Placement[3] or 0.0, -propData.Placement[4] or 0.0, -propData.Placement[5] or 0.0, -propData.Placement[6] or 0.0, -false, -true, -false, -true, -1, -true -) -STREAMING.SET_MODEL_AS_NO_LONGER_NEEDED(hash) -end -end -TASK.TASK_PLAY_ANIM(ped, group, animation, 8.0, 8.0, duration, flags, 0.0, false, false, false) -end - ------------------------------- --- Loading & Saving Favorites --------------------------------- -local path = filesystem.stand_dir() .. "/Favorite Animations.txt" -if filesystem.exists(path) then -local headerRead = false -for line in io.lines(path) do -if headerRead then -chunks = {} -for substring in string.gmatch(line, "%S+") do -table.insert(chunks, substring) -end -if #chunks == 2 or #chunks == 3 then -table.insert(favorites, chunks) -end -else -headerRead = true -end -end -populate_favorites() -end -function save_favorites() -local file = io.open(path, "w") -file:write("category\t\tanimation name\t\talias (no spaces)\n") -for _, favorite in ipairs(favorites) do -if favorite[3] then -file:write(string.format("%s %s %s\n", favorite[1], favorite[2], favorite[3])) -else -file:write(string.format("%s %s\n", favorite[1], favorite[2])) -end -end -file:close() -end - ----------------------------------------------------------------------------------------------------------------- - - -addict.toggle(Net_Shit, "Rank 420", {"rank"}, "Note: If you save the profile with it toggled it will give you pemanant 420 rank", function(on_toggle) -addict.trigger_commands("setrank" .. " 420") -end) - -addict.toggle(Net_Shit, "FPS Boost", {"fpsboost"}, "Wait a few seconds for 5-10 FPS Boost.", function(on_toggle) -if on_toggle then -addict.trigger_commands("weather" .. " extrasunny") -addict.trigger_commands("clouds" .. " clear01") -addict.trigger_commands("time" .. " 6") -addict.trigger_commands("superc") -addict.trigger_commands("noidlecam ") -else -addict.trigger_commands("weather" .. " normal") -addict.trigger_commands("clouds" .. " normal") -addict.trigger_commands("noidlecam ") -end -end) - -addict.toggle(Net_Shit, "FPS Boost No Sky", {"fpsnsboost"}, "Wait a few seconds 10-15 FPS Boost.", function(on_toggle) -if on_toggle then -addict.trigger_commands("weather" .. " extrasunny") -addict.trigger_commands("clouds" .. " clear01") -addict.trigger_commands("time" .. " 6") -addict.trigger_commands("supercloop") -addict.trigger_commands("potatomode ") -addict.trigger_commands("nosky ") -addict.trigger_commands("noidlecam ") -else -addict.trigger_commands("weather" .. " normal") -addict.trigger_commands("clouds" .. " normal") -addict.trigger_commands("supercloop") -addict.trigger_commands("potatomode ") -addict.trigger_commands("nosky ") -addict.trigger_commands("noidlecam ") -end -end) - -bountyloop = addict.list(Recovery, "Bounty Loops", {}, "", function(); end) - - ---coded by MrWall - -util.show_corner_help("~p~Loaded ~r~" .. SCRIPT_FILENAME .. " ~p~;)\n~p~Let's Farm Some ~g~$$$ ~p~Or ~r~Crash ~p~Some ~r~Fools ~p~;)") - - - -local playerList = players.list(false, true, true) -local notify = false -local amount = {1000, 2000, 3000, 4000, 5000, 6000, 7000, 8000, 9000} -local randomamount = 10000 - - ---Header -addict.divider(bountyloop, "Bounty Loops") - -local next_loop_time -local has_bounty = false -addict.toggle_loop(bountyloop, "Bounty Loop", {"bountyloop"}, "Still experimental", function(on) -if next_loop_time == nil or util.current_time_millis() > next_loop_time then -local delay -if not has_bounty then -local command = "bounty "..players.get_name(players.user()).." 10000" -addict.trigger_commands(command) -has_bounty = true -delay = 10000 -else -addict.trigger_commands("removebounty") -has_bounty = false -delay = 1000 -end -next_loop_time = util.current_time_millis() + delay -end -end) - ---Waiting time -delay = 30 -addict.slider(bountyloop, "Repeat Colldown", {"bdelay"}, "Set the time on how long the script waits to give the next player a bounty (time is in sec)", 10, 300, delay, 5, function(value) -delay = value -end) - ---Random Amount -function random_pay() -while randomamount <= 10000 do -randomamount = amount[math.random(#amount)] -util.yield(delay * 100) -end -return randomamount -end - -addict.toggle(bountyloop, "Random payout¿", {}, "Set random pay bounty loops\n\nActive = random", function(d) -if d then -random_pay() -else -randomamount = 10000 -end -end) - -addict.toggle(bountyloop, "notifications Off", {}, "By default notifications are turned OFF", function(on) -if on then -notify = true -util.show_corner_help("~p~notifications ~g~On") -else -notify = false -util.show_corner_help("~p~notifications ~r~Off") -end -end) - ---Bounty Toggle -addict.toggle_loop(bountyloop, "Start Loops", {}, "Will get a random players and give them bounty on set time", function() -if #playerList > 0 then -randomPlayer = players.get_name(playerList[math.random(1, #playerList)]) -addict.trigger_commands("bounty" .. randomPlayer .. " " .. randomamount) -if notify then -util.show_corner_help("~r~Bounty placed~y~... \n~r~$ ~w~= " .. randomamount) -if not util.BEGIN_TEXT_COMMAND_IS_THIS_HELP_MESSAGE_BEING_DISPLAYED("~p~notifications ~g~On") then -util.show_corner_help("~r~Bounty placed~y~... \n~r~$ ~w~= " .. randomamount) -end -end -util.yield(delay * 1000) -else -util.show_corner_help("Lobby has ~r~no ~w~other ~r~players.\n\n~w~Consider ~g~joining ~w~a ~g~new one.") -util.yield(60000) -end -end) - -is_player_pointing = function () -return read_global.int(glob.playerpoint + 930) == 3 -- didn't change -end -TraceFlag = -{ -everything = 4294967295, -none = 0, -world = 1, -vehicles = 2, -pedsSimpleCollision = 4, -peds = 8, -objects = 16, -water = 32, -foliage = 256, -} - -function get_offset_from_cam(dist) -local rot = CAM.GET_FINAL_RENDERED_CAM_ROT(2) -local pos = CAM.GET_FINAL_RENDERED_CAM_COORD() -local dir = rot:toDir() -dir:mul(dist) -local offset = ENTITY.GET_ENTITY_COORDS(players.user_ped(), pos, true) -offset:add(dir) -return offset -end - -function get_raycast_result(dist, flag) -local result = {} -flag = flag or TraceFlag.everything -local didHit = memory.alloc(1) -local endCoords = ENTITY.GET_ENTITY_COORDS(players.user_ped(), true) -local normal = ENTITY.GET_ENTITY_COORDS(players.user_ped(), true) -local hitEntity = memory.alloc_int() -local camPos = CAM.GET_FINAL_RENDERED_CAM_COORD() -local offset = get_offset_from_cam(dist) - -local handle = SHAPETEST.START_EXPENSIVE_SYNCHRONOUS_SHAPE_TEST_LOS_PROBE( -camPos.x, camPos.y, camPos.z, -offset.x, offset.y, offset.z, -flag, -players.user_ped(), 7 -) -SHAPETEST.GET_SHAPE_TEST_RESULT(handle, didHit, endCoords, normal, hitEntity) - -result.didHit = memory.read_byte(didHit) ~= 0 -result.endCoords = endCoords -result.surfaceNormal = normal -result.hitEntity = memory.read_int(hitEntity) -return result -end - -local draw_line = function (start, to, colour) -GRAPHICS.DRAW_LINE(start.x, start.y, start.z, to.x, to.y, to.z, colour.r, colour.g, colour.b, colour.a) -end - -local draw_rect = function (pos0, pos1, pos2, pos3, colour) -GRAPHICS.DRAW_POLY(pos0.x, pos0.y, pos0.z, pos1.x, pos1.y, pos1.z, pos3.x, pos3.y, pos3.z, colour.r, colour.g, colour.b, colour.a) -GRAPHICS.DRAW_POLY(pos3.x, pos3.y, pos3.z, pos2.x, pos2.y, pos2.z, pos0.x, pos0.y, pos0.z, colour.r, colour.g, colour.b, colour.a) -end - -function draw_bounding_box(entity, showPoly, colour) -if not ENTITY.DOES_ENTITY_EXIST(entity) then -return -end -colour = colour or {r = 255, g = 0, b = 0, a = 255} -local min = ENTITY.GET_ENTITY_COORDS(players.user_ped(), true) -local max = ENTITY.GET_ENTITY_COORDS(players.user_ped(), true) -MISC.GET_MODEL_DIMENSIONS(ENTITY.GET_ENTITY_MODEL(entity), min, max) -min:abs(); max:abs() - -local upperLeftRear = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, -max.x, -max.y, max.z) -local upperRightRear = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, min.x, -max.y, max.z) -local lowerLeftRear = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, -max.x, -max.y, -min.z) -local lowerRightRear = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, min.x, -max.y, -min.z) - -draw_line(upperLeftRear, upperRightRear, colour) -draw_line(lowerLeftRear, lowerRightRear, colour) -draw_line(upperLeftRear, lowerLeftRear, colour) -draw_line(upperRightRear, lowerRightRear, colour) - -local upperLeftFront = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, -max.x, min.y, max.z) -local upperRightFront = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, min.x, min.y, max.z) -local lowerLeftFront = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, -max.x, min.y, -min.z) -local lowerRightFront = ENTITY.GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(entity, min.x, min.y, -min.z) - -draw_line(upperLeftFront, upperRightFront, colour) -draw_line(lowerLeftFront, lowerRightFront, colour) -draw_line(upperLeftFront, lowerLeftFront, colour) -draw_line(upperRightFront, lowerRightFront, colour) - -draw_line(upperLeftRear, upperLeftFront, colour) -draw_line(upperRightRear, upperRightFront, colour) -draw_line(lowerLeftRear, lowerLeftFront, colour) -draw_line(lowerRightRear, lowerRightFront, colour) - -if type(showPoly) ~= "boolean" or showPoly then -draw_rect(lowerLeftRear, upperLeftRear, lowerLeftFront, upperLeftFront, colour) -draw_rect(upperRightRear, lowerRightRear, upperRightFront, lowerRightFront, colour) - -draw_rect(lowerLeftFront, upperLeftFront, lowerRightFront, upperRightFront, colour) -draw_rect(upperLeftRear, lowerLeftRear, upperRightRear, lowerRightRear, colour) - -draw_rect(upperRightRear, upperRightFront, upperLeftRear, upperLeftFront, colour) -draw_rect(lowerRightFront, lowerRightRear, lowerLeftFront, lowerLeftRear, colour) -end -end - -function request_control_once(entity) -if not NETWORK.NETWORK_IS_IN_SESSION() then -return true -end -local netId = NETWORK.NETWORK_GET_NETWORK_ID_FROM_ENTITY(entity) -NETWORK.SET_NETWORK_ID_CAN_MIGRATE(netId, true) -return NETWORK.NETWORK_REQUEST_CONTROL_OF_ENTITY(entity) -end - -addict.divider(worldchaos, "Fist Power") - -local targetEntity = NULL -local lastStop = newTimer() -local explosionProof = false - -addict.toggle_loop(worldchaos, "Blackhole Finger", {"bhfinger"}, "Move entities with your finger when pointing them. Press B to start pointing.", function() -if is_player_pointing() then -write_global.int(glob.playerpoint + 935, NETWORK.GET_NETWORK_TIME()) -- to avoid the animation to stop -if not ENTITY.DOES_ENTITY_EXIST(targetEntity) then -local flag = TraceFlag.peds | TraceFlag.vehicles | TraceFlag.pedsSimpleCollision | TraceFlag.objects -local raycastResult = get_raycast_result(500.0, flag) -if raycastResult.didHit and ENTITY.DOES_ENTITY_EXIST(raycastResult.hitEntity) then -targetEntity = raycastResult.hitEntity -end -else -local dont_stop = false -for k, veh in pairs(entities.get_all_vehicles_as_handles()) do -local PedInSeat = VEHICLE.GET_PED_IN_VEHICLE_SEAT(veh, -1, false) -local locspeed2 = speed -local holecoords = players.get_position(players.user()) -if not PED.IS_PED_A_PLAYER(PedInSeat) then -NETWORK.NETWORK_REQUEST_CONTROL_OF_ENTITY(veh) -ENTITY.GET_ENTITY_COORDS(PLAYER.GET_PLAYER_PED_SCRIPT_INDEX(bh_target), true) -vcoords = ENTITY.GET_ENTITY_COORDS(veh, true) -speed = 100 -local x_vec = (holecoords['x']-vcoords['x'])*speed -local y_vec = (holecoords['y']-vcoords['y'])*speed -local z_vec = ((holecoords['z']+hole_zoff)-vcoords['z'])*speed -hole_zoff = 100 -ENTITY.SET_ENTITY_INVINCIBLE(veh, true) -ENTITY.APPLY_FORCE_TO_ENTITY_CENTER_OF_MASS(veh, 1, x_vec, y_vec, z_vec, true, false, true, true) -if not dont_stop and not PAD.IS_CONTROL_PRESSED(2, 71) and not PAD.IS_CONTROL_PRESSED(2, 72) then -VEHICLE.SET_VEHICLE_FORWARD_SPEED(veh, 0.0); -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -end -end -local myPos = players.get_position(players.user()) -local entityPos = ENTITY.GET_ENTITY_COORDS(targetEntity, true) -local camDir = CAM.GET_GAMEPLAY_CAM_ROT(0):toDir() -local distance = myPos:distance(entityPos) -if distance > 30.0 then distance = 30.0 -elseif distance < 10.0 then distance = 10.0 end -local targetPos = ENTITY.GET_ENTITY_COORDS(players.user_ped(), camDir, true) -targetPos:mul(distance) -targetPos:add(myPos) -local direction = ENTITY.GET_ENTITY_COORDS(players.user_ped(), targetPos, true) -direction:sub(entityPos) -direction:normalise() -if ENTITY.IS_ENTITY_A_PED(targetEntity) then -direction:mul(1.0) -local explosionPos = ENTITY.GET_ENTITY_COORDS(players.user_ped(), entityPos, true) -explosionPos:sub(direction) -draw_bounding_box(targetEntity, false, {r = 80, g = 0, b = 255, a = 255}) -set_explosion_proof(players.user_ped(), true) -explosionProof = true -FIRE.ADD_EXPLOSION(explosionPos.x, explosionPos.y, explosionPos.z, 29, 25.0, false, true, 0.0, true) - -else -local vel = ENTITY.GET_ENTITY_COORDS(players.user_ped(), direction, true) -local magnitude = entityPos:distance(targetPos) -vel:mul(magnitude) -draw_bounding_box(targetEntity, true, {r = 80, g = 0, b = 255, a = 80}) -request_control_once(targetEntity) -ENTITY.SET_ENTITY_VELOCITY(targetEntity, vel.x, vel.y, vel.z) -end -end -elseif targetEntity ~= NULL then -lastStop.reset() -targetEntity = NULL - -elseif explosionProof and lastStop.elapsed() > 500 then --- No need to worry about disabling any proof if Stand's godmode is on, because --- it'll turn them back on anyways -explosionProof = false -set_explosion_proof(players.user_ped(), false) -end -end) - -dont_stop = false -addict.toggle_loop(worldchaos,"Point Fly Nearby vehicles", {"vehflyall"}, "basically 'impulse like sport mode' but applied to every vehicle", function() -if is_player_pointing() then -write_global.int(glob.playerpoint + 935, NETWORK.GET_NETWORK_TIME()) -- to avoid the animation to stop -if not ENTITY.DOES_ENTITY_EXIST(targetEntity) then -local flag = TraceFlag.peds | TraceFlag.vehicles | TraceFlag.pedsSimpleCollision | TraceFlag.objects -local raycastResult = get_raycast_result(500.0, flag) -if raycastResult.didHit and ENTITY.DOES_ENTITY_EXIST(raycastResult.hitEntity) then -targetEntity = raycastResult.hitEntity -end -else -for k, veh in pairs(entities.get_all_vehicles_as_handles()) do -local PedInSeat = VEHICLE.GET_PED_IN_VEHICLE_SEAT(veh, -1, false) -if not PED.IS_PED_A_PLAYER(PedInSeat) then -NETWORK.NETWORK_REQUEST_CONTROL_OF_ENTITY(veh) -cam_pos = CAM.GET_GAMEPLAY_CAM_ROT(0) -ENTITY.SET_ENTITY_ROTATION(veh, cam_pos.x, cam_pos.y, cam_pos.z, 1, true); -local locspeed = speed*10 -local locspeed2 = speed -if not dont_stop and not PAD.IS_CONTROL_PRESSED(2, 71) and not PAD.IS_CONTROL_PRESSED(2, 72) then -VEHICLE.SET_VEHICLE_FORWARD_SPEED(veh, 0.0); -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -if PAD.IS_CONTROL_PRESSED(0, 61) then -locspeed = locspeed*2 -locspeed2 = locspeed2*2 -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -if PAD.IS_CONTROL_PRESSED(2, 71) then -if dont_stop then -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, 0.0, speed, 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -else -VEHICLE.SET_VEHICLE_FORWARD_SPEED(veh, locspeed) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -end -if PAD.IS_CONTROL_PRESSED(2, 72) then -local lsp = speed -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -if not PAD.IS_CONTROL_PRESSED(0, 61) then -lsp = speed * 2 -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -if dont_stop then -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, 0.0, 0 - (lsp), 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -else -VEHICLE.SET_VEHICLE_FORWARD_SPEED(veh, 0 - (locspeed)); -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -end -if PAD.IS_CONTROL_PRESSED(2, 63) then -local lsp = (0 - speed)*2 -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -if not PAD.IS_CONTROL_PRESSED(0, 61) then -lsp = 0 - speed -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -if dont_stop then -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, (lsp), 0.0, 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -else -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, 0 - (locspeed), 0.0, 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1); -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -end -if PAD.IS_CONTROL_PRESSED(2, 64) then -local lsp = speed -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -if not PAD.IS_CONTROL_PRESSED(0, 61) then -lsp = speed*2 -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -if dont_stop then -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, lsp, 0.0, 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -else -ENTITY.APPLY_FORCE_TO_ENTITY(veh, 1, locspeed, 0.0, 0.0, 0.0, 0.0, 0.0, 0, 1, 1, 1, 0, 1) -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -end -end -if not dont_stop and not PAD.IS_CONTROL_PRESSED(2, 71) and not PAD.IS_CONTROL_PRESSED(2, 72) then -draw_bounding_box(veh, true, {r = 80, g = 0, b = 255, a = 80}) -VEHICLE.SET_VEHICLE_FORWARD_SPEED(veh, 0.0); -end -end -end -end -end -end) - -enabled = false -addict.toggle(bountyloop, "Infinite bountys Loop", {"infinibounty"}, "Places a 10k bounty on the entire session again and again.", function(on) -if on then -enabled = true -else -enabled = false -end -end, false) - -while true do -if enabled then -addict.trigger_commands("bountyall 10000") -end - -util.yield(1000) -end ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -util.on_stop(function() -util.log("Later pussy (Yawn)") -end) \ No newline at end of file +addict.trigger_commands("clicktennisc \ No newline at end of file