act_wiz.txt
diff_logs/act_wiz.txt · 112.9 KB
From the archive diff_logs.tar.gz
Download the archive « Back to the archive contents
diff -i smaug14/src/act_wiz.c smaug18/src/act_wiz.c
8c8
< * Tricops and Fireblade | *
---
> * Tricops, Fireblade, Edmond, Conran | *
33a34
>
36c37
< "empty", "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23", "r24",
---
> "empty", "tmpsave", "r17", "r18", "r19", "r20", "r21", "r22", "r23", "r24",
58a60,62
> /* from clans.c */
> void remove_member args( ( char *clanname, char *membername ) );
>
70a75,76
> void sort_noauctions args( ( NOAUCTION_DATA * pNoauc ) );
>
162,164c168,170
< /*
< * Clear watch file
< */
---
> /*
> * Clear watch file
> */
170c176
< if ( 0 == remove( fname ) )
---
> if ( !remove( fname ) )
179,181c185,187
< /*
< * Display size of watch file
< */
---
> /*
> * Display size of watch file
> */
189d194
<
207,209c212,214
< /*
< * Print watch file
< */
---
> /*
> * Print watch file
> */
251,254c256,259
< /*
< * Display all watches
< * Only IMP+ can see all the watches. The rest can just see their own.
< */
---
> /*
> * Display all watches
> * Only IMP+ can see all the watches. The rest can just see their own.
> */
267,269c272,274
< /*
< * Display only those watches belonging to the requesting imm
< */
---
> /*
> * Display only those watches belonging to the requesting imm
> */
284,286c289,291
< /*
< * Delete a watch belonging to the requesting imm
< */
---
> /*
> * Delete a watch belonging to the requesting imm
> */
321,323c326,328
< /*
< * Watch a specific player
< */
---
> /*
> * Watch a specific player
> */
372,374c377,379
< /*
< * Watch a specific site
< */
---
> /*
> * Watch a specific site
> */
415,417c420,422
< /*
< * Watch a specific command - FB
< */
---
> /*
> * Watch a specific command - FB
> */
478a484,585
> void do_setvault( CHAR_DATA * ch, char *argument )
> {
> VAULT_DATA *vault;
> int rnum;
> char arg1[MAX_INPUT_LENGTH];
> char arg2[MAX_INPUT_LENGTH];
>
> argument = one_argument( argument, arg1 );
> argument = one_argument( argument, arg2 );
>
> if ( !str_cmp( arg1, "show" ) )
> {
> ROOM_INDEX_DATA *room;
>
> pager_printf_color( ch, "&W%6s | %-40.40s | Area name\n\r", "VNUM", "Room Name" );
> for ( vault = first_vault; vault; vault = vault->next )
> {
> if ( ( room = get_room_index( vault->vnum ) ) == NULL )
> continue;
> pager_printf_color( ch, "&c%6d | &C%-40.40s | %s\n\r", vault->vnum, room->name, room->area->filename );
> }
> return;
> }
>
> if ( !str_cmp( arg1, "save" ) && get_trust( ch ) > LEVEL_GREATER )
> {
> save_vault_list( );
> send_to_char( "Done.\n\r", ch );
> return;
> }
>
> if ( is_number( arg1 ) && ( arg2[0] != '\0' ) )
> {
> rnum = atoi( arg1 );
>
> if ( get_room_index( rnum ) != NULL )
> {
> if ( !str_cmp( arg2, "create" ) )
> {
> CREATE( vault, VAULT_DATA, 1 );
> vault->vnum = rnum;
> sort_vaults( vault );
> ch_printf( ch, "Donation room created.\n\r" );
> return;
> }
> if ( !str_cmp( arg2, "delete" ) )
> {
> for ( vault = first_vault; vault; vault = vault->next )
> if ( vault->vnum == rnum )
> {
> UNLINK( vault, first_vault, last_vault, next, prev );
> DISPOSE( vault );
> send_to_char( "Deleting that vnum...\n\r", ch );
> return;
> }
> }
> else
> send_to_char( "Not currently a donation vnum.\n\r", ch );
> }
> else
> {
> send_to_char( "Invalid vnum argument", ch );
> return;
> }
> }
>
> set_char_color( AT_IMMORT, ch );
> ch_printf( ch, "Syntax:\n\r" );
> ch_printf( ch, " setvault show - lists the rooms currently set to save donations\n\r" );
> ch_printf( ch, " setvault <vnum> create - adds a vnum to the list of rooms to save\n\r" );
> ch_printf( ch, " setvault <vnum> delete - removes a vnum from the list of rooms to save\n\r\n\r" );
> if ( get_trust( ch ) > LEVEL_GREATER )
> ch_printf( ch, " setvault save - saves the vault list\n\r" );
> ch_printf( ch, " Remember, rooms set as storage on clans or councils will need to be\n\r" );
> ch_printf( ch, " removed in both clan/council file and the vault list.\n\r" );
> return;
> }
>
>
> /* Old Wizhelp
> void do_wizhelp( CHAR_DATA *ch, char *argument )
> {
> CMDTYPE * cmd;
> int col, hash;
>
> col = 0;
> set_pager_color( AT_PLAIN, ch );
> for ( hash = 0; hash < 126; hash++ )
> for ( cmd = command_hash[hash]; cmd; cmd = cmd->next )
> if ( cmd->level >= LEVEL_HERO
> && cmd->level <= get_trust( ch ) )
> {
> pager_printf( ch, "%-12s", cmd->name );
> if ( ++col % 6 == 0 )
> send_to_pager( "\n\r", ch );
> }
>
> if ( col % 6 != 0 )
> send_to_pager( "\n\r", ch );
> return;
> }
> */
483a591
> int curr_lvl;
486,494d593
< set_pager_color( AT_PLAIN, ch );
< for ( hash = 0; hash < 126; hash++ )
< for ( cmd = command_hash[hash]; cmd; cmd = cmd->next )
< if ( cmd->level >= LEVEL_HERO && cmd->level <= get_trust( ch ) )
< {
< pager_printf( ch, "%-12s", cmd->name );
< if ( ++col % 6 == 0 )
< send_to_pager( "\n\r", ch );
< }
495a595,610
> for ( curr_lvl = LEVEL_AVATAR; curr_lvl <= get_trust( ch ); curr_lvl++ )
> {
> set_pager_color( AT_WHITE, ch );
> send_to_pager( "\n\r\n\r", ch );
> col = 1;
> pager_printf( ch, "[LEVEL %-2d] \n\r", curr_lvl );
> set_pager_color( AT_GREEN, ch );
> for ( hash = 0; hash < 126; hash++ )
> for ( cmd = command_hash[hash]; cmd; cmd = cmd->next )
> if ( ( cmd->level == curr_lvl ) && cmd->level <= get_trust( ch ) )
> {
> pager_printf( ch, "%-12s", cmd->name );
> if ( ++col % 6 == 0 )
> send_to_pager( "\n\r", ch );
> }
> }
497a613
> set_pager_color( AT_PLAIN, ch );
500a617
>
649,650c766,768
< send_to_char_color( "&RThe name you have chosen is too similar to that of a current immortal. \n\r"
< "We ask you to please choose another name using the name command.\n\r", victim );
---
> send_to_char_color( "&RThe name you have chosen is too similar to that of an Immortal.\n\r"
> "We ask you to please choose another name using the 'name' command.\n\r"
> " (Type HELP NAME or HELP NAMING)\n\r", victim );
661,664c779,782
< send_to_char_color( "&RThe name you have chosen is too similar to that of certain\n\r"
< "monsters in the game, in the long run this could cause problems\n\r"
< "and therefore we are unable to authorize them. Please choose\n\r"
< "another name using the name command.\n\r", victim );
---
> send_to_char_color( "&RThe name you have chosen is similar to that of a particular\n\r"
> "creature in the game, in the long run this could cause problems\n\r"
> "and therefore we are unable to authorize it. Please choose\n\r"
> "another name using the 'name' command.\n\r" " (Type HELP NAME or HELP NAMING)\n\r", victim );
675,676c793,794
< send_to_char_color( "&RWe will not authorize names containing swear words, in any language.\n\r"
< "Please choose another name using the name command.\n\r", victim );
---
> send_to_char_color( "&RWe will not authorize names containing profanity, in any language.\n\r"
> "Please choose another name using the 'name' command.\n\r" " (Type HELP NAME or HELP NAMING)\n\r", victim );
688c806,807
< "medieval in nature. Please choose another name using the name\n\r" "command.\n\r", victim );
---
> "medieval in nature. Please choose another name using the 'name'\n\r"
> "command.\n\r" " (Type HELP NAME or HELP NAMING)\n\r", victim );
700c819,820
< "Please choose another name using the name\n\r" "command.\n\r", victim );
---
> "Please choose another name using the 'name'\n\r"
> "command.\n\r" " (Type HELP NAME or HELP NAMING)", victim );
709,710c829,830
< "We ask you to discontinue such behaviour, or suffer possible banishmemt\n\r"
< "from this mud.\n\r", victim );
---
> "We ask you to discontinue such behaviour, or suffer possible banishment\n\r"
> "from the game.\n\r", victim );
713a834,835
> if ( victim->fighting )
> stop_fighting( victim, TRUE );
725,726d846
< "You may choose a new name when you reach "
< "the end of this area.\n\r"
728c848
< "No titles, descriptive words, or names close to any existing " "Immortal's name.\n\r", victim->name );
---
> " (Type HELP NAME or HELP NAMING)\n\r", victim->name );
815c935
< if ( victim->level < LEVEL_SAVIOR )
---
> if ( !IS_RETIRED( victim ) && victim->level < LEVEL_SAVIOR )
827a948
> do_mortalize( ch, victim->name );
926a1048
> act( AT_BLOOD, "$n denies access to $N.", ch, NULL, victim, TO_ROOM );
1128a1251,1252
> else if ( tar == ECHOTAR_PK && !IS_PKILL( d->character ) )
> continue;
1142a1267,1293
> void do_aecho( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *vch;
> CHAR_DATA *vch_next;
> sh_int color;
>
> if ( ( color = get_color( argument ) ) )
> argument = one_argument( argument, arg );
> if ( argument[0] == '\0' )
> {
> send_to_char( "Aecho what?\n\r", ch );
> return;
> }
> for ( vch = first_char; vch; vch = vch_next )
> {
> vch_next = vch->next;
> if ( vch->in_room->area == ch->in_room->area )
> {
> if ( color )
> set_char_color( color, vch ), send_to_char( argument, vch ), send_to_char( "\n\r", vch );
> else
> set_char_color( AT_IMMORT, vch ), send_to_char( argument, vch ), send_to_char( "\n\r", vch );
> }
> }
> }
>
1180a1332,1337
> if ( !str_cmp( arg, "Thoric" )
> || !str_cmp( arg, "Blodkai" ) || !str_cmp( arg, "Kali" ) || !str_cmp( arg, "Nivek" ) )
> {
> ch_printf( ch, "I don't think %s would like that!\n\r", arg );
> return;
> }
1214a1372,1378
> if ( !str_cmp( arg, "Thoric" )
> || !str_cmp( arg, "Circe" )
> || !str_cmp( arg, "Haus" ) || !str_cmp( arg, "Scryn" ) || !str_cmp( arg, "Blodkai" ) )
> {
> ch_printf( ch, "I don't think %s would like that!\n\r", arg );
> return;
> }
1324,1325c1488,1489
< pager_printf( ch, "Sorry. %s does not wish to be disturbed.\n\r", victim->name );
< pager_printf( victim, "Your DND flag just foiled %s's transfer command.\n\r", ch->name );
---
> ch_printf( ch, "Sorry. %s does not wish to be disturbed.\n\r", victim->name );
> ch_printf( victim, "Your DND flag just foiled %s's transfer command.\n\r", ch->name );
1424,1425c1588,1589
< pager_printf( ch, "Sorry. %s does not wish to be disturbed.\n\r", wch->name );
< pager_printf( wch, "Your DND flag just foiled %s's at command.\n\r", ch->name );
---
> ch_printf( ch, "Sorry. %s does not wish to be disturbed.\n\r", wch->name );
> ch_printf( wch, "Your DND flag just foiled %s's at command.\n\r", ch->name );
1446,1447c1610,1611
< pager_printf( ch, "That room is \"do not disturb\" right now.\n\r" );
< pager_printf( victim, "Your DND flag just foiled %s's atmob command\n\r", ch->name );
---
> ch_printf( ch, "That room is \"do not disturb\" right now.\n\r" );
> ch_printf( victim, "Your DND flag just foiled %s's atmob command\n\r", ch->name );
1501,1502c1665,1666
< pager_printf( ch, "That room is \"do not disturb\" right now.\n\r" );
< pager_printf( victim, "Your DND flag just foiled %s's atobj command\n\r", ch->name );
---
> ch_printf( ch, "That room is \"do not disturb\" right now.\n\r" );
> ch_printf( victim, "Your DND flag just foiled %s's atobj command\n\r", ch->name );
1540c1704
< if ( Start < 1 || End < Start || Start > End || Start == End || End > 32767 )
---
> if ( Start < 1 || End < Start || Start > End || Start == End || End > MAX_VNUM )
1679a1844
> ch_printf_color( ch, "&cRoom Weight: &W%d &cRoom Max Weight: &R%d\n\r", location->weight, location->max_weight );
1682c1847
< ch_printf_color( ch, "&cRoom flags: &w%s\n\r", flag_string( location->room_flags, r_flags ) );
---
> ch_printf_color( ch, "&cRoom flags: &w%s\n\r", ext_flag_string( &location->room_flags, r_flags ) );
1693c1858
< send_to_char( " ", ch );
---
> send_to_char( ", ", ch );
1764a1930,1931
> if ( obj->owner[0] != '\0' )
> ch_printf_color( ch, "&cOwner: &Y%s\n\r", obj->owner );
1781c1948,1949
< ch_printf_color( ch, "&cLevel: &P%d\n\r", obj->level );
---
> ch_printf_color( ch, "&cLevel: &P%d ", obj->level );
> ch_printf_color( ch, "&cIndex level: &P%d\n\r", obj->pIndexData->level );
1799c1967
< send_to_char( " ", ch );
---
> send_to_char( ", ", ch );
1801c1969
< send_to_char( "'.\n\r", ch );
---
> send_to_char( "'\n\r", ch );
1812c1980
< send_to_char( " ", ch );
---
> send_to_char( ", ", ch );
1814c1982
< send_to_char( "'.\n\r", ch );
---
> send_to_char( "'\n\r", ch );
1822a1991,2074
> void do_vstat( CHAR_DATA * ch, char *argument )
> {
> VARIABLE_DATA *vd;
> CHAR_DATA *victim;
>
> if ( argument[0] == '\0' )
> {
> send_to_pager( "Vstat whom?\n\r", ch );
> return;
> }
>
> if ( ( victim = get_char_world( ch, argument ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
>
> if ( get_trust( ch ) < get_trust( victim ) )
> {
> send_to_char( "Their godly glow prevents you from getting a good look.\n\r", ch );
> return;
> }
>
> if ( !victim->variables )
> {
> send_to_char( "They have no variables currently assigned to them.\n\r", ch );
> return;
> }
>
> pager_printf_color( ch, "\n\r&cName: &C%-20s &cRoom : &w%-10d", victim->name,
> victim->in_room == NULL ? 0 : victim->in_room->vnum );
> pager_printf_color( ch, "\n\r&cVariables:\n\r" );
>
> /*
> Variables:
> Vnum: Tag: Type: Timer:
> Flags:
> Data:
> */
> for ( vd = victim->variables; vd; vd = vd->next )
> {
> pager_printf_color( ch, " &cVnum: &W%-10d &cTag: &W%-15s &cTimer: &W%d\n\r", vd->vnum, vd->tag, vd->timer );
> pager_printf_color( ch, " &cType: " );
> if ( vd->data )
> switch ( vd->type )
> {
> case vtSTR:
> if ( vd->data )
> pager_printf_color( ch, "&CString &cData: &W%s", vd->data );
> break;
> case vtINT:
> if ( vd->data )
> pager_printf_color( ch, "&CInteger &cData: &W%d", ( int ) vd->data );
> break;
> case vtXBIT:
> if ( vd->data )
> {
> char buf[MAX_STRING_LENGTH];
> int started = 0;
> int x;
>
> buf[0] = '\0';
> for ( x = MAX_BITS; x > 0; --x )
> {
> if ( !started && xIS_SET( *( EXT_BV * ) vd->data, x ) )
> started = x;
> }
> for ( x = 1; x <= started; x++ )
> strcat( buf, xIS_SET( *( EXT_BV * ) vd->data, x ) ? "1 " : "0 " );
>
> if ( buf[0] != '\0' )
> buf[strlen( buf ) - 1] = '\0';
> pager_printf_color( ch, "&CXBIT &cData: &w[&W%s&w]", buf );
> }
> break;
> }
> else
> pager_printf_color( ch, "&CNo Data" );
>
> send_to_pager( "\n\r\n\r", ch );
> }
> return;
> }
>
1831a2084
> VARIABLE_DATA *vd;
1835a2089
>
1875,1877c2129,2140
< pager_printf_color( ch, "&cUser: &w%s@%s Descriptor: %d &cTrust: &w%d &cAuthBy: &w%s\n\r",
< victim->desc->user, victim->desc->host, victim->desc->descriptor,
< victim->trust, victim->pcdata->authed_by[0] != '\0' ? victim->pcdata->authed_by : "(unknown)" );
---
> pager_printf_color( ch, "&cUser: &w%-19s Descriptor: %d &cTrust: &w%d &cAuthBy: &w%s\n\r",
> victim->desc->user, victim->desc->descriptor, victim->trust,
> victim->pcdata->authed_by[0] != '\0' ? victim->pcdata->authed_by : "(unknown)" );
> if ( !IS_NPC( victim ) )
> {
> pager_printf_color( ch, "&cRecent IP: &w%-15s", victim->pcdata->recent_site ?
> victim->pcdata->recent_site : "Unknown" );
> pager_printf_color( ch, "&cPrevious IP: &w%-15s", victim->pcdata->prev_site ?
> victim->pcdata->prev_site : "Unknown" );
> pager_printf_color( ch, "&cRank: &w%s\n\r",
> str_cmp( victim->pcdata->rank, "" ) ? victim->pcdata->rank : "(default)" );
> }
1892c2155,2159
< pager_printf_color( ch, "&cLevel : &P%-2d ", victim->level );
---
> pager_printf_color( ch, "&cLevel : &P%-2d ", victim->level );
> if ( IS_NPC( victim ) )
> pager_printf_color( ch, "&c(&w%-2.2d&c) ", victim->pIndexData->level );
> else
> pager_printf_color( ch, " " );
1930,1932c2197,2200
< pager_printf_color( ch, "&cDeity : &w%-13s&w &cFavor : &w%-5d &cGlory : &w%-d (%d)\n\r",
< victim->pcdata->deity ? victim->pcdata->deity->name : "(none)",
< victim->pcdata->favor, victim->pcdata->quest_curr, victim->pcdata->quest_accum );
---
> pager_printf_color( ch,
> "&cDeity : &w%-13s&w &cFavor : &w%-5d &cGlory : &w%-3d (%-3d) &cHonour : &w%-3d\n\r",
> victim->pcdata->deity ? victim->pcdata->deity->name : "(none)", victim->pcdata->favor,
> victim->pcdata->quest_curr, victim->pcdata->quest_accum, victim->pcdata->honour );
1984a2253,2256
> /*
> pager_printf_color( ch, "&cSpeaks: &w%d &cSpeaking: &w%d &cExperience: &w%d",
> victim->speaks, victim->speaking, victim->exp );
> */
1986c2258,2262
< victim->speaks, victim->speaking, victim->exp );
---
> victim->speaks, victim->speaking,
> IS_NPC( victim ) ?
> get_exp_worth( victim ) < MAX_EXP_WORTH ? get_exp_worth( victim ) : MAX_EXP_WORTH : victim->exp );
>
>
2035a2312,2333
> #ifdef SHADDAI
> if ( xIS_SET( victim->act, ACT_PROTOTYPE ) )
> pager_printf_color( ch, "&cDefault Stance: &w%s\n\r", get_stance_name( victim->pIndexData->stances[0] ) );
> #endif
> }
> #ifdef SHADDAI
> pager_printf_color( ch, "&cStances : " );
> {
> int i, j = 1;
>
> for ( i = ( STANCE_NORMAL + 1 ); i < MAX_STANCE; i++, j++ )
> {
> if ( IS_NPC( victim ) )
> pager_printf_color( ch, "&w%10s: %3d ", get_stance_name( i ), victim->pIndexData->stances[i] );
> else
> pager_printf_color( ch, "&w%10s: %3d ", get_stance_name( i ), victim->pcdata->stances[i] );
> if ( j == 4 )
> {
> j = 0;
> send_to_char( "\n\r ", ch );
> }
> }
2036a2335,2337
> #endif
> send_to_char( "\n\r", ch );
>
2045c2346,2409
< send_to_char( "\n\r", ch );
---
> send_to_pager( "\n\r", ch );
> }
> /* pre variables update
> if ( ch->variables )
> {
> pager_printf_color( ch, "&cVariables : &w" );
> for ( vd = victim->variables; vd; vd = vd->next )
> {
> pager_printf_color( ch, "%s:%d", vd->tag, vd->vnum );
> switch(vd->type)
> {
> case vtSTR:
> if ( vd->data )
> pager_printf_color( ch, "=%s", vd->data );
> break;
> case vtINT:
> if ( vd->data )
> pager_printf_color( ch, "=%d", (int)vd->data );
> break;
> case vtXBIT:
> }
> pre variables update end */
> /* post variables update */
> if ( victim->variables )
> {
> pager_printf_color( ch, "&cVariables : &w" );
> for ( vd = victim->variables; vd; vd = vd->next )
> {
> pager_printf_color( ch, "%s:%d", vd->tag, vd->vnum );
> switch ( vd->type )
> {
> case vtSTR:
> if ( vd->data )
> pager_printf_color( ch, "=%s", vd->data );
> break;
> case vtINT:
> if ( vd->data )
> pager_printf_color( ch, "=%d", ( int ) vd->data );
> break;
> case vtXBIT:
> if ( vd->data )
> {
> char buf[MAX_STRING_LENGTH];
> int started = 0;
>
> buf[0] = '\0';
> for ( x = MAX_BITS; x > 0; --x )
> {
> if ( !started && xIS_SET( *( EXT_BV * ) vd->data, x ) )
> started = x;
> }
> for ( x = 1; x <= started; x++ )
> strcat( buf, xIS_SET( *( EXT_BV * ) vd->data, x ) ? "1 " : "0 " );
>
> if ( buf[0] != '\0' )
> buf[strlen( buf ) - 1] = '\0';
> pager_printf_color( ch, "=[%s]", buf );
> }
> }
> /* post variables update end */
> if ( vd->next )
> send_to_pager( " ", ch );
> }
> send_to_pager( "\n\r", ch );
2160c2524,2527
< if ( IS_NPC( victim ) && victim->in_room && nifty_is_name( arg, victim->name ) )
---
> if ( IS_NPC( victim )
> && victim->in_room
> && ( nifty_is_name( arg, victim->name )
> || victim->pIndexData->vnum == ( is_number( arg ) ? atoi( arg ) : 0 ) ) )
2163c2530
< pager_printf( ch, "[%5d] %-28s [%5d] %s\n\r",
---
> pager_printf_color( ch, "[%5d] %-28s [%5d] %s\n\r",
2247a2615
>
2436a2805,2807
> if ( IS_NPC( ch ) )
> return;
>
2443a2815,2820
> if ( IS_SET( ch->pcdata->flags, PCFLAG_PAGERON ) )
> {
> send_to_char( "The 'owhere' command temporarily not be used in conjunction with the pager.\n\r", ch );
> return;
> }
>
2501c2878
< send_to_pager( buf, ch );
---
> send_to_char( buf, ch );
2505a2883
>
2512,2516d2889
< void do_reboo( CHAR_DATA * ch, char *argument )
< {
< send_to_char_color( "&YIf you want to REBOOT, spell it out.\n\r", ch );
< return;
< }
2518c2891,2896
< void do_reboot( CHAR_DATA * ch, char *argument )
---
> /*
> * "Claim" an object. Will allow an immortal to "grab" an object no matter
> * where it is hiding. ie: from a player's inventory, from deep inside
> * a container, from a mobile, from anywhere. -Thoric
> */
> void do_oclaim( CHAR_DATA * ch, char *argument )
2520,2522c2898,2900
< char buf[MAX_STRING_LENGTH];
< extern bool mud_down;
< CHAR_DATA *vch;
---
> char arg[MAX_INPUT_LENGTH];
> char arg1[MAX_INPUT_LENGTH];
> char arg2[MAX_INPUT_LENGTH];
2524c2902,2913
< set_char_color( AT_IMMORT, ch );
---
> char arg3[MAX_INPUT_LENGTH];
> char *who = NULL;
> CHAR_DATA *vch = NULL;
> OBJ_DATA *obj;
> bool silently = FALSE, found = FALSE;
> int number, count, vnum;
>
> number = number_argument( argument, arg );
> argument = arg;
> argument = one_argument( argument, arg1 );
> argument = one_argument( argument, arg2 );
> argument = one_argument( argument, arg3 );
2526,2527c2915
< if ( str_cmp( argument, "mud now" )
< && str_cmp( argument, "nosave" ) && str_cmp( argument, "and sort skill table" ) )
---
> if ( arg1[0] == '\0' )
2529c2917
< send_to_char( "Syntax: 'reboot mud now' or 'reboot nosave'\n\r", ch );
---
> send_to_char( "Syntax: oclaim <object> [from who] [+silent]\r\n", ch );
2532,2538c2920
<
< if ( auction->item )
< do_auction( ch, "stop" );
< sprintf( buf, "Reboot by %s.", ch->name );
< do_echo( ch, buf );
<
< if ( !str_cmp( argument, "and sort skill table" ) )
---
> if ( arg3[0] == '\0' )
2540,2541c2922,2934
< sort_skill_table( );
< save_skill_table( );
---
> if ( arg2[0] != '\0' )
> {
> if ( !str_cmp( arg2, "+silent" ) )
> silently = TRUE;
> else
> who = arg2;
> }
> }
> else
> {
> who = arg2;
> if ( !str_cmp( arg3, "+silent" ) )
> silently = TRUE;
2544,2549c2937,3081
< /*
< * Save all characters before booting.
< */
< if ( str_cmp( argument, "nosave" ) )
< for ( vch = first_char; vch; vch = vch->next )
< if ( !IS_NPC( vch ) )
---
> if ( who )
> {
> if ( ( vch = get_char_world( ch, who ) ) == NULL )
> {
> send_to_pager( "They aren't here.\n\r", ch );
> return;
> }
> if ( get_trust( ch ) < get_trust( vch ) && !IS_NPC( vch ) )
> {
> act( AT_TELL, "$n tells you, 'Keep your hands to yourself!'", vch, NULL, ch, TO_VICT );
> return;
> }
> }
>
> if ( is_number( arg1 ) )
> vnum = atoi( arg1 );
> else
> vnum = -1;
>
> count = 0;
> for ( obj = first_object; obj; obj = obj->next )
> {
> if ( can_see_obj( ch, obj )
> && ( obj->pIndexData->vnum == vnum || nifty_is_name( arg1, obj->name ) )
> && ( !vch || vch == carried_by( obj ) ) )
> if ( ( count += obj->count ) >= number )
> {
> found = TRUE;
> break;
> }
> }
> if ( !found && vnum != -1 )
> {
> send_to_char( "You can't find that.\r\n", ch );
> return;
> }
>
> count = 0;
> for ( obj = first_object; obj; obj = obj->next )
> {
> if ( can_see_obj( ch, obj )
> && ( obj->pIndexData->vnum == vnum || nifty_is_name_prefix( arg1, obj->name ) )
> && ( !vch || vch == carried_by( obj ) ) )
> if ( ( count += obj->count ) >= number )
> {
> found = TRUE;
> break;
> }
> }
>
> if ( !found )
> {
> send_to_char( "You can't find that.\r\n", ch );
> return;
> }
>
> if ( !vch && ( vch = carried_by( obj ) ) != NULL )
> {
> if ( get_trust( ch ) < get_trust( vch ) && !IS_NPC( vch ) )
> {
> act( AT_TELL, "$n tells you, 'Keep your hands off $p! It's mine.'", vch, obj, ch, TO_VICT );
> act( AT_IMMORT, "$n tried to lay claim to $p from your possession!", vch, obj, ch, TO_CHAR );
> return;
> }
> }
>
> separate_obj( obj );
> if ( obj->item_type == ITEM_PORTAL )
> remove_portal( obj );
>
> if ( obj->carried_by )
> obj_from_char( obj );
> else if ( obj->in_room )
> obj_from_room( obj );
> else if ( obj->in_obj )
> obj_from_obj( obj );
>
> obj_to_char( obj, ch );
> if ( vch )
> {
> if ( !silently )
> {
> act( AT_IMMORT, "$n claims $p from you!", ch, obj, vch, TO_VICT );
> act( AT_IMMORT, "$n claims $p from $N!", ch, obj, vch, TO_NOTVICT );
> act( AT_IMMORT, "You claim $p from $N!", ch, obj, vch, TO_CHAR );
> }
> else
> act( AT_IMMORT, "You silently claim $p from $N.", ch, obj, vch, TO_CHAR );
> }
> else
> {
> if ( !silently )
> {
> /*
> * notify people in the room... (not done yet)
> */
> act( AT_IMMORT, "You claim $p!", ch, obj, NULL, TO_CHAR );
> }
> else
> act( AT_IMMORT, "You silently claim $p.", ch, obj, NULL, TO_CHAR );
> }
> }
>
> void do_reboo( CHAR_DATA * ch, char *argument )
> {
> send_to_char_color( "&YIf you want to REBOOT, spell it out.\n\r", ch );
> return;
> }
>
> void do_reboot( CHAR_DATA * ch, char *argument )
> {
> char buf[MAX_STRING_LENGTH];
> char buf2[MAX_STRING_LENGTH];
> extern bool mud_down;
> CHAR_DATA *vch;
>
> set_char_color( AT_IMMORT, ch );
>
> sprintf( buf, "%s now", sysdata.port_name );
> sprintf( buf2, "%s nosave", sysdata.port_name );
>
> if ( str_cmp( argument, buf ) && str_cmp( argument, buf2 ) && str_cmp( argument, "and sort skill table" ) )
> {
> send_to_char( "Syntax: 'reboot <port_name> now' or 'reboot <port_name> nosave'\n\r", ch );
> return;
> }
>
> if ( auction->item )
> do_auction( ch, "stop" );
>
> sprintf( buf, "Reboot by %s.", ch->name );
> do_echo( ch, buf );
>
> if ( !str_cmp( argument, "and sort skill table" ) )
> {
> sort_skill_table( );
> save_skill_table( );
> }
>
> /*
> * Save all characters before booting.
> */
> if ( str_cmp( argument, "nosave" ) )
> for ( vch = first_char; vch; vch = vch->next )
> if ( !IS_NPC( vch ) )
2564a3097
> char buf2[MAX_STRING_LENGTH];
2570c3103,3106
< if ( str_cmp( argument, "mud now" ) && str_cmp( argument, "nosave" ) )
---
> sprintf( buf, "%s now", sysdata.port_name );
> sprintf( buf2, "%s nosave", sysdata.port_name );
>
> if ( str_cmp( argument, buf ) && str_cmp( argument, buf2 ) )
2572c3108
< send_to_char( "Syntax: 'shutdown mud now' or 'shutdown nosave'\n\r", ch );
---
> send_to_char( "Syntax: 'shutdown <port_name> now' or 'shutdown <port_name> nosave'\n\r", ch );
2778d3313
< set_char_color( AT_IMMORT, ch );
2783a3319
> set_char_color( AT_IMMORT, ch );
2788d3323
< send_to_char( "You return to your original body.\n\r", ch );
2800a3336,3337
> set_char_color( AT_IMMORT, ch );
> send_to_char( "You return to your original body.\n\r", ch );
2809c3346
< sh_int vnum;
---
> int vnum;
2881,2882c3418,3421
< char arg1[MAX_INPUT_LENGTH];
< char arg2[MAX_INPUT_LENGTH];
---
> char arg1[MAX_INPUT_LENGTH]; /* Vnum/keyword */
> char arg2[MAX_INPUT_LENGTH]; /* Level */
> char arg3[MAX_INPUT_LENGTH]; /* Quantity */
>
2885c3424
< sh_int vnum;
---
> int vnum;
2886a3426
> int quantity = 1;
2891a3432,3433
> argument = one_argument( argument, arg3 );
>
2894c3436
< send_to_char( "Syntax: oinvoke <vnum> <level>.\n\r", ch );
---
> send_to_char( "Syntax: oinvoke <vnum> <level> <quantity>.\n\r", ch );
2914a3457,3473
> if ( arg3[0] != '\0' )
> {
> if ( !is_number( arg3 ) )
> {
> send_to_char( "Syntax: oinvoke <vnum> <level> <quantity>\n\r", ch );
> return;
> }
>
> quantity = atoi( arg3 );
>
> if ( quantity < 1 || quantity > MAX_OINVOKE_QUANTITY )
> {
> ch_printf( ch, "You must oinvoke between 1 and %d items.\n\r", MAX_OINVOKE_QUANTITY );
> return;
> }
> }
>
2977a3537,3545
>
> if ( quantity > 1 && ( !xIS_SET( obj->extra_flags, ITEM_MULTI_INVOKE ) ) )
> {
> send_to_char( "This item can not be invoked in quantities greater than 1.\n\r", ch );
> return;
> }
> else
> obj->count = quantity;
>
2986a3555
>
2990,2991c3559,3566
< ch_printf_color( ch, "&YYou invoke %s (&W#%d &Y- &W%s &Y- &Wlvl %d&Y)\n\r",
< pObjIndex->short_descr, pObjIndex->vnum, pObjIndex->name, obj->level );
---
> ch_printf_color( ch, "&YYou invoke %s (&W#%d &Y- &W%s &Y- &Wlvl %d &Y- &Wqty %d&Y)\n\r",
> pObjIndex->short_descr, pObjIndex->vnum, pObjIndex->name, obj->level, quantity );
> sprintf( log_buf, "%s invoked %s (vnum %d - %s - level %d - quantity %d)",
> ch->name, pObjIndex->short_descr, pObjIndex->vnum, pObjIndex->name, obj->level, quantity );
> log_string_plus( log_buf, LOG_ALL, 62 );
> sprintf( log_buf, "%s (v%d / %s / l%d / q%d)",
> pObjIndex->short_descr, pObjIndex->vnum, pObjIndex->name, obj->level, quantity );
> append_file( ch, OINVOKE_FILE, log_buf );
3026a3602,3618
> save_house_by_vnum( ch->in_room->vnum ); /* Prevent House Object Duplication */
> /*
> * Clan storeroom check
> */
> if ( xIS_SET( ch->in_room->room_flags, ROOM_CLANSTOREROOM ) )
> {
> VAULT_DATA *vault;
> char buf[20];
>
> for ( vault = first_vault; vault; vault = vault->next )
> if ( vault->vnum == ch->in_room->vnum )
> {
> sprintf( buf, "%d", vault->vnum );
> save_storeroom( ch, buf );
> }
>
> }
3048a3641,3642
> int vnum = ( obj->in_room ? obj->in_room->vnum : ROOM_VNUM_LIMBO );
>
3052a3647,3660
> save_house_by_vnum( vnum ); /* Prevent House Object Duplication */
> if ( xIS_SET( ch->in_room->room_flags, ROOM_CLANSTOREROOM ) )
> {
> VAULT_DATA *vault;
> char buf[20];
>
> for ( vault = first_vault; vault; vault = vault->next )
> if ( vault->vnum == ch->in_room->vnum )
> {
> sprintf( buf, "%d", vault->vnum );
> save_storeroom( ch, buf );
> }
>
> }
3073a3682,3751
>
> /* Sunangel
> LOOP <command> [start] [end] [params] */
> void do_loop( CHAR_DATA * ch, char *argument )
> {
> char arg1[MAX_INPUT_LENGTH];
> char arg2[MAX_INPUT_LENGTH];
> char arg3[MAX_INPUT_LENGTH];
> char buf[MAX_STRING_LENGTH];
> int startvnum, endvnum, i;
>
> argument = one_argument( argument, arg1 );
> argument = one_argument( argument, arg2 );
> argument = one_argument( argument, arg3 );
>
> if ( arg1[0] == '\0' )
> {
> send_to_char( "Syntax: loop <command> <start#> <end#> <params>\n\r", ch );
> send_to_char( " Where <command> is a valid command to execute,\n\r", ch );
> send_to_char( " <start#> and <end#> are numbers/vnums,\n\r", ch );
> send_to_char( " and <params> is a parameter list for <command>.\n\r", ch );
> send_to_char( "EXAMPLE: LOOP MSET 22000 22100 FLAGS PROTOTYPE&C&w\n\r", ch );
> return;
> }
>
> if ( arg2[0] == '\0' )
> {
> send_to_char( "You must specify a start number/vnum.\n\r", ch );
> return;
> }
>
> if ( arg3[0] == '\0' )
> {
> send_to_char( "You must specify an end number/vnum.\n\r", ch );
> return;
> }
>
> startvnum = ( is_number( arg2 ) ? atoi( arg2 ) : 1 );
> endvnum = ( is_number( arg3 ) ? atoi( arg3 ) : 1 );
>
> if ( endvnum < 0 )
> endvnum = 1;
>
> if ( startvnum < 0 )
> startvnum = 1;
>
> if ( startvnum > endvnum )
> {
> i = endvnum;
> endvnum = startvnum;
> startvnum = i;
> }
>
> sprintf( buf, "Beginning loop for %s command, vnums %d to %d (%s).\n\r", arg1, startvnum, endvnum, argument );
>
> send_to_char( buf, ch );
>
> for ( i = startvnum; i <= endvnum; i++ )
> {
> sprintf( buf, "%s %d %s", arg1, i,
> ( !str_cmp( arg1, "mstat" ) || !str_cmp( arg1, "ostat" ) ) ? "\b" : argument );
> interpret( ch, buf );
> }
>
> send_to_char( "Done.\n\r", ch );
>
> return;
> }
>
>
3102a3781,3794
> save_house_by_vnum( ch->in_room->vnum ); /* Prevent House Object Duplication */
> if ( xIS_SET( ch->in_room->room_flags, ROOM_CLANSTOREROOM ) )
> {
> VAULT_DATA *vault;
> char buf[20];
>
> for ( vault = first_vault; vault; vault = vault->next )
> if ( vault->vnum == ch->in_room->vnum )
> {
> sprintf( buf, "%d", vault->vnum );
> save_storeroom( ch, buf );
> }
>
> }
3123a3816
>
3459a4153,4169
> void do_imm_news( CHAR_DATA * ch, char *argument )
> {
>
> if ( IS_NPC( ch ) )
> return;
>
> if ( !IS_IMMORTAL( ch ) )
> {
> send_to_char( "Huh?\n\r", ch );
> return;
> }
>
> send_to_char_color( "\n\r&G&cImmortal news of the Realms ...\n\r", ch );
> show_file( ch, IMMNEWS_FILE );
> return;
> }
>
3520a4231
> remove_member( victim->pcdata->clan_name, victim->name );
3552a4264,4330
> void do_mobinvade( CHAR_DATA * ch, char *argument )
> {
> char arg1[MAX_INPUT_LENGTH];
> char arg2[MAX_INPUT_LENGTH];
> char arg3[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
> AREA_DATA *tarea;
> int count, created;
> bool found = FALSE;
> MOB_INDEX_DATA *pMobIndex;
> ROOM_INDEX_DATA *location;
>
> argument = one_argument( argument, arg1 );
> argument = one_argument( argument, arg2 );
> argument = one_argument( argument, arg3 );
> count = atoi( arg2 );
> set_char_color( AT_GREEN, ch );
> if ( arg1[0] == '\0' || arg2[0] == '\0' )
> {
> send_to_char( "Invade <area> <# of invaders> <mob vnum>\n\r", ch );
> return;
> }
> for ( tarea = first_area; tarea; tarea = tarea->next )
> if ( !str_cmp( tarea->filename, arg1 ) )
> {
> found = TRUE;
> break;
> }
> if ( !found )
> {
> send_to_char( "Area not found.\n\r", ch );
> return;
> }
> if ( count > 300 )
> {
> send_to_char( "Whoa...Less than 300 please.\n\r", ch );
> return;
> }
> if ( ( pMobIndex = get_mob_index( atoi( arg3 ) ) ) == NULL )
> {
> send_to_char( "No mobile has that vnum.\n\r", ch );
> return;
> }
>
> for ( created = 0; created < count; created++ )
> {
> if ( ( location = get_room_index( number_range( tarea->low_r_vnum, tarea->hi_r_vnum ) ) ) == NULL )
> {
> --created;
> continue;
> }
> if ( xIS_SET( location->room_flags, ROOM_SAFE ) )
> {
> --created;
> continue;
> }
> victim = create_mobile( pMobIndex );
> char_to_room( victim, location );
> act( AT_IMMORT, "$N appears as part of an invasion force!", ch, NULL, victim, TO_ROOM );
> }
> send_to_char( "The invasion was successful!\n\r", ch );
>
> return;
> }
>
>
>
3627c4405
< pRoomIndex = get_room_index( number_range( 0, 32767 ) );
---
> pRoomIndex = get_room_index( number_range( 0, MAX_VNUM ) );
3629,3632c4407,4410
< if ( !IS_SET( pRoomIndex->room_flags, ROOM_PRIVATE )
< && !IS_SET( pRoomIndex->room_flags, ROOM_SOLITARY )
< && !IS_SET( pRoomIndex->room_flags, ROOM_NO_ASTRAL )
< && !IS_SET( pRoomIndex->room_flags, ROOM_PROTOTYPE ) )
---
> if ( !xIS_SET( pRoomIndex->room_flags, ROOM_PRIVATE )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_SOLITARY )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_NO_ASTRAL )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_PROTOTYPE ) )
3696c4474
< pRoomIndex = get_room_index( number_range( 0, 32767 ) );
---
> pRoomIndex = get_room_index( number_range( 0, MAX_VNUM ) );
3698,3701c4476,4479
< if ( !IS_SET( pRoomIndex->room_flags, ROOM_PRIVATE )
< && !IS_SET( pRoomIndex->room_flags, ROOM_SOLITARY )
< && !IS_SET( pRoomIndex->room_flags, ROOM_NO_ASTRAL )
< && !IS_SET( pRoomIndex->room_flags, ROOM_PROTOTYPE ) )
---
> if ( !xIS_SET( pRoomIndex->room_flags, ROOM_PRIVATE )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_SOLITARY )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_NO_ASTRAL )
> && !xIS_SET( pRoomIndex->room_flags, ROOM_PROTOTYPE ) )
3768a4547,4548
> bool supah_boost = FALSE;
> DEITY_DATA *deity = NULL;
3777a4558,4567
> // Restore-by-deity. -- Alty
> if ( !str_cmp( arg, "deity" ) )
> {
> argument = one_argument( argument, arg );
> if ( !( deity = get_deity( arg ) ) )
> {
> send_to_char( "No such deity holds weight on this world.\n\r", ch );
> return;
> }
> }
3780a4571,4574
> if ( !str_cmp( ch->name, "Blodkai" ) )
> supah_boost = TRUE;
> else
> boost = TRUE;
3782d4575
< boost = TRUE;
3784c4577
< if ( !str_cmp( arg, "all" ) )
---
> if ( deity || !str_cmp( arg, "all" ) )
3822c4615,4619
< if ( boost )
---
> if ( deity && ch->pcdata->deity != deity )
> continue;
> if ( supah_boost )
> vch->hit = vch->max_hit * 2.2;
> else if ( boost )
3826c4623,4626
< vch->mana = vch->max_mana;
---
> if ( supah_boost )
> vch->mana = vch->max_mana * 2.2;
> else
> vch->mana = vch->max_mana;
3838c4638,4851
< CHAR_DATA *victim;
---
> CHAR_DATA *victim;
>
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
>
> if ( get_trust( ch ) < LEVEL_LESSER
> && victim != ch && !( IS_NPC( victim ) && xIS_SET( victim->act, ACT_PROTOTYPE ) ) )
> {
> send_to_char( "You can't do that.\n\r", ch );
> return;
> }
>
> if ( boost )
> victim->hit = victim->max_hit * 1.5;
> else
> victim->hit = victim->max_hit;
> victim->mana = victim->max_mana;
> victim->move = victim->max_move;
> if ( victim->pcdata )
> victim->pcdata->condition[COND_BLOODTHIRST] = ( 10 + victim->level );
> update_pos( victim );
> if ( ch != victim )
> act( AT_IMMORT, "$n has restored you.", ch, NULL, victim, TO_VICT );
> send_to_char( "Restored.\n\r", ch );
> return;
> }
> }
>
> void do_restoretime( CHAR_DATA * ch, char *argument )
> {
> long int time_passed;
> int hour, minute;
>
> set_char_color( AT_IMMORT, ch );
>
> if ( !last_restore_all_time )
> ch_printf( ch, "There has been no restore all since reboot.\n\r" );
> else
> {
> time_passed = current_time - last_restore_all_time;
> hour = ( int ) ( time_passed / 3600 );
> minute = ( int ) ( ( time_passed - ( hour * 3600 ) ) / 60 );
> ch_printf( ch, "The last restore all was %d hours and %d minutes ago.\n\r", hour, minute );
> }
>
> if ( !ch->pcdata )
> return;
>
> if ( !ch->pcdata->restore_time )
> {
> send_to_char( "You have never done a restore all.\n\r", ch );
> return;
> }
>
> time_passed = current_time - ch->pcdata->restore_time;
> hour = ( int ) ( time_passed / 3600 );
> minute = ( int ) ( ( time_passed - ( hour * 3600 ) ) / 60 );
> ch_printf( ch, "Your last restore all was %d hours and %d minutes ago.\n\r", hour, minute );
> return;
> }
>
> void do_nohomepage( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
>
> set_char_color( AT_IMMORT, ch );
>
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
> {
> send_to_char( "Nohomepage whom?\n\r", ch );
> return;
> }
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
> if ( IS_NPC( victim ) )
> {
> send_to_char( "Not on NPC's.\n\r", ch );
> return;
> }
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "You failed.\n\r", ch );
> return;
> }
> set_char_color( AT_IMMORT, victim );
> if ( xIS_SET( victim->act, PLR_NOHOMEPAGE ) )
> {
> xREMOVE_BIT( victim->act, PLR_NOHOMEPAGE );
> send_to_char( "You can set your own homepage again.\n\r", victim );
> ch_printf( ch, "NOHOMEPAGE removed from %s.\n\r", victim->name );
> }
> else
> {
> xSET_BIT( victim->act, PLR_NOHOMEPAGE );
> STRFREE( victim->pcdata->homepage );
> victim->pcdata->homepage = STRALLOC( "" );
> if ( !victim->desc )
> add_loginmsg( victim->name, 12, NULL );
> else
> send_to_char( "You can't set your own homepage!\n\r", victim );
> ch_printf( ch, "NOHOMEPAGE set on %s.\n\r", victim->name );
> }
> return;
> }
>
> /*
> * Prevent a player from creating a desc and clear offending desc -Shaddai
> */
> void do_nodesc( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
>
> set_char_color( AT_IMMORT, ch );
>
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
> {
> send_to_char( "Nodesc whom?\n\r", ch );
> return;
> }
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
> if ( IS_NPC( victim ) )
> {
> send_to_char( "Not on NPC's.\n\r", ch );
> return;
> }
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "You failed.\n\r", ch );
> return;
> }
> set_char_color( AT_IMMORT, victim );
> if ( IS_SET( victim->pcdata->flags, PCFLAG_NODESC ) )
> {
> REMOVE_BIT( victim->pcdata->flags, PCFLAG_NODESC );
> send_to_char( "You can set your own description again.\n\r", victim );
> ch_printf( ch, "NODESC removed from %s.\n\r", victim->name );
> }
> else
> {
> SET_BIT( victim->pcdata->flags, PCFLAG_NODESC );
> STRFREE( victim->description );
> victim->description = STRALLOC( "" );
> if ( !victim->desc )
> add_loginmsg( victim->name, 11, NULL );
> else
> send_to_char( "You can't set your own description!\n\r", victim );
> ch_printf( ch, "NODESC set on %s.\n\r", victim->name );
> }
> return;
> }
>
> void do_nohttp( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
>
> set_char_color( AT_IMMORT, ch );
>
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
> {
> send_to_char( "Nohttp whom?\n\r", ch );
> return;
> }
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
> if ( IS_NPC( victim ) )
> {
> send_to_char( "Not on NPC's.\n\r", ch );
> return;
> }
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "You failed.\n\r", ch );
> return;
> }
> set_char_color( AT_IMMORT, victim );
> if ( IS_SET( victim->pcdata->flags, PCFLAG_NOHTTP ) )
> {
> REMOVE_BIT( victim->pcdata->flags, PCFLAG_NOHTTP );
> send_to_char( "You can set your own home page again.\n\r", victim );
> ch_printf( ch, "NOHTTP removed from %s.\n\r", victim->name );
> }
> else
> {
> SET_BIT( victim->pcdata->flags, PCFLAG_NOHTTP );
> STRFREE( victim->pcdata->homepage );
> victim->pcdata->homepage = STRALLOC( "" );
> if ( !victim->desc )
> add_loginmsg( victim->name, 12, NULL );
> else
> send_to_char( "You can't set your own home page!\n\r", victim );
> ch_printf( ch, "NOHTTP set on %s.\n\r", victim->name );
> }
> return;
> }
>
3840,3844c4853,4859
< if ( ( victim = get_char_world( ch, arg ) ) == NULL )
< {
< send_to_char( "They aren't here.\n\r", ch );
< return;
< }
---
> /*
> * Prevent a player from creating a bio and clear offending bio -Shaddai
> */
> void do_nobio( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
3846,3851c4861
< if ( get_trust( ch ) < LEVEL_LESSER
< && victim != ch && !( IS_NPC( victim ) && xIS_SET( victim->act, ACT_PROTOTYPE ) ) )
< {
< send_to_char( "You can't do that.\n\r", ch );
< return;
< }
---
> set_char_color( AT_IMMORT, ch );
3853,3864c4863,4881
< if ( boost )
< victim->hit = victim->max_hit * 1.5;
< else
< victim->hit = victim->max_hit;
< victim->mana = victim->max_mana;
< victim->move = victim->max_move;
< if ( victim->pcdata )
< victim->pcdata->condition[COND_BLOODTHIRST] = ( 10 + victim->level );
< update_pos( victim );
< if ( ch != victim )
< act( AT_IMMORT, "$n has restored you.", ch, NULL, victim, TO_VICT );
< send_to_char( "Restored.\n\r", ch );
---
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
> {
> send_to_char( "Nobio whom?\n\r", ch );
> return;
> }
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
> return;
> }
> if ( IS_NPC( victim ) )
> {
> send_to_char( "Not on NPC's.\n\r", ch );
> return;
> }
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "You failed.\n\r", ch );
3866a4884,4902
> set_char_color( AT_IMMORT, victim );
> if ( IS_SET( victim->pcdata->flags, PCFLAG_NOBIO ) )
> {
> REMOVE_BIT( victim->pcdata->flags, PCFLAG_NOBIO );
> send_to_char( "You can set your own bio again.\n\r", victim );
> ch_printf( ch, "NOBIO removed from %s.\n\r", victim->name );
> }
> else
> {
> SET_BIT( victim->pcdata->flags, PCFLAG_NOBIO );
> STRFREE( victim->pcdata->bio );
> victim->pcdata->bio = STRALLOC( "" );
> if ( !victim->desc )
> add_loginmsg( victim->name, 9, NULL );
> else
> send_to_char( "You can't set your own bio!\n\r", victim );
> ch_printf( ch, "NOBIO set on %s.\n\r", victim->name );
> }
> return;
3869c4905,4907
< void do_restoretime( CHAR_DATA * ch, char *argument )
---
>
> /* Guess I should have added this to begin with, huh? - Blod, 12/2000 */
> void do_nobeckon( CHAR_DATA * ch, char *argument )
3871,3872c4909,4910
< long int time_passed;
< int hour, minute;
---
> char arg[MAX_INPUT_LENGTH];
> CHAR_DATA *victim;
3876,3878c4914,4915
< if ( !last_restore_all_time )
< ch_printf( ch, "There has been no restore all since reboot.\n\r" );
< else
---
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
3880,3883c4917,4918
< time_passed = current_time - last_restore_all_time;
< hour = ( int ) ( time_passed / 3600 );
< minute = ( int ) ( ( time_passed - ( hour * 3600 ) ) / 60 );
< ch_printf( ch, "The last restore all was %d hours and %d minutes ago.\n\r", hour, minute );
---
> send_to_char( "Use nobeckon on who?\n\r", ch );
> return;
3885,3886c4920,4922
<
< if ( !ch->pcdata )
---
> if ( ( victim = get_char_world( ch, arg ) ) == NULL )
> {
> send_to_char( "They aren't here.\n\r", ch );
3888,3889c4924,4925
<
< if ( !ch->pcdata->restore_time )
---
> }
> if ( IS_NPC( victim ) )
3891c4927
< send_to_char( "You have never done a restore all.\n\r", ch );
---
> send_to_char( "Not on NPC's.\n\r", ch );
3894,3898c4930,4951
<
< time_passed = current_time - ch->pcdata->restore_time;
< hour = ( int ) ( time_passed / 3600 );
< minute = ( int ) ( ( time_passed - ( hour * 3600 ) ) / 60 );
< ch_printf( ch, "Your last restore all was %d hours and %d minutes ago.\n\r", hour, minute );
---
> set_char_color( AT_IMMORT, victim );
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "Their godly glow prevents you from getting close enough.\n\r", ch );
> return;
> }
> if ( IS_SET( victim->pcdata->flags, PCFLAG_NOBECKON ) )
> {
> REMOVE_BIT( victim->pcdata->flags, PCFLAG_NOBECKON );
> send_to_char( "The gods return your ability to beckon.\n\r", victim );
> ch_printf( ch, "%s can again beckon.\n\r", victim->name );
> }
> else
> {
> SET_BIT( victim->pcdata->flags, PCFLAG_NOBECKON );
> if ( !victim->desc )
> add_loginmsg( victim->name, 13, NULL );
> else
> send_to_char( "The gods have removed your ability to beckon.\n\r", victim );
> ch_printf( ch, "You have removed beckon from %s.\n\r", victim->name );
> }
> save_char_obj( victim );
3941c4994,4997
< send_to_char( "A godly force turns your body to ice!\n\r", victim );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 15, NULL );
> else
> send_to_char( "A godly force turns your body to ice!\n\r", victim );
4087c5143,5146
< send_to_char( "You can't emote!\n\r", victim );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 16, NULL );
> else
> send_to_char( "You can't emote!\n\r", victim );
4103c5162
< send_to_char( "Notell whom?", ch );
---
> send_to_char( "Notell whom?\n\r", ch );
4131c5190,5193
< send_to_char( "You can't use tells!\n\r", victim );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 14, NULL );
> else
> send_to_char( "You can't use tells!\n\r", victim );
4178c5240,5243
< send_to_char( "You can't set your own title!\n\r", victim );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 8, NULL );
> else
> send_to_char( "You can't set your own title!\n\r", victim );
4220c5285,5288
< send_to_char( "You can't use channels!\n\r", victim );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 7, NULL );
> else
> send_to_char( "You can't use channels!\n\r", victim );
4576a5645,5667
> /*
> * Make yourself visible to people in the same room as you -Thoric
> */
> void do_roomvis( CHAR_DATA * ch, char *argument )
> {
> set_char_color( AT_IMMORT, ch );
>
> if ( IS_NPC( ch ) )
> return;
>
> if ( xIS_SET( ch->act, PLR_ROOMVIS ) )
> {
> xREMOVE_BIT( ch->act, PLR_ROOMVIS );
> send_to_char( "You are no longer visible to people in the same room as you.\n\r", ch );
> }
> else
> {
> xSET_BIT( ch->act, PLR_ROOMVIS );
> send_to_char( "You are now visible to people who are in the same room as you.\n\r", ch );
> }
> return;
> }
>
4582c5673
< sh_int r_lo, r_hi;
---
> int r_lo, r_hi;
4646c5737
< sh_int o_lo, o_hi;
---
> int o_lo, o_hi;
4691c5782
< sh_int m_lo, m_hi;
---
> int m_lo, m_hi;
4780c5871
< bool loaded;
---
> bool loaded = FALSE;
4782c5873
< int old_room_vnum;
---
> int old_room_vnum, test = 0;
4785c5876
< CHAR_DATA *victim;
---
> CHAR_DATA *victim = NULL;
4798,4800c5889
< name[0] = UPPER( name[0] );
< sprintf( fname, "%s%c/%s", PLAYER_DIR, tolower( name[0] ), capitalize( name ) );
< if ( stat( fname, &fst ) != -1 )
---
> for ( victim = first_char; victim; victim = victim->next )
4802,4807c5891,5895
< CREATE( d, DESCRIPTOR_DATA, 1 );
< d->next = NULL;
< d->prev = NULL;
< d->connected = CON_GET_NAME;
< d->outsize = 2000;
< CREATE( d->outbuf, char, d->outsize );
---
> if ( IS_NPC( victim ) )
> continue;
> if ( !str_cmp( name, victim->name ) )
> break;
> }
4809,4816c5897,5922
< loaded = load_char_obj( d, name, FALSE );
< add_char( d->character );
< old_room_vnum = d->character->in_room->vnum;
< char_to_room( d->character, ch->in_room );
< if ( get_trust( d->character ) >= get_trust( ch ) )
< {
< do_say( d->character, "Do *NOT* disturb me again!" );
< send_to_char( "I think you'd better leave that player alone!\n\r", ch );
---
> if ( !victim )
> {
> name[0] = UPPER( name[0] );
> sprintf( fname, "%s%c/%s", PLAYER_DIR, tolower( name[0] ), capitalize( name ) );
> if ( ( test = stat( fname, &fst ) ) )
> {
> CREATE( d, DESCRIPTOR_DATA, 1 );
> d->next = NULL;
> d->prev = NULL;
> d->connected = CON_GET_NAME;
> d->outsize = 2000;
> CREATE( d->outbuf, char, d->outsize );
>
> loaded = load_char_obj( d, name, FALSE );
> add_char( d->character );
> old_room_vnum = d->character->in_room->vnum;
> char_to_room( d->character, ch->in_room );
> if ( get_trust( d->character ) >= get_trust( ch ) )
> {
> do_say( d->character, "Do *NOT* disturb me again!" );
> send_to_char( "I think you'd better leave that player alone!\n\r", ch );
> d->character->desc = NULL;
> if ( loaded )
> do_quit( d->character, "" );
> return;
> }
4818c5924,5936
< do_quit( d->character, "" );
---
> victim = d->character;
> d->character = NULL;
> DISPOSE( d->outbuf );
> DISPOSE( d );
> }
> }
> if ( test != -1 && victim )
> {
> if ( get_trust( victim ) >= get_trust( ch ) )
> {
> send_to_char( "You failed!\n\r", ch );
> if ( loaded )
> do_quit( victim, "" );
4821,4825d5938
< d->character->desc = NULL;
< victim = d->character;
< d->character = NULL;
< DISPOSE( d->outbuf );
< DISPOSE( d );
4877d5989
< make_wizlist( );
4880c5992,5998
< do_quit( victim, "" );
---
> if ( loaded )
> do_quit( victim, "" );
> else
> save_char_obj( victim );
> make_wizlist( );
> make_adminlist( );
> make_retiredlist( );
4896c6014
< bool loaded;
---
> bool loaded = FALSE;
4942c6060,6061
< do_quit( d->character, "" );
---
> if ( loaded )
> do_quit( d->character, "" );
5747c6866
< name = capitalize( arg );
---
> name = str_dup( capitalize( arg ) );
5755a6875,6884
> sprintf( buf, "%s%s", HOUSE_DIR, name );
> if ( !remove( buf ) )
> send_to_char( "Player's housing data destroyed.\n\r", ch );
> else if ( errno != ENOENT )
> {
> ch_printf( ch, "Unknown error #%d - %s (housing data)."
> " Report to Coder.\n\r", errno, strerror( errno ) );
> sprintf( buf2, "%s destroying %s", ch->name, buf );
> perror( buf2 );
> }
5799a6929
> DISPOSE( name );
6058a7189
> pager_printf_color( ch, "\n\r&WPort_name: %s", sysdata.port_name );
6066,6067c7197,7199
< pager_printf_color( ch, "&WBuilding:\n\r &wPrototype modification: &W%d &wPlayer msetting: &W%d\n\r",
< sysdata.level_modify_proto, sysdata.level_mset_player );
---
> pager_printf_color( ch,
> "&WBuilding:\n\r &wPrototype modification: &W%d &wPlayer msetting: &W%d &wArea Save version: &W%d\n\r",
> sysdata.level_modify_proto, sysdata.level_mset_player, sysdata.save_version );
6073,6074c7205,7207
< pager_printf_color( ch, "&WDefenses:\n\r &wDodge_mod: &W%d &wParry_mod: &W%d &wTumble_mod: &W%d\n\r",
< sysdata.dodge_mod, sysdata.parry_mod, sysdata.tumble_mod );
---
> pager_printf_color( ch,
> "&WDefenses:\n\r &wDodge_mod: &W%d &wParry_mod: &W%d &wTumble_mod: &W%d &wTumble_pk: &W%d\n\r",
> sysdata.dodge_mod, sysdata.parry_mod, sysdata.tumble_mod, sysdata.tumble_pk );
6086a7220,7221
> pager_printf_color( ch, " &wPercent damage nonav vs. mob: &W%-7d", sysdata.dam_nonav_vs_mob );
> pager_printf_color( ch, "&wPercent damage mob vs. nonav: &W%-3d\n\r", sysdata.dam_mob_vs_nonav );
6094c7229,7234
< pager_printf_color( ch, " &wPkill looting is: &W%s\n\r", ( sysdata.pk_loot ) ? "ON" : "off" );
---
> pager_printf_color( ch, " &wPkill looting is: &W%-7s", ( sysdata.pk_loot ) ? "ON" : "off" );
> pager_printf_color( ch, "&wPkill_channels are: &W%s\n\r", ( sysdata.pk_channels ) ? "ON" : "off" );
> pager_printf_color( ch, " &wPeaceful exp mod: &W%-7d", sysdata.peaceful_exp_mod );
> pager_printf_color( ch, "&wPkill_silence is: &W%s\n\r", ( sysdata.pk_silence ) ? "ON" : "off" );
> pager_printf_color( ch, " &wDeadly exp mod: &W%-7d", sysdata.deadly_exp_mod );
> pager_printf_color( ch, "&wWizlock after reboot: &W%s\n\r", ( sysdata.wizlock ) ? "ON" : "off" );
6096a7237,7238
> pager_printf_color( ch, " &wMax HTML news: %d&W\n\r &wHTML news path: %s&W\n\r", sysdata.max_html_news,
> sysdata.news_html_path );
6115a7258,7296
> if ( !str_cmp( arg, "saveversion" ) )
> {
> sysdata.save_version = UMAX( MIN_SAVE_VERSION, ( ( sh_int ) atoi( argument ) ) );
> send_to_char( "Save version set.\n\r", ch );
> return;
> }
>
> if ( !str_cmp( arg, "wizlock" ) )
> {
> set_char_color( AT_DANGER, ch );
>
> sysdata.wizlock = !sysdata.wizlock;
> ch_printf( ch, "Wizlocked at reboot is %s.\n\r", sysdata.wizlock ? "ON" : "OFF" );
> return;
> }
>
> /*
> * 3/29/02 - for extended news - Nopey
> */
> if ( !str_cmp( arg, "newspath" ) )
> {
> if ( argument[0] == '\0' )
> {
> pager_printf_color( ch, "News path now set to nothing. HTML writing disabled" );
> sysdata.news_html_path[0] = '\0';
> return;
> }
> sysdata.news_html_path = STRALLOC( argument );
> pager_printf_color( ch, "News path set to: %snews.txt\n\r", argument );
> return;
> }
>
> if ( !str_cmp( arg, "maxnews" ) )
> {
> sysdata.max_html_news = atoi( argument );
> pager_printf_color( ch, "Max HTML news now set to: %d\n\r", sysdata.max_html_news );
> return;
> }
>
6121c7302,7311
< send_to_char( "Name set.\n\r", ch );
---
> send_to_char( "Mud name set.\n\r", ch );
> return;
> }
>
> if ( !str_cmp( arg, "portname" ) )
> {
> if ( sysdata.port_name )
> DISPOSE( sysdata.port_name );
> sysdata.port_name = str_dup( argument );
> send_to_char( "Port name set.\n\r", ch );
6138a7329,7336
> if ( !str_prefix( arg, "magichell" ) )
> {
> sysdata.magichell = !sysdata.magichell;
> ch_printf_color( ch, "&BMagic hell is %s.\n\r", sysdata.magichell ? "ON" : "OFF" );
> send_to_char( "Ok.\n\r", ch );
> return;
> }
>
6223a7422,7428
> if ( !str_cmp( arg, "tumble_pk" ) )
> {
> sysdata.tumble_pk = level > 0 ? level : 1;
> send_to_char( "Tumble_pk mod set.\n\r", ch );
> return;
> }
>
6237a7443,7456
> if ( !str_cmp( arg, "deadly_exp" ) )
> {
> sysdata.deadly_exp_mod = level;
> send_to_char( "Deadly experience multiplier modified.\n\r", ch );
> return;
> }
>
> if ( !str_cmp( arg, "peaceful_exp" ) )
> {
> sysdata.peaceful_exp_mod = level;
> send_to_char( "Peaceful experience multiplier modified.\n\r", ch );
> return;
> }
>
6251a7471,7484
> if ( !str_cmp( arg, "dam_navm" ) )
> {
> sysdata.dam_nonav_vs_mob = level;
> send_to_char( "Non-avatar damage vs mobile set.\n\r", ch );
> return;
> }
>
> if ( !str_cmp( arg, "dam_mvna" ) )
> {
> sysdata.dam_mob_vs_nonav = level;
> send_to_char( "Mobile damage vs non-avatar set.\n\r", ch );
> return;
> }
>
6333c7566,7592
< sysdata.save_pets = FALSE;
---
> sysdata.save_pets = FALSE;
> }
> else if ( !str_cmp( arg, "pk_silence" ) )
> {
> if ( level )
> {
> send_to_char( "Pkill silence is enabled.\n\r", ch );
> sysdata.pk_silence = TRUE;
> }
> else
> {
> send_to_char( "Pkill silence is disabled. (use cset pk_silence 1 to enable.)\n\r", ch );
> sysdata.pk_silence = FALSE;
> }
> }
> else if ( !str_cmp( arg, "pk_channels" ) )
> {
> if ( level )
> {
> send_to_char( "Pkill channels are enabled.\n\r", ch );
> sysdata.pk_channels = TRUE;
> }
> else
> {
> send_to_char( "Pkill channels are disabled. (use cset pk_channels 1 to enable)\n\r", ch );
> sysdata.pk_channels = FALSE;
> }
6458,6459c7717,7721
< ch_printf( victim, "The immortals are not pleased with your actions.\n\r"
< "You shall remain in hell for %d %s%s.\n\r", time, ( h_d ? "hour" : "day" ), ( time == 1 ? "" : "s" ) );
---
> if ( !victim->desc )
> add_loginmsg( victim->name, 10, NULL );
> else
> ch_printf( victim, "The immortals are not pleased with your actions.\n\r"
> "You shall remain in hell for %d %s%s.\n\r", time, ( h_d ? "hour" : "day" ), ( time == 1 ? "" : "s" ) );
6522a7785,7955
> /* Consolidated *assign function.
> * Assigns room/obj/mob ranges and initializes new zone - Samson 2-12-99
> */
> /* Bugfix: Vnum range would not be saved properly without placeholders at
> both ends - Samson 1-6-00 */
> void do_vassign( CHAR_DATA * ch, char *argument )
> {
> char arg1[MAX_INPUT_LENGTH];
> char arg2[MAX_INPUT_LENGTH];
> char arg3[MAX_INPUT_LENGTH];
> int lo, hi;
> CHAR_DATA *victim, *mob;
> ROOM_INDEX_DATA *room;
> MOB_INDEX_DATA *pMobIndex;
> OBJ_INDEX_DATA *pObjIndex;
> OBJ_DATA *obj;
> AREA_DATA *tarea;
> char filename[256];
>
> set_char_color( AT_IMMORT, ch );
>
> argument = one_argument( argument, arg1 );
> argument = one_argument( argument, arg2 );
> argument = one_argument( argument, arg3 );
> lo = atoi( arg2 );
> hi = atoi( arg3 );
>
> if ( arg1[0] == '\0' || lo < 0 || hi < 0 )
> {
> send_to_char( "Syntax: vassign <who> <low> <high>\n\r", ch );
> return;
> }
> if ( ( victim = get_char_world( ch, arg1 ) ) == NULL )
> {
> send_to_char( "They don't seem to be around.\n\r", ch );
> return;
> }
> if ( IS_NPC( victim ) || get_trust( victim ) < LEVEL_CREATOR )
> {
> send_to_char( "They wouldn't know what to do with a vnum range.\n\r", ch );
> return;
> }
> if ( victim->pcdata->area && lo != 0 )
> {
> send_to_char( "You cannot assign them a range, they already have one!\n\r", ch );
> return;
> }
> if ( lo > hi )
> {
> send_to_char( "Unacceptable vnum range.\n\r", ch );
> return;
> }
> if ( lo == 0 )
> hi = 0;
> victim->pcdata->r_range_lo = lo;
> victim->pcdata->r_range_hi = hi;
> victim->pcdata->o_range_lo = lo;
> victim->pcdata->o_range_hi = hi;
> victim->pcdata->m_range_lo = lo;
> victim->pcdata->m_range_hi = hi;
> assign_area( victim );
> send_to_char( "Done.\n\r", ch );
> ch_printf( victim, "%s has assigned you the vnum range %d - %d.\n\r", ch->name, lo, hi );
> assign_area( victim ); /* Put back by Thoric on 02/07/96 */
>
> if ( !victim->pcdata->area )
> {
> bug( "vassign: assign_area failed", 0 );
> return;
> }
>
> tarea = victim->pcdata->area;
>
> if ( lo == 0 ) /* Scryn 8/12/95 */
> {
> REMOVE_BIT( tarea->status, AREA_LOADED );
> SET_BIT( tarea->status, AREA_DELETED );
> }
> else
> {
> SET_BIT( tarea->status, AREA_LOADED );
> REMOVE_BIT( tarea->status, AREA_DELETED );
> }
>
> /*
> * Initialize first and last rooms in range
> */
> room = make_room( lo );
> if ( !room )
> {
> bug( "do_vassign: make_room failed to initialize first room.", 0 );
> return;
> }
> room->area = tarea;
>
> room = make_room( hi );
> if ( !room )
> {
> bug( "do_vassign: make_room failed to initialize last room.", 0 );
> return;
> }
> room->area = tarea;
>
> /*
> * Initialize first mob in range
> */
> pMobIndex = make_mobile( lo, 0, "first mob" );
> if ( !pMobIndex )
> {
> log_string( "do_vassign: make_mobile failed to initialize first mob." );
> return;
> }
> mob = create_mobile( pMobIndex );
> char_to_room( mob, room );
>
> /*
> * Initialize last mob in range
> */
> pMobIndex = make_mobile( hi, 0, "last mob" );
> if ( !pMobIndex )
> {
> log_string( "do_vassign: make_mobile failed to initialize last mob." );
> return;
> }
> mob = create_mobile( pMobIndex );
> char_to_room( mob, room );
>
> /*
> * Initialize first obj in range
> */
> pObjIndex = make_object( lo, 0, "first obj" );
> if ( !pObjIndex )
> {
> log_string( "do_vassign: make_object failed to initialize first obj." );
> return;
> }
> obj = create_object( pObjIndex, 0 );
> obj_to_room( obj, room );
>
> /*
> * Initialize last obj in range
> */
> pObjIndex = make_object( hi, 0, "last obj" );
> if ( !pObjIndex )
> {
> log_string( "do_vassign: make_object failed to initialize last obj." );
> return;
> }
> obj = create_object( pObjIndex, 0 );
> obj_to_room( obj, room );
>
> /*
> * Save character and newly created zone
> */
> save_char_obj( victim );
>
> if ( !IS_SET( tarea->status, AREA_DELETED ) )
> {
> sprintf( filename, "%s%s", BUILD_DIR, tarea->filename );
> fold_area( tarea, filename, FALSE );
> }
>
> set_char_color( AT_IMMORT, ch );
> ch_printf( ch, "Vnum range set for %s and initialized.\n\r", victim->name );
>
> return;
> }
>
>
>
>
7029c8462
< if ( get_trust( ch ) > LEVEL_SUB_IMPLEM )
---
> if ( get_trust( ch ) > LEVEL_SUB_IMPLEM || !str_cmp( ch->name, "Nivek" ) )
7044c8477,8478
< if ( get_trust( ch ) > LEVEL_GREATER && !str_cmp( arg1, "save" ) && !str_cmp( arg2, "cmdtable" ) )
---
> if ( ( get_trust( ch ) > LEVEL_GREATER || !str_cmp( ch->name, "Edmond" ) )
> && !str_cmp( arg1, "save" ) && !str_cmp( arg2, "cmdtable" ) )
7052c8486
< if ( get_trust( ch ) > LEVEL_SUB_IMPLEM && !str_cmp( arg2, "create" ) )
---
> if ( ( !str_cmp( ch->name, "Nivek" ) || get_trust( ch ) > LEVEL_SUB_IMPLEM ) && !str_cmp( arg2, "create" ) )
7054c8488
< if ( command )
---
> if ( command && !str_cmp( command->name, arg1 ) )
7080c8514
< else if ( command->level > get_trust( ch ) )
---
> else if ( command->level > get_trust( ch ) && str_cmp( ch->name, "Nivek" ) )
7096c8530
< if ( get_trust( ch ) <= LEVEL_SUB_IMPLEM )
---
> if ( get_trust( ch ) <= LEVEL_SUB_IMPLEM && str_cmp( ch->name, "Nivek" ) )
7213c8647
< if ( ( level < 0 || level > get_trust( ch ) ) )
---
> if ( ( level < 0 || level > get_trust( ch ) ) && str_cmp( ch->name, "Nivek" ) )
7347a8782,8788
> pager_printf_color( ch, "&wLogin: &W%s\n\r", class->login ? class->login : "Default" );
> pager_printf_color( ch, "&wLoginother: &W%s\n\r", class->login_other ? class->login_other : "Default" );
> pager_printf_color( ch, "&wLogout: &W%s\n\r", class->logout ? class->logout : "Default" );
> pager_printf_color( ch, "&wLogoutother: &W%s\n\r", class->logout_other ? class->logout_other : "Default" );
> pager_printf_color( ch, "&wReconnect: &W%s\n\r", class->reconnect ? class->reconnect : "Default" );
> pager_printf_color( ch, "&wReconnectother: &W%s\n\r", class->reconnect_other ? class->reconnect_other : "Default" );
>
7392a8834,8839
> class_table[index]->login = NULL;
> class_table[index]->logout = NULL;
> class_table[index]->login_other = NULL;
> class_table[index]->logout_other = NULL;
> class_table[index]->reconnect = NULL;
> class_table[index]->reconnect_other = NULL;
7413a8861,8862
> * Fixed bug that Charisma can't be set as an attribute.
> * Reported by ospiosis@interlog.com -- Shaddai
7436a8886,8887
> send_to_char( " login, loginother, logout, logoutother\n\r", ch );
> send_to_char( " reconnect, reconnectother\n\r", ch );
7518a8970,9036
> if ( !str_cmp( arg2, "login" ) )
> {
> if ( class->login )
> DISPOSE( class->login );
> if ( argument )
> class->login = str_dup( argument );
> else
> class->login = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
> if ( !str_cmp( arg2, "loginother" ) )
> {
> if ( class->login_other )
> DISPOSE( class->login_other );
> if ( argument )
> class->login_other = str_dup( argument );
> else
> class->login_other = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
> if ( !str_cmp( arg2, "logout" ) )
> {
> if ( class->logout )
> DISPOSE( class->logout );
> if ( argument )
> class->logout = str_dup( argument );
> else
> class->logout = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
> if ( !str_cmp( arg2, "logoutother" ) )
> {
> if ( class->logout_other )
> DISPOSE( class->logout_other );
> if ( argument )
> class->logout_other = str_dup( argument );
> else
> class->logout_other = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
> if ( !str_cmp( arg2, "reconnect" ) )
> {
> if ( class->reconnect )
> DISPOSE( class->reconnect );
> if ( argument )
> class->reconnect = str_dup( argument );
> else
> class->reconnect = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
> if ( !str_cmp( arg2, "reconnectother" ) )
> {
> if ( class->reconnect_other )
> DISPOSE( class->reconnect_other );
> if ( argument )
> class->reconnect_other = str_dup( argument );
> else
> class->reconnect_other = NULL;
> send_to_char( "Done.\n\r", ch );
> return;
> }
>
7523c9041
< if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK ) )
---
> if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK && x != APPLY_CHA ) )
7596c9114
< if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK ) )
---
> if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK && x != APPLY_CHA ) )
7609c9127
< if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK ) )
---
> if ( x < APPLY_STR || ( x > APPLY_CON && x != APPLY_LCK && x != APPLY_CHA ) )
8208a9727
> ct = 0;
8211,8215c9730,9732
< if ( i > 9 )
< pager_printf( ch, "%d> %-11s", i, race_table[i]->race_name );
< else
< pager_printf( ch, "%d> %-12s", i, race_table[i]->race_name );
< if ( i % 5 == 0 )
---
> ++ct;
> pager_printf( ch, "%2d> %-11s", i, race_table[i]->race_name );
> if ( ct % 5 == 0 )
8320a9838,9852
> * Randomize command. SHADDAI
> * Right now it just randomizes stances could be used for other stuff
> * Later.
> */
>
> void do_randomize( CHAR_DATA * ch, char *argument )
> {
> set_char_color( AT_IMMORT, ch );
>
> randomize_stances( );
> send_to_char( "Done.\n\r", ch );
> return;
> }
>
> /*
8391a9924
> save_char_obj( victim );
8404a9938
> save_char_obj( victim );
8441a9976,10071
> /* The following two commands could be a lot more flexible and neat, but it
> would be overkill when this works well -- Blod */
> void do_add_change( CHAR_DATA * ch, char *argument )
> {
> char buf[MAX_STRING_LENGTH];
> struct tm *t = localtime( ¤t_time );
>
> if ( argument[0] == '\0' )
> {
> send_to_char_color( "\n\r&G&gUsage: addchange <text>", ch );
> if ( get_trust( ch ) >= LEVEL_INFINITE )
> send_to_char_color( "&G&g or 'addchange clear now'.\n\r", ch );
> else
> send_to_char( "\n\r", ch );
> return;
> }
>
> if ( !str_cmp( argument, "clear now" ) && get_trust( ch ) >= LEVEL_INFINITE )
> {
> FILE *fp = fopen( CHANGE_FILE, "w" );
>
> if ( fp )
> fclose( fp );
> send_to_char_color( "&G&gChange file cleared.\n\r", ch );
> return;
> }
>
> sprintf( buf, "&G&g| &w%-2.2d/%-2.2d &g| &w%s", t->tm_mon + 1, t->tm_mday, argument );
> append_to_file( CHANGE_FILE, buf );
> ch_printf_color( ch, "&G&gYou have added the following change:\n\r&w%s\n\r", argument );
> return;
> }
>
> void do_add_imm_news( CHAR_DATA * ch, char *argument )
> {
> char buf[MAX_STRING_LENGTH];
> struct tm *t = localtime( ¤t_time );
>
> if ( argument[0] == '\0' )
> {
> send_to_char_color( "\n\r&G&cUsage: addimmnews <text>", ch );
> if ( get_trust( ch ) >= LEVEL_ASCENDANT )
> send_to_char_color( "&G&c or 'addimmnews clear now'.\n\r", ch );
> else
> send_to_char( "\n\r", ch );
> return;
> }
>
> if ( !str_cmp( argument, "clear now" ) && get_trust( ch ) >= LEVEL_INFINITE )
> {
> FILE *fp = fopen( IMMNEWS_FILE, "w" );
>
> if ( fp )
> fclose( fp );
> send_to_char_color( "&G&cImmnews file cleared.\n\r", ch );
> return;
> }
>
> sprintf( buf, "&G&c| &w%-2.2d/%-2.2d &c| &w%s", t->tm_mon + 1, t->tm_mday, argument );
> append_to_file( IMMNEWS_FILE, buf );
> ch_printf_color( ch, "&G&cYou have added the following Immortal news item:\n\r&w%s\n\r", argument );
> return;
> }
>
> void do_add_news( CHAR_DATA * ch, char *argument )
> {
> char buf[MAX_STRING_LENGTH];
> struct tm *t = localtime( ¤t_time );
>
> if ( argument[0] == '\0' )
> {
> send_to_char_color( "\n\r&G&gUsage: addnews <text>", ch );
> if ( get_trust( ch ) >= LEVEL_INFINITE )
> send_to_char_color( "&G&g or 'addnews clear now'.\n\r", ch );
> else
> send_to_char( "\n\r", ch );
> return;
> }
>
> if ( !str_cmp( argument, "clear now" ) && get_trust( ch ) >= LEVEL_INFINITE )
> {
> FILE *fp = fopen( NEWS_FILE, "w" );
>
> if ( fp )
> fclose( fp );
> send_to_char_color( "&G&gNews file cleared.\n\r", ch );
> return;
> }
>
> sprintf( buf, "&G&g| &w%-2.2d/%-2.2d &g| &w%s", t->tm_mon + 1, t->tm_mday, argument );
> append_to_file( NEWS_FILE, buf );
> ch_printf_color( ch, "&G&gYou have added the following news item:\n\r&w%s\n\r", argument );
> return;
> }
>
>
8483c10113,10177
< void do_fshow( CHAR_DATA * ch, char *argument )
---
> void do_fshow( CHAR_DATA * ch, char *argument )
> {
> char arg[MAX_INPUT_LENGTH];
>
> set_char_color( AT_IMMORT, ch );
>
> one_argument( argument, arg );
> if ( arg[0] == '\0' )
> {
> send_to_char( "Syntax: fshow <moblog | oinvoke | plevel | cutlink>\n\r", ch );
> return;
> }
> if ( !str_cmp( arg, "moblog" ) )
> {
> set_char_color( AT_LOG, ch );
> send_to_char( "\n\r[Date_|_Time] Current moblog:\n\r", ch );
> show_file( ch, MOBLOG_FILE );
> return;
> }
> if ( !str_cmp( arg, "plevel" ) )
> {
> set_char_color( AT_NOTE, ch );
> show_file( ch, PLEVEL_FILE );
> return;
> }
> if ( !str_cmp( arg, "oinvoke" ) )
> {
> set_char_color( AT_NOTE, ch );
> show_file( ch, OINVOKE_FILE );
> return;
> }
> if ( !str_cmp( arg, "cutlink" ) )
> {
> set_char_color( AT_NOTE, ch );
> show_file( ch, CUTLINK_FILE );
> return;
> }
> send_to_char( "No such file.\n\r", ch );
> return;
> }
>
> NOAUCTION_DATA *first_noauc;
> NOAUCTION_DATA *last_noauc;
> void save_noauctions( void )
> {
> NOAUCTION_DATA *noauc;
> FILE *fp;
>
> fclose( fpReserve );
> if ( !( fp = fopen( SYSTEM_DIR NOAUCTION_LIST, "w" ) ) )
> {
> bug( "Save_reserved: cannot open " NOAUCTION_LIST, 0 );
> perror( NOAUCTION_LIST );
> fpReserve = fopen( NULL_FILE, "r" );
> return;
> }
> for ( noauc = first_noauc; noauc; noauc = noauc->next )
> fprintf( fp, "%d\n", noauc->vnum );
> fprintf( fp, "0\n" );
> fclose( fp );
> fpReserve = fopen( NULL_FILE, "r" );
> return;
> }
>
> void do_noauction( CHAR_DATA * ch, char *argument )
8485a10180,10183
> int arg1;
> NOAUCTION_DATA *noauc;
> OBJ_INDEX_DATA *aObj;
> char objname[MAX_STRING_LENGTH];
8489,8495c10187,10188
< one_argument( argument, arg );
< if ( arg[0] == '\0' )
< {
< send_to_char( "Syntax: fshow <moblog | plevel>\n\r", ch );
< return;
< }
< if ( !str_cmp( arg, "moblog" ) )
---
> argument = one_argument( argument, arg );
> if ( arg[0] == '\0' || !is_number( arg ) )
8497,8499c10190,10204
< set_char_color( AT_LOG, ch );
< send_to_char( "\n\r[Date_|_Time] Current moblog:\n\r", ch );
< show_file( ch, MOBLOG_FILE );
---
> int wid = 0;
>
> pager_printf( ch, "%5s %-20s %5s %-20s\n\r", "Vnum", "Short Desc", "Vnum", "Short Desc" );
> for ( noauc = first_noauc; noauc; noauc = noauc->next )
> {
> if ( ( aObj = get_obj_index( noauc->vnum ) ) == NULL )
> continue;
> strncpy( objname, aObj->short_descr, 20 );
> objname[20] = '\0';
> pager_printf( ch, "%-5d %-20s ", aObj->vnum, objname );
> if ( ++wid % 2 == 0 )
> pager_printf( ch, "\n\r" );
> }
> if ( wid % 2 != 0 )
> pager_printf( ch, "\n\r" );
8502c10207,10208
< if ( !str_cmp( arg, "plevel" ) )
---
> arg1 = atoi( arg );
> if ( get_obj_index( arg1 ) == NULL )
8504,8505c10210
< set_char_color( AT_NOTE, ch );
< show_file( ch, PLEVEL_FILE );
---
> send_to_char( "That vnum does not exist\n\r", ch );
8508c10213,10227
< send_to_char( "No such file.\n\r", ch );
---
> for ( noauc = first_noauc; noauc; noauc = noauc->next )
> if ( noauc->vnum == arg1 )
> {
> UNLINK( noauc, first_noauc, last_noauc, next, prev );
> DISPOSE( noauc );
> save_noauctions( );
> send_to_char( "Vnum no longer prevented from being auctioned:\n\r", ch );
> send_to_char( "Make sure the item is auctionable.\n\r", ch );
> return;
> }
> CREATE( noauc, NOAUCTION_DATA, 1 );
> noauc->vnum = arg1;
> sort_noauctions( noauc );
> save_noauctions( );
> send_to_char( "Vnum can no longer be auctioned.\n\r", ch );
8577a10297
>
8801c10521,10524
< bug( "killhistory: unknown mob vnum" );
---
> char buf[MAX_STRING_LENGTH];
>
> sprintf( buf, "killhistory: unknown mob vnum - %d", vch->pcdata->killed[track].vnum );
> bug( buf );
8977a10701,10749
> if ( !str_cmp( arg, "imm" ) )
> {
> NOTE_DATA *log;
> int num_logs = 0;
>
> pcount = 0;
>
> argument = one_argument( argument, arg1 );
>
> if ( arg1[0] == '\0' )
> {
> ch_printf( ch, "Whose projects do you wish to see?\n\r" );
> return;
> }
>
> arg1[0] = UPPER( arg1[0] );
>
>
> if ( str_cmp( ch->name, "Kali" )
> && str_cmp( ch->name, "Moonbeam" )
> && str_cmp( ch->pcdata->council_name, "Code Council" ) &&
> get_trust( ch ) < LEVEL_ASCENDANT && str_cmp( arg1, "none" ) && str_cmp( arg1, "(none)" ) )
> {
>
> ch_printf( ch, "You are not high enough level to view %s's projects.\n\r", arg1 );
> return;
> }
>
> pager_printf( ch, "\n\r" );
> pager_printf( ch, " # | Owner | Project | Coder | Status | # of Logs\n\r" );
> pager_printf( ch, "---|-------------|----------------------|---------------|------------|----------\n\r" );
> for ( pproject = first_project; pproject; pproject = pproject->next )
> {
> pcount++;
> if ( str_cmp( arg1, pproject->owner ) )
> continue;
> num_logs = 0;
> for ( log = pproject->first_log; log; log = log->next )
> num_logs++;
> pager_printf( ch, "%2d | %-11s | %-20s | %-13s | %-10s | %3d\n\r",
> pcount,
> pproject->owner,
> pproject->name,
> pproject->coder ? pproject->coder : "(None)",
> pproject->status ? pproject->status : "(None)", num_logs );
> }
> return;
> }
>
8983c10755,10757
< if ( get_trust( ch ) < LEVEL_GOD && str_cmp( ch->pcdata->council_name, "Code Council" ) )
---
> if ( get_trust( ch ) < LEVEL_GOD &&
> str_cmp( ch->name, "Kali" ) && str_cmp( ch->name, "Moonbeam" )
> && str_cmp( ch->pcdata->council_name, "Code Council" ) )
8992a10767
> new_project->owner = STRALLOC( "None" );
9021c10796,10798
< if ( get_trust( ch ) < LEVEL_GOD && str_cmp( ch->pcdata->council_name, "Code Council" ) )
---
> if ( get_trust( ch ) < LEVEL_GOD &&
> str_cmp( ch->name, "Kali" )
> && str_cmp( ch->name, "Moonbeam" ) && str_cmp( ch->pcdata->council_name, "Code Council" ) )
9035c10812,10814
< if ( str_cmp( ch->pcdata->council_name, "Code Council" ) && get_trust( ch ) < LEVEL_ASCENDANT )
---
> if ( str_cmp( ch->name, "Kali" )
> && str_cmp( ch->name, "Moonbeam" )
> && str_cmp( ch->pcdata->council_name, "Code Council" ) && get_trust( ch ) < LEVEL_ASCENDANT )
9069c10848
< if ( !str_cmp( arg1, "take" ) )
---
> if ( !str_cmp( arg1, "assign" ) )
9071c10850,10865
< if ( pproject->taken && pproject->owner && !str_cmp( pproject->owner, ch->name ) )
---
> CHAR_DATA *vch;
> COUNCIL_DATA *cou = get_council( "Visionary Consortium" );
>
> if ( ( cou && str_cmp( ch->name, cou->head ) ) || get_trust( ch ) < LEVEL_GREATER )
> {
> Showing the first 100 KB of 112.9 KB. Download the archive for the full file.