From 10931750ab9a9a96c3eede85c83b6a420e75cf0e Mon Sep 17 00:00:00 2001 From: epoch Date: Wed, 7 Feb 2018 00:19:47 -0600 Subject: added control command to change target of key press commands --- src/hackvr.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/hackvr.c b/src/hackvr.c index 40c6e30..da6292e 100644 --- a/src/hackvr.c +++ b/src/hackvr.c @@ -146,6 +146,7 @@ int load_stdin() {//this function returns -1 to quit, 0 to not ask for a redraw, fprintf(stderr,"# deletegroup\n"); fprintf(stderr,"# assimilate\n"); fprintf(stderr,"# renamegroup\n"); + fprintf(stderr,"# control name\n"); fprintf(stderr,"# dump\n"); fprintf(stderr,"# quit\n"); fprintf(stderr,"# set\n"); @@ -302,6 +303,14 @@ int load_stdin() {//this function returns -1 to quit, 0 to not ask for a redraw, ret=1; continue; } + if(!strcmp(command,"control")) {//change what shape key commands affect. + if(len > 2) { + free(global.user); + global.user=strdup(a[2]); // :D + } + ret=0;//doesn't change anything yet... + continue; + } if(!strcmp(command,"addshape")) {//need to add a grouprot with this. if(len > 3) { if(len != ((strtold(a[3],0)+(strtold(a[3],0)==1))*3)+4) { -- cgit v1.2.3