comparison urogue/command.c @ 281:4a3f4729257c

Merge the urogue and bugfix branches.
author John "Elwin" Edwards
date Fri, 15 Sep 2017 21:16:28 -0400
parents 4573b355cdc1
children e52a8a7ad4c5
comparison
equal deleted inserted replaced
280:70aa5808c782 281:4a3f4729257c
1301 item_color = s_names; 1301 item_color = s_names;
1302 break; 1302 break;
1303 case STICK: 1303 case STICK:
1304 item_type = TYP_STICK; 1304 item_type = TYP_STICK;
1305 item_color = ws_made; 1305 item_color = ws_made;
1306 break;
1306 default: 1307 default:
1307 if (!mark) 1308 if (!mark)
1308 { 1309 {
1309 msg("You can't call that anything."); 1310 msg("You can't call that anything.");
1310 return; 1311 return;
1311 } 1312 }
1312 break; 1313 break;
1313 } 1314 }
1314 1315
1315 elsewise = (guess_items[item_type][obj->o_which] != NULL ? 1316 if (!mark && know_items[item_type][obj->o_which])
1316 guess_items[item_type][obj->o_which] : item_color[obj->o_which]);
1317
1318 if (know_items[item_type][obj->o_which] && !mark)
1319 { 1317 {
1320 msg("That has already been identified."); 1318 msg("That has already been identified.");
1321 return; 1319 return;
1322 } 1320 }
1323 1321
1329 msg("What do you want to mark it? "); 1327 msg("What do you want to mark it? ");
1330 prbuf[0] = '\0'; 1328 prbuf[0] = '\0';
1331 } 1329 }
1332 else 1330 else
1333 { 1331 {
1332 elsewise = (guess_items[item_type][obj->o_which] != NULL ?
1333 guess_items[item_type][obj->o_which] : item_color[obj->o_which]);
1334
1334 msg("Was called \"%s\".", elsewise); 1335 msg("Was called \"%s\".", elsewise);
1335 msg("What do you want to call it? "); 1336 msg("What do you want to call it? ");
1336 1337
1337 if (guess_items[item_type][obj->o_which] != NULL) 1338 if (guess_items[item_type][obj->o_which] != NULL)
1338 ur_free(guess_items[item_type][obj->o_which]); 1339 ur_free(guess_items[item_type][obj->o_which]);