runelite-client: Don't duplicate chatbox input when widget ids are wrong

This commit is contained in:
Max Weber
2018-09-11 21:01:26 -06:00
parent 1a14aa295e
commit 0e02f04a85
2 changed files with 16 additions and 0 deletions

View File

@@ -36,6 +36,18 @@
.int_var_count 2
.string_var_count 1
; If we are not the active listener, the widget ids have probably changed
get_varc 5
load_int -2
if_icmpeq LABEL2
; Log the error
load_string "Got input while not active; Widget ids in ChatboxInputInit are probably wrong."
load_string "debug"
runelite_callback
return
LABEL2:
; Discard zero presses
iload 0
load_int 0

View File

@@ -46,6 +46,10 @@
sload 1
put_varc_string 22
; Mark varcstring22 for our use
load_int -2
put_varc 5
; Set text
sload 0
load_int 10616869 ; 162:37