Improve debugging.
This commit is contained in:
parent
24d102781c
commit
8b1533db1a
1 changed files with 12 additions and 4 deletions
16
main.c
16
main.c
|
@ -1059,10 +1059,18 @@ Lclearobj:
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
#ifdef GDEBUG
|
#ifdef GDEBUG
|
||||||
printf("Preserve: type1 = %u, id1 = %ld, type2 = %u, id2 = %ld\n",
|
/* Needs to stay synced with enum word_type_t */
|
||||||
preserve.word[0].type, preserve.word[0].id, preserve.word[1].type, preserve.word[1].id);
|
const char *types[] = {"NO_WORD_TYPE", "MOTION", "OBJECT", "ACTION", "NUMERIC"};
|
||||||
printf("Command: type1 = %u, id1 = %ld, type2 = %u, id2 = %ld\n",
|
printf("Preserve: type1 = %s, id1 = %ld, type2 = %s, id2 = %ld\n",
|
||||||
command.word[0].type, command.word[0].id, command.word[1].type, command.word[1].id);
|
types[preserve.word[0].type],
|
||||||
|
preserve.word[0].id,
|
||||||
|
types[preserve.word[1].type],
|
||||||
|
preserve.word[1].id);
|
||||||
|
printf("Command: type1 = %s, id1 = %ld, type2 = %s, id2 = %ld\n",
|
||||||
|
types[command.word[0].type],
|
||||||
|
command.word[0].id,
|
||||||
|
types[command.word[1].type],
|
||||||
|
command.word[1].id);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Handle of objectless action followed by actionless object */
|
/* Handle of objectless action followed by actionless object */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue