/* * I put this into player.c cus it made the most sense.. but you can put it * Anywhere.. YOu just need to add this and it to tables.c and mud.h and cedit * it into the mud... * -Gangien */ void do_qptransfer( CHAR_DATA *ch, char *argument ) { char arg[MAX_INPUT_LENGTH]; char arg1[MAX_INPUT_LENGTH]; CHAR_DATA *victim; int amount; argument = one_argument( argument, arg ); argument = one_argument( argument, arg1); if( arg[0] == '\0') { send_to_char("Syntax: qptransfer \n\r", ch); return; } if(( victim = get_char_world( ch, arg )) == NULL) { send_to_char("They are not here.\n\r", ch); return; } if( IS_NPC(victim) ) { send_to_char("What a waste to give it to a MOB...\n\r", ch); return; } if ( !is_number( arg1 ) ) { send_to_char( "Give how much?\n\r", ch ); return; } amount = atoi(arg1); if( amount < 1 ) { send_to_char("So we have a comidian in our mud?\n\r", ch); return; } if( amount > ch->pcdata->quest_curr) { send_to_char("You do not have that much glory", ch); return; } victim->pcdata->quest_curr += amount; victim->pcdata->quest_accum += amount; ch->pcdata->quest_curr -= amount; ch_printf( ch, "You give %s, %d quest points\n\r", victim->name, amount); ch_printf( victim, "You get %d quest points from %s.\n\r", amount, ch->name ); return; }