fight.c.patch
./rom24mp/fight.c.patch · 1.4 KB
From the archive MobProgs2_4.tar.gz
Download the archive « Back to the archive contents
108a109,116
>
> if ( IS_NPC( ch ) )
> {
> if ( HAS_TRIGGER( ch, TRIG_FIGHT ) )
> mp_percent_trigger( ch, victim, NULL, NULL, TRIG_FIGHT );
> if ( HAS_TRIGGER( ch, TRIG_HPCNT ) )
> mp_hprct_trigger( ch, victim );
> }
742a751
> {
743a753,755
> if ( IS_NPC( victim ) && HAS_TRIGGER( victim, TRIG_KILL ) )
> mp_percent_trigger( victim, ch, NULL, NULL, TRIG_KILL );
> }
930a943,951
> /*
> * Death trigger
> */
> if ( IS_NPC( victim ) && HAS_TRIGGER( victim, TRIG_DEATH) )
> {
> victim->position = POS_STANDING;
> mp_percent_trigger( victim, ch, NULL, NULL, TRIG_DEATH );
> }
>
3382a3404,3415
> void do_surrender( CHAR_DATA *ch, char *argument )
> {
> CHAR_DATA *mob;
> if ( (mob = ch->fighting) == NULL )
> {
> send_to_char( "But you're not fighting!\n\r", ch );
> return;
> }
> act( "You surrender to $N!", ch, NULL, mob, TO_CHAR );
> act( "$n surrenders to you!", ch, NULL, mob, TO_VICT );
> act( "$n tries to surrender to $N!", ch, NULL, mob, TO_NOTVICT );
> stop_fighting( ch, TRUE );
3383a3417,3424
> if ( !IS_NPC( ch ) && IS_NPC( mob )
> && ( !HAS_TRIGGER( mob, TRIG_SURR )
> || !mp_percent_trigger( mob, ch, NULL, NULL, TRIG_SURR ) ) )
> {
> act( "$N seems to ignore your cowardly act!", ch, NULL, mob, TO_CHAR );
> multi_hit( mob, ch, TYPE_UNDEFINED );
> }
> }