From 59432708a4ae926e4be2959dfbb2b4eb80be3fd6 Mon Sep 17 00:00:00 2001 From: salmonik Date: Tue, 27 Oct 2026 20:17:07 +0100 Subject: Stucklaunch: alternate attack/use and expose spam rate - Gravity-gun spam now alternates +attack (grab) and +use (drop) instead of pressing both together, which would punt the prop. - Add a Spam rate slider (1..16 ticks, default 2) so the pickup/drop cycle can be tuned; it persists as spam_ticks in [stucklaunch]. - Log the prop index the first few times a stucklaunch engages to aid testing. --- src/menu.cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'src/menu.cpp') diff --git a/src/menu.cpp b/src/menu.cpp index 00ba9be..0b8e20b 100644 --- a/src/menu.cpp +++ b/src/menu.cpp @@ -48,6 +48,7 @@ FeatureState g_stucklaunch{false, 0}; // opt-in movement assist bool g_stucklaunch_use_spam = true; bool g_stucklaunch_gravspam = false; bool g_stucklaunch_autostrafe = true; +int g_stucklaunch_spam_ticks = 2; // Aimbot bone checklist. Head defaults on (v1 behaviour). bool g_aim_bones[AIM_BONE_COUNT] = {true, false, false, @@ -163,10 +164,10 @@ void config_save() { g_bhop.bind, g_bhop_autostrafe); fprintf(f, "[abh]\nactive=%d\nbind=%d\n", g_abh.active, g_abh.bind); fprintf(f, "[stucklaunch]\nactive=%d\nbind=%d\nuse_spam=%d\n" - "gravspam=%d\nautostrafe=%d\n", + "gravspam=%d\nautostrafe=%d\nspam_ticks=%d\n", g_stucklaunch.active, g_stucklaunch.bind, (int)g_stucklaunch_use_spam, (int)g_stucklaunch_gravspam, - (int)g_stucklaunch_autostrafe); + (int)g_stucklaunch_autostrafe, g_stucklaunch_spam_ticks); fprintf(f, "[jumpbug]\nactive=%d\nbind=%d\nassist=%d\n", g_jumpbug.active, g_jumpbug.bind, (int)g_jumpbug_assist); fprintf(f, "[melee]\nactive=%d\nbind=%d\n", g_melee.active, g_melee.bind); @@ -268,6 +269,12 @@ static bool config_load() { g_stucklaunch_gravspam = atoi(val) != 0; else if (strcmp(key, "autostrafe") == 0) g_stucklaunch_autostrafe = atoi(val) != 0; + else if (strcmp(key, "spam_ticks") == 0) { + int v = atoi(val); + if (v < 1) v = 1; + if (v > 16) v = 16; + g_stucklaunch_spam_ticks = v; + } } if (in_aim) { if (strcmp(key, "smooth") == 0) { @@ -351,6 +358,7 @@ void config_reset_defaults() { g_stucklaunch_use_spam = true; g_stucklaunch_gravspam = false; g_stucklaunch_autostrafe = true; + g_stucklaunch_spam_ticks = 2; g_jumpbug = {true, 0}; g_jumpbug_assist = false; g_melee = {true, 0}; @@ -497,6 +505,8 @@ bool stucklaunch_gravspam_enabled() { return g_stucklaunch_gravspam; } bool stucklaunch_autostrafe_enabled() { return g_stucklaunch_autostrafe; } +int stucklaunch_spam_ticks() { return g_stucklaunch_spam_ticks; } + unsigned aimbot_bone_mask() { unsigned m = 0; if (g_aim_bones[AIM_BONE_HEAD]) -- cgit v1.2.3