Пример #1
0
Файл: shop.c Проект: xxx/cdlib
/*
 * Function name: shop_hook_bought_items
 * Description:   Called when player has bought something
 * Arguments:	  arr - The array of objects
 * Returns: 	  1
 */
int
shop_hook_bought_items(object *arr)
{
    write(break_string("You bought " + COMPOSITE_DEAD(arr) + ".\n", 75));
    say(QCTNAME(this_player()) + " bought " + QCOMPDEAD + ".\n");
    return 1;
}
Пример #2
0
Файл: shop.c Проект: xxx/cdlib
/*
 * Function name: shop_hook_sold_items
 * Description:   Hook that is called when player sold something
 * Arguments:	  item - The item array player sold
 * Returns:	  1
 */
int
shop_hook_sold_items(object *item)
{
    write(break_string("You sold " + COMPOSITE_DEAD(item) + ".\n", 75));
    say(QCTNAME(this_player()) + " sold " + QCOMPDEAD + ".\n");
    return 1;
}
Пример #3
0
int
gs_hook_rise()
{
    write("As if ascending from a great depth, you rise to the surface\n" +
	  "of your consciousness. You exhale and feel very relaxed as\n" +
	  "you get up and leave the altar.\n");
    say(QCTNAME(this_player()) + " rises from the altar.\n");
}
Пример #4
0
/*
 * Function name:   wiz_check
 * Description:     Check if a player is a wizard
 * Returns:         0 if the player is a wizard
 *                  1 otherwise
 */
int
wiz_check()
{
    if (this_player()->query_wiz_level())
      	return 0;
    write("Some magic force keeps you from going north.\n");
    say(QCTNAME(this_player()) + " tries to go north but fails.\n");
    return 1;
}
Пример #5
0
Файл: shop.c Проект: xxx/cdlib
/*
 * Function name: shop_hook_fail_storeroom
 * Description  : This function is called when a player tries to enter
 *                the storeroom. The function operates on this_player().
 */
void
shop_hook_fail_storeroom()
{
    write("You are not allowed to enter the store-room.\n");
    say(QCTNAME(this_player()) + " tries in vain to enter the store-room.\n");
}
Пример #6
0
Файл: shop.c Проект: xxx/cdlib
/*
 * Function name: shop_hook_appraise_object
 * Description  : Called when a player asks to see an object for sale.
 */
void
shop_hook_appraise_object(object ob)
{
    say(QCTNAME(this_player()) + " asks to see " + LANG_ASHORT(ob) + ".\n");
}
Пример #7
0
Файл: shop.c Проект: xxx/cdlib
/*
 * Function name: shop_hook_value_asking
 * Description:   What other see when someone evaluates something
 * Arguments:     str - The text form what the player is asking about
 */
void
shop_hook_value_asking(string str)
{
    say(QCTNAME(this_player()) + " asks about some values.\n");
}