Commit 0d26e562 authored by Rob Swindell's avatar Rob Swindell 💬
Browse files

When console output is off, ignore most Ctrl-A codes

Ctrl-A codes that cause cursor movement or attribute changes or anything except toggling the console output will now be ignored when console output is off.
parent 2cc09ca0
Pipeline #835 passed with stage
in 16 minutes and 12 seconds
......@@ -1060,13 +1060,6 @@ void sbbs_t::ctrl_a(char x)
console^=(CON_ECHO_OFF);
return;
}
if((uchar)x>0x7f) {
cursor_right((uchar)x-0x7f);
return;
}
if(IS_DIGIT(x)) { /* background color */
atr &= (BG_BRIGHT|BLINK|0x0f);
}
switch(toupper(x)) {
case '!': /* level 10 or higher */
if(useron.level<10)
......@@ -1107,6 +1100,18 @@ void sbbs_t::ctrl_a(char x)
case ')': /* turn echo back on */
console&=~CON_ECHO_OFF;
break;
}
if(console & CON_ECHO_OFF)
return;
if((uchar)x>0x7f) {
cursor_right((uchar)x-0x7f);
return;
}
if(IS_DIGIT(x)) { /* background color */
atr &= (BG_BRIGHT|BLINK|0x0f);
}
switch(toupper(x)) {
case '+': /* push current attribute */
if(attr_sp<(int)sizeof(attr_stack))
attr_stack[attr_sp++]=curatr;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment