Skip to content

Fix report abuse breaking the chat box#1063

Open
HarleyGilpin wants to merge 1 commit into
GregHib:mainfrom
HarleyGilpin:bug/fix-report-abuse-chatbox-lock
Open

Fix report abuse breaking the chat box#1063
HarleyGilpin wants to merge 1 commit into
GregHib:mainfrom
HarleyGilpin:bug/fix-report-abuse-chatbox-lock

Conversation

@HarleyGilpin

@HarleyGilpin HarleyGilpin commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Closes #1061

Problem

After submitting (or cancelling) an abuse report, the reporter couldn't type in chat or press Enter for quick-chat until they relogged.

Root cause (client-side, from the 634 cache cs2 + void-client source)

  • Opening report abuse in select-player mode runs cs2 246, which sets the report-mode varc 11 = 1 and removes the chat box key listener (if_setonkey(137:55, -1)) so keystrokes feed the report screen instead. Script 73 (the removed handler) is what processes all chat typing and Enter.
  • The client's close script (cs2 675) only closes the modal. It never re-registers the listener, and the send path (cs2 135) never resets varc 11. Keyboard chat stays dead; relogging fixes it because listeners/varcs rebuild on login.
  • The restore script is cs2 244 (re-registers script 73 on 137:55 via cs2 132, sets varc 11 = 0, clears the reported-name varc 24).

Fix

  • Run cs2 244 (close_report_abuse) whenever the report_abuse interface closes.
  • Close the interface server-side when the ReportAbuse instruction arrives (before validation — the client has already dismissed its side), keeping server interface state in sync and triggering the restore on every path (submit, cancel, X).

Testing

  • New WorldTest asserts the interface closes and script 244 is sent after submitting a report; all existing ReportAbuseTest cases pass.
  • Verified in the client: reported via right-click chat line, via the Report button, and cancelled without submitting, chat keeps working after each.

Opening report abuse in select-player mode (cs2 246) unhooks the chat
input key listener (137:55) and sets report mode varc 11. The client's
close script (cs2 675) never restores either, so chat stays dead until
relog. The restore script (cs2 244) has no client-side callers - the
server is expected to run it. Close the interface server-side on submit
and run cs2 244 whenever report_abuse closes.

Closes GregHib#1061
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Report abuse breaks chat box

1 participant