ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/server/c_misc.C
(Generate patch)

Comparing deliantra/server/server/c_misc.C (file contents):
Revision 1.48 by pippijn, Thu Mar 1 13:30:10 2007 UTC vs.
Revision 1.49 by pippijn, Fri Mar 2 10:15:40 2007 UTC

444 new_draw_info (NDI_UNIQUE, 0, op, "Invalid value for output_count."); 444 new_draw_info (NDI_UNIQUE, 0, op, "Invalid value for output_count.");
445 445
446 return 1; 446 return 1;
447} 447}
448 448
449int
450command_listen (object *op, char *params)
451{
452 int i;
453
454 if (params == NULL || !sscanf (params, "%d", &i))
455 {
456 new_draw_info_format (NDI_UNIQUE, 0, op, "Set listen to what (presently %d)?", op->contr->listening);
457 return 1;
458 }
459 op->contr->listening = (char) i;
460 new_draw_info_format (NDI_UNIQUE, 0, op, "Your verbose level is now %d.", i);
461 return 1;
462}
463
464/* Prints out some useful information for the character. Everything we print 449/* Prints out some useful information for the character. Everything we print
465 * out can be determined by the docs, so we aren't revealing anything extra - 450 * out can be determined by the docs, so we aren't revealing anything extra -
466 * rather, we are making it convenient to find the values. params have 451 * rather, we are making it convenient to find the values. params have
467 * no meaning here. 452 * no meaning here.
468 */ 453 */
1044 strcpy (op->contr->own_title, params); 1029 strcpy (op->contr->own_title, params);
1045 return 1; 1030 return 1;
1046} 1031}
1047 1032
1048int 1033int
1049command_peaceful (object *op, char *params)
1050{
1051 new_draw_info (NDI_UNIQUE, 0, op,
1052 "You cannot change your peaceful setting with this command."
1053 " Please speak to the priest in the temple of Gorokh"
1054 " if you want to become hostile or in temple of Valriel" " if you want to become peaceful again.");
1055
1056/*
1057 if((op->contr->peaceful=!op->contr->peaceful))
1058 new_draw_info(NDI_UNIQUE, 0,op,"You will not attack other players.");
1059 else
1060 new_draw_info(NDI_UNIQUE, 0,op,"You will attack other players.");
1061*/
1062 return 1;
1063}
1064
1065int
1066command_wimpy (object *op, char *params)
1067{
1068 int i;
1069 char buf[MAX_BUF];
1070
1071 if (params == NULL || !sscanf (params, "%d", &i))
1072 {
1073 sprintf (buf, "Your current wimpy level is %d.", op->run_away);
1074 new_draw_info (NDI_UNIQUE, 0, op, buf);
1075 return 1;
1076 }
1077 sprintf (buf, "Your new wimpy level is %d.", i);
1078 new_draw_info (NDI_UNIQUE, 0, op, buf);
1079 op->run_away = i;
1080 return 1;
1081}
1082
1083int
1084command_brace (object *op, char *params)
1085{
1086 if (!params)
1087 op->contr->braced = !op->contr->braced;
1088 else
1089 op->contr->braced = onoff_value (params);
1090
1091 if (op->contr->braced)
1092 new_draw_info (NDI_UNIQUE, 0, op, "You are braced.");
1093 else
1094 new_draw_info (NDI_UNIQUE, 0, op, "Not braced.");
1095
1096 op->update_stats ();
1097 return 0;
1098}
1099
1100int
1101command_kill_pets (object *op, char *params) 1034command_kill_pets (object *op, char *params)
1102{ 1035{
1103 objectlink *obl, *next; 1036 objectlink *obl, *next;
1104 int counter = 0, removecount = 0; 1037 int counter = 0, removecount = 0;
1105 1038

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines