Angband
Macros | Enumerations | Functions | Variables
option.h File Reference

Options table and definitions. More...

#include "z-file.h"
#include "list-options.h"

Go to the source code of this file.

Macros

#define OP(a, b, c, d)   OPT_##a,
#define OPT(opt_name)   op_ptr->opt[OPT_##opt_name]
#define OPT_PAGE_MAX   OP_SCORE
 Information for "do_cmd_options()".
#define OPT_PAGE_PER   20
#define OPT_PAGE_BIRTH   1

Enumerations

enum  {
  OP_INTERFACE = 0, OP_BIRTH, OP_CHEAT, OP_SCORE,
  OP_SPECIAL, OP_MAX
}
 Option types. More...
enum  { OP, OP }
 Option indexes. More...

Functions

const char * option_name (int opt)
 Functions.
const char * option_desc (int opt)
 Given an option index, return its description.
int option_type (int opt)
 Determine the type of option (score, birth etc)
bool option_set (const char *opt, int val)
 Set an option, return TRUE if successful.
void init_options (void)
 Initialise options to defaults.

Variables

int option_page [OPT_PAGE_MAX][OPT_PAGE_PER]
 The option data structures.

Detailed Description

Options table and definitions.

Copyright (c) 1997 Ben Harrison

This work is free software; you can redistribute it and/or modify it under the terms of either:

a) the GNU General Public License as published by the Free Software Foundation, version 2, or

b) the "Angband licence": This software may be copied and distributed for educational, research, and not for profit purposes provided that this copyright and statement are included in all such copies. Other copyrights may also apply.

Macro Definition Documentation

#define OP (   a,
  b,
  c,
 
)    OPT_##a,
#define OPT (   opt_name)    op_ptr->opt[OPT_##opt_name]

Referenced by auto_pickup_okay(), calc_obj_feeling(), cmd_sub_entry(), collect_known_artifacts(), context_menu_cave(), context_menu_object(), context_menu_player(), context_menu_player_2(), count_known_monsters(), death_randarts(), describe_flavor_text(), display_feeling(), display_knowledge(), display_monster(), display_object(), disturb(), do_cmd_accept_character(), do_cmd_go_down(), do_cmd_go_up(), do_cmd_knowledge_ego_items(), do_cmd_knowledge_monsters(), do_cmd_locate(), do_cmd_query_symbol(), do_cmd_sell(), drop_near(), effect_handler_RECALL(), effect_handler_TELEPORT_LEVEL(), flavor_init(), floor_carry(), get_tag(), grid_data_as_text(), grid_get_attr(), hp_colour_change(), idle_update(), inkey_ex(), keymap_dump(), lore_description(), lore_title(), make_artifact(), make_artifact_special(), make_gold(), map_info(), msg_flush(), new_player_spot(), obj_desc_get_basename(), pick_and_place_distant_monster(), place_new_monster_one(), player_outfit(), price_item(), process_monster(), process_world(), py_attack_real(), ranged_helper(), rd_misc(), recharged_notice(), refresh(), remove_bad_spells(), show_command_list(), sound(), spoil_artifact(), store_display_help(), store_menu_set_selections(), store_sell(), store_update(), store_will_buy_tester(), take_hit(), target_dir_allow(), textui_browse_knowledge(), textui_browse_object_knowledge(), textui_get_aim_dir(), textui_get_command(), textui_get_item(), textui_process_click(), textui_process_command(), ui_keymap_create(), ui_keymap_query(), ui_keymap_remove(), update_mon(), update_smart_learn(), and verify_panel().

#define OPT_PAGE_BIRTH   1
#define OPT_PAGE_MAX   OP_SCORE

Information for "do_cmd_options()".

Referenced by init_options().

#define OPT_PAGE_PER   20

Referenced by init_options(), and option_toggle_menu().

Enumeration Type Documentation

anonymous enum

Option types.

Enumerator:
OP_INTERFACE 
OP_BIRTH 
OP_CHEAT 
OP_SCORE 
OP_SPECIAL 
OP_MAX 
anonymous enum

Option indexes.

Enumerator:
OP 
OP 

Function Documentation

void init_options ( void  )
const char* option_desc ( int  opt)

Given an option index, return its description.

References option_entry::description.

Referenced by option_toggle_display(), and write_character_dump().

const char* option_name ( int  opt)
bool option_set ( const char *  opt,
int  val 
)

Set an option, return TRUE if successful.

References FALSE, op_ptr, player_other::opt, option_is_cheat(), streq, and TRUE.

Referenced by death_randarts(), option_toggle_handle(), and rd_options().

int option_type ( int  opt)

Determine the type of option (score, birth etc)

References option_entry::type.

Referenced by do_cmd_accept_character(), enter_score(), option_is_cheat(), option_toggle_handle(), and write_character_dump().

Variable Documentation

int option_page[OPT_PAGE_MAX][OPT_PAGE_PER]

The option data structures.

Referenced by init_options(), and option_toggle_menu().