* feat(Commands): Prototype command system
* feat(Commands): Chat commands
* refactor(Toxic): convert most options into commands
* feat(Protections): block breakup kicks on other players as host
* refactor(Kicks): convert most options into commands
* refactor(Commands): add labels and descriptions to all commands
* feat(Commands): cleanup on unload
* refactor(Troll): convert most options into commands
* refactor(Misc): convert most options into commands
* refactor(Teleport): convert most options into commands
* feat(Commands): Variadic commands and toggleable bools
* feat(Hotkeys): hotkeys now use commands
* fix(Chat): fix the chat window locking up when a message is sent
* fix(Commands): properly handle spoofed username
* fix(Spam): update filter

Co-authored-by: Yimura <24669514+Yimura@users.noreply.github.com>
This commit is contained in:
maybegreat48
2022-12-22 21:23:32 +00:00
committed by GitHub
parent 9d9d438b5d
commit ce5c317d87
143 changed files with 3194 additions and 1458 deletions

View File

@ -4,11 +4,15 @@
#include "looped/looped.hpp"
#include "services/context_menu/context_menu_service.hpp"
#include "script_patches.hpp"
#include "looped_command.hpp"
namespace big
{
void backend::loop()
{
for (auto& command : g_looped_commands)
command->refresh();
register_script_patches();
while (g_running)
@ -20,6 +24,10 @@ namespace big
looped::system_mission_creator();
looped::system_auto_tp();
for (auto command : g_looped_commands)
if (command->is_enabled())
command->on_tick();
script::get_current()->yield();
}
}
@ -30,20 +38,9 @@ namespace big
while (g_running)
{
looped::self_clean_player();
looped::self_free_cam();
looped::self_godmode();
looped::self_invisibility();
looped::self_no_ragdoll();
looped::self_off_radar();
looped::self_police();
looped::self_super_run();
looped::self_no_collision();
looped::self_hud();
looped::self_unlimited_oxygen();
looped::self_no_water_collision();
looped::self_mobile_radio();
looped::self_fast_respawn();
looped::self_dance_mode();
script::get_current()->yield();
@ -59,17 +56,11 @@ namespace big
looped::weapons_ammo_special_type();
looped::weapons_cage_gun();
looped::weapons_delete_gun();
looped::weapons_force_crosshairs();
looped::weapons_gravity_gun();
looped::weapons_increased_damage();
looped::weapons_infinite_ammo();
looped::weapons_infinite_mag();
looped::weapons_no_recoil();
looped::weapons_no_spread();
looped::weapons_repair_gun();
looped::weapons_steal_vehicle_gun();
looped::weapons_vehicle_gun();
looped::weapons_rapid_fire();
script::get_current()->yield();
}
@ -83,16 +74,8 @@ namespace big
{
looped::vehicle_auto_drive();
looped::vehicle_boost_behavior();
looped::vehicle_drive_on_water();
looped::vehicle_god_mode();
looped::vehicle_horn_boost();
looped::vehicle_jump();
looped::vehicle_instant_brake();
looped::vehicle_is_targetable();
looped::vehicle_seatbelt();
looped::vehicle_speedo_meter();
looped::vehicle_keep_vehicle_repaired();
looped::vehicle_no_water_collision();
script::get_current()->yield();
}
@ -117,7 +100,6 @@ namespace big
while (g_running)
{
looped::hud_transition_state();
looped::tunables_disable_phone();
looped::session_local_time();
looped::session_pop_multiplier_areas();
looped::session_force_thunder();
@ -142,18 +124,6 @@ namespace big
}
}
void backend::noclip_loop()
{
LOG(INFO) << "Starting script: No clip";
while (g_running)
{
looped::self_noclip();
script::get_current()->yield();
}
}
void backend::lscustoms_loop()
{
LOG(INFO) << "Starting script: Ls customs";
@ -196,11 +166,8 @@ namespace big
while (g_running)
{
looped::self_free_cam_disable_control_action();
looped::self_noclip_disable_control_action();
looped::custom_gun_disable_control_action();
context_menu_service::disable_control_action_loop();
script::get_current()->yield();