new cmdtrigger = 0;if(strcmp(cmdtext, "/somecmd") == 0){ if(cmdtrigger == 0) { //nothing happens cmdtrigger++; return 1; } else { //command gets executed cmdtrigger = 0; return 1; }}