DEATH_SH.C

LIB3/OBJ/DEATH_SH.C · 2.1 KB

From the archive nm4dos.zip

Download the archive   « Back to the archive contents

object  my_player;

int     test_add()
{
    return 0;
}
void    attack()
{
}
void    adjust_hp()
{
}
void    set_hp()
{
}
void    do_death()
{
}

void    setup_shadow( object ob )
{
    shadow( ob, 1 );
    my_player = ob;
}

attack_by( object ob )
{
    if( my_player->query_domain() == "flaz" )
	tell_object( ob, "You cannot attack a hologram!\n" );
    else
	tell_object( ob, "You cannot attack a ghost!\n" );
    ob->stop_fight( my_player );
    return 1;
}

attack_ob( object ob )
{
    if( my_player->query_domain() == "flaz" )
	write( "You are just a hologram. You cannot touch anything!\n" );
    else
	write( "Don't be silly. Ghosts haven't anything to attack anyone with.\n" );
    return 0;
}

string short()
{
    if( !my_player )
	return "Death shadow";
    if( (string)my_player->query_domain() == "flaz" )
	return "Hologram of " + my_player->short();

    else
	return "Ghost of " + my_player->short();
}

string long()
{
    if( !my_player )
	return "It is a disembodied spirit.\n";
    if( (string)my_player->query_domain() == "flaz" )
	return "You see a hologrammatic projection of " +
	    my_player->short() + ". " + my_player->query_pronoun() +
	        " looks fair normal apart from the large 'H' on " +
	        my_player->query_possessive() + " forhead, and " +
	        my_player->query_possessive() + " tendancy to flicker a little.\n";

    else
	return "You see the disembodied spirit of " +
	    my_player->short() + ", or rather you see " +
	        "through them. They do not look very healthy " +
	        "right now. Decidedly pale, in fact ... \n";
}

void    dest_death_shadow()
{
    destruct( this_object() );
}

int     cast()
{
    write( "Casting spells when you are dead?\n" );
    return 1;
}

int     do_shout()
{
    write( "You are dead, that is not possible.\n" );
    return 1;
}

int     do_echo()
{
    write( "You are dead...\n" );
    return 1;
}

int     do_guild_command()
{
    write( "You are dead!\n" );
    return 1;
}

int     do_race_command()
{
    write( "You are dead!\n" );
    return 1;
}

int     score()
{
    write( "You have no body, so how can you have stats?\n" );
    return 1;
}

void    second_life()
{
}

Site Stats

Snippets: 1791
Codebases: 571