 |
Crossfire Server, Trunk
1.75.0
|
Go to the documentation of this file.
10 int account_link(
const char *account_name,
const char *player_name);
46 int hit_map(
object *op,
int dir, uint32_t
type,
int full_hit);
48 int attack_ob(
object *op,
object *hitter);
51 int hit_player(
object *op,
int dam,
object *hitter, uint32_t
type,
int full_hit);
62 void command_me(
object *op,
const char *params);
188 void do_goto(
object *op,
const char *
name,
int x,
int y);
202 int sack_can_hold(
const object *pl,
const object *sack,
const object *op, uint32_t nrof);
203 void pick_up(
object *op,
object *alt);
206 object *
drop_object(
object *op,
object *tmp, uint32_t nrof);
207 void drop(
object *op,
object *tmp);
215 void examine(
object *op,
object *tmp);
268 void command_dm(
object *op,
const char *params);
290 void do_dump(
object *who,
object *what);
302 int infect_object(
object *victim,
object *disease,
int force);
317 void init(
int argc,
char **argv);
341 void check_login(
object *op,
const char *password);
362 int move_ob(
object *op,
int dir,
object *originator);
363 int transfer_ob(
object *op,
int x,
int y,
int randomly,
object *originator);
364 int teleport(
object *teleporter, uint8_t tele_type,
object *user);
366 int push_ob(
object *who,
int dir,
object *pusher);
367 int move_to(
object *op,
int x,
int y);
396 int pets_summon_object(
object *op,
object *caster,
object *spell_ob,
int dir,
const char *stringarg);
430 int fire_bow(
object *op,
object *arrow,
int dir,
int wc_mod, int16_t sx, int16_t sy);
431 void fire(
object *op,
int dir);
432 object *
find_key(
object *pl,
object *container,
object *door);
439 void kill_player(
object *op,
const object *killer);
442 void cast_dust(
object *op,
object *throw_ob,
int dir);
478 int write_rune(
object *op,
object *caster,
object *
spell,
int dir,
const char *runename);
481 int trap_see(
object *op,
object *trap);
482 int trap_show(
object *trap,
object *where);
485 int steal(
object *op,
int dir,
object *
skill);
488 int jump(
object *pl,
int dir,
object *
skill);
506 int change_skill(
object *who,
object *new_skill,
int flag);
508 int do_skill(
object *op,
object *part,
object *
skill,
int dir,
const char *
string);
512 int use_skill(
object *op,
const char *
string);
513 void skill_attack(
object *tmp,
object *pl,
int dir,
const char *
string,
object *
skill);
515 int fire_bolt(
object *op,
object *caster,
int dir,
object *spob);
519 int cast_cone(
object *op,
object *caster,
int dir,
object *
spell);
523 int cast_curse(
object *op,
object *caster,
object *spell_ob,
int dir);
530 int recharge(
object *op,
object *caster,
object *spell_ob);
532 int cast_polymorph(
object *op,
object *caster,
object *spell_ob,
int dir);
534 int cast_create_food(
object *op,
object *caster,
object *spell_ob,
int dir,
const char *stringarg);
535 int probe(
object *op,
object *caster,
object *spell_ob,
int dir,
int level);
540 int cast_wonder(
object *op,
object *caster,
int dir,
object *spell_ob);
543 int magic_wall(
object *op,
object *caster,
int dir,
object *spell_ob);
544 int dimension_door(
object *op,
object *caster,
object *spob,
int dir);
545 int cast_heal(
object *op,
object *caster,
object *
spell,
int dir);
546 int cast_change_ability(
object *op,
object *caster,
object *spell_ob,
int dir,
int silent);
547 int cast_bless(
object *op,
object *caster,
object *spell_ob,
int dir);
548 int alchemy(
object *op,
object *caster,
object *spell_ob);
562 void set_spell_skill(
object *op,
object *caster,
object *spob,
object *dest);
586 int cast_spell(
object *op,
object *caster,
int dir,
object *spell_ob,
char *stringarg);
621 char const*
newhash(
char const *password);
int SP_level_range_adjust(const object *caster, const object *spob)
Adjust the range of the spell based on level.
player * find_player_socket(const socket_struct *ns)
Return a player for a socket structure.
void command_stack_pop(object *op, const char *params)
Pop the stack top.
void fix_weight(void)
Check recursively the weight of all players, and fix what needs to be fixed.
void paralyze_living(object *op, int dam)
Paralyze a living thing.
void command_style_map_info(object *op, const char *params)
Displays information about styles loaded for random maps.
int do_skill(object *op, object *part, object *skill, int dir, const char *string)
Main skills use function-similar in scope to cast_spell().
void apply_changes_to_player(object *pl, object *change, int limit_stats)
Applies (race) changes to a player.
int handle_newcs_player(object *op)
Handles commands the player can send us, and various checks on invisibility, golem and such.
void command_dance(object *op, const char *params)
'dance' command.
void set_spell_skill(object *op, object *caster, object *spob, object *dest)
Utility function to assign the correct skill when casting.
int path_to_player(object *mon, object *pl, unsigned mindiff)
Returns the direction to the player, if valid.
int cftimer_find_free_id(void)
Finds a free ID for a new timer.
void command_shutdown(object *op, const char *params)
Totally shutdowns the server.
const char * party_get_leader(const partylist *party)
Returns the name of the party's leader.
void command_cackle(object *op, const char *params)
'cackle' command.
void command_stack_push(object *op, const char *params)
Push specified item on stack.
int fire_bolt(object *op, object *caster, int dir, object *spob)
Cast a bolt-like spell.
void tick_the_clock(void)
This performs the basic function of advancing the clock one tick forward.
void pets_terminate_all(object *owner)
Removes all pets someone owns.
void command_northeast(object *op, const char *params)
'northeast' command.
static struct Command_Line_Options options[]
Actual valid command line options.
void command_sound(object *op, const char *params)
Player wants to change sound status.
void send_delayed_buffers(player *pl)
Send all delayed buffers for a player.
void command_bleed(object *op, const char *params)
'bleed' command.
void command_glare(object *op, const char *params)
'glare' command.
void command_delete(object *op, const char *params)
Player wants to totally delete her character.
void emergency_save(int flag)
Save all players.
void command_list(object *pl, bool is_dm)
Display the list of commands to a player.
void command_dumpallmaps(object *op, const char *params)
Various map-related statistics.
void command_players(object *op, const char *params)
Display all known players.
void command_nowiz(object *op, const char *params)
Steps down from wizard mode.
void command_snore(object *op, const char *params)
'snore' command.
void command_remove(object *op, const char *params)
Remove an object from its position.
void command_dumpfriendlyobjects(object *op, const char *params)
Various friendly object-related statistics.
void legacy_move_hole(object *op)
object * find_skill_by_number(object *who, int skillno)
This returns the first skill pointer of the given subtype (the one that accumulates exp,...
void hiscore_display(object *op, int max, const char *match)
Displays the high score file.
void command_search_items(object *op, const char *params)
'search-items' command.
void command_wizcast(object *op, const char *params)
Wizard toggling "cast everywhere" ability.
void command_growl(object *op, const char *params)
'growl' command.
void command_say(object *op, const char *params)
'say' command.
int cast_consecrate(object *op, object *caster, object *spell)
A spell to make an altar your god's.
void legacy_animate_trigger(object *op)
int cast_create_food(object *op, object *caster, object *spell_ob, int dir, const char *stringarg)
Create food.
void command_sulk(object *op, const char *params)
'sulk' command.
void monster_npc_say(object *npc, const char *cp)
Simple function to have some NPC say something.
int use_alchemy(object *op)
Handle use_skill for alchemy-like items.
void command_whistle(object *op, const char *params)
'whistle' command.
void send_news(const object *op)
Send the news to a player.
void command_cringe(object *op, const char *params)
'cringe' command.
int monster_can_detect_enemy(object *op, object *enemy, rv_vector *rv)
Determine if we can 'detect' the enemy.
void command_unarmed_skill(object *op, const char *params)
Player wants to change prefered unarmed skill.
void command_clap(object *op, const char *params)
'clap' command.
int roll_stat(void)
This rolls four 1-6 rolls and sums the best 3 of the 4.
int monster_stand_in_light(object *op)
Cache monster_stand_in_light_internal().
void recursive_roll(object *op, int dir, object *pusher)
An object is pushed by another which is trying to take its place.
void command_cough(object *op, const char *params)
'cough' command.
object * find_random_spell_in_ob(object *ob, const char *skill)
This returns a random spell from 'ob'.
void command_spit(object *op, const char *params)
'spit' command.
void command_poke(object *op, const char *params)
'poke' command.
char const * newhash(char const *password)
void command_shrug(object *op, const char *params)
'shrug' command.
int plugins_remove_plugin(const char *id)
Unload the specified plugin.
int plugins_init_plugin(const char *libfile)
Try to load the specified plugin.
void command_time(object *op, const char *params)
Players asks for the time.
int cast_identify(object *op, object *caster, object *spell)
Identifies objects in the players inventory/on the ground.
void command_groan(object *op, const char *params)
'groan' command.
same as sound ncom command like but with extra the client want tick commands so it knows animation timing the client wants to be informed of pickup mode changes Mode will be sent when the player successfully logs and afterward any time the value is but over many options have become defaults This documents those now obsolete client can handle the bit exp values that are now used values are sent as bit Setting this flag also means that skill exp will be and it will be sent in revised method as described in the stats command Value is an integer in string format else Deprecated client should presume all servers support this server will return FALSE Deprecated replaced with sound2 setup command
void remove_locked_door(object *op)
Same as remove_door() but for locked doors.
void command_wave(object *op, const char *params)
'wave' command.
void party_remove(partylist *party)
Removes and frees a party.
int dimension_door(object *op, object *caster, object *spob, int dir)
Teleport through some doors and space.
linked_char * account_get_additional_chars(const char *account_name, const Account_Chars *chars, int *count)
Get a list of character names linked to the specified account which are not listed in chars.
int cast_change_map_lightlevel(object *op, object *spell)
This changes the light level for the entire map.
void command_beg(object *op, const char *params)
'beg' command.
void command_hiccup(object *op, const char *params)
'hiccup' command.
int perceive_self(object *op)
Living thing wants to know information.
void command_me(object *op, const char *params)
'me' command.
void command_south(object *op, const char *params)
'south' command.
int pets_should_arena_attack(object *pet, object *owner, object *target)
Determines if checks so pets don't attack players or other pets should be overruled by the arena petm...
int get_party_password(object *op, partylist *party)
Ask the player for the password of the party she wants to join.
void do_learn_spell(object *op, object *spell, int special_prayer)
Actually makes op learn spell.
Socket structure, represents a client-server connection.
void confuse_living(object *op, object *hitter, int dam)
Confuse a living thing.
void clear_skill(object *who)
This function just clears the chosen_skill and range_skill values in the player.
void make_visible(object *op)
Makes an object visible again.
void flush_old_maps(void)
Reset maps that need to, remove their swap file.
int cast_destruction(object *op, object *caster, object *spell_ob)
Hit all monsters around the caster.
int op_on_battleground(object *op, int *x, int *y, archetype **trophy)
Check if the given object (usually a player) is standing on a battleground tile.
void command_kiss(object *op, const char *params)
'kiss' command.
void command_shout(object *op, const char *params)
'shout' command.
void command_thank(object *op, const char *params)
'thank' command.
void command_disarm(object *op, const char *params)
'disarm' command.
int cast_spell(object *op, object *caster, int dir, object *spell_ob, char *stringarg)
Main dispatch when someone casts a spell.
partylist * party_find(const char *partyname)
Find a party by name.
void command_snap(object *op, const char *params)
'snap' command.
void command_party(object *op, const char *params)
'party' command, subdivided in different sub commands.
void command_execute(object *pl, char *command)
Handle a player-issued command.
void command_wink(object *op, const char *params)
'wink' command.
void monster_check_doors(object *op, mapstruct *m, int x, int y)
Living creature attempts to open a door.
int tailor_god_spell(object *spellop, object *caster)
Changes the attributes of cone, smite, and ball spells as needed by the code.
char ** account_get_players_for_account(const char *account_name)
Returns an array of strings for the characters on this account - the array is null terminated.
void command_recollect(object *op, const char *params)
void accounts_save(void)
Save all the account information.
int detect_curse_on_item(object *pl, object *tmp, object *skill)
Runs a 'detect curse' check on a given item.
void cleanup(void)
Clean up everything and exit.
void command_cast_spell(object *op, const char *params, int cast_now)
Sets up to cast a spell.
void command_run_stop(object *op, const char *params)
Player wants to stop running.
int magic_wall(object *op, object *caster, int dir, object *spell_ob)
This creates magic walls.
void spring_trap(object *trap, object *victim)
This function generalizes attacks by runes/traps.
void check_bullet(object *op)
Checks to see what op should do, given the space it is on (eg, explode, damage player,...
void apply_map_builder(object *pl, int dir)
Global building function.
void command_printlos(object *op, const char *params)
Various LOS-related statistics.
void set_map_timeout(mapstruct *oldmap)
Enable swapping for the given map.
int infect_object(object *victim, object *disease, int force)
Try to infect something with a disease.
void do_dump(object *who, object *what)
int cast_cause_disease(object *op, object *caster, object *spell, int dir)
Let's try to infect something.
void quest_set_player_state(player *pl, sstring quest_code, int state)
Set the state of a quest for a player.
void command_usekeys(object *op, const char *params)
Player wants to change how keys are used.
void command_party_rejoin(object *op, const char *params)
Handles the 'party_rejoin' command.
void monster_check_earthwalls(object *op, mapstruct *m, int x, int y)
Living creature attempts to hit an earthwall.
void get_password(object *op)
Waiting for the player's password.
int write_on_item(object *pl, const char *params, object *skill)
Implement the 'inscription' skill, which checks for the required skills and marked items before runni...
void explode_bullet(object *op)
Causes an object to explode, eg, a firebullet, poison cloud ball, etc.
void command_lock_item(object *op, const char *params)
Alternate way to lock/unlock items (command line).
non standard information is not specified or uptime this means how long since the executable has been started A particular host may have been running a server for quite a long time
void command_hiscore(object *op, const char *params)
Player is asking for the hiscore.
int use_oratory(object *pl, int dir, object *skill)
Oratory skill handling.
void init_ob_methods(void)
Initializes the ob_method system.
void command_invoke(object *op, const char *params)
'invoke' command, fires a spell immediately.
int move_player(object *op, int dir)
Move player in the given direction.
object * races_get_random_monster(const char *race, int level)
Get a random monster of specified race and level at most the specified one.
void command_twiddle(object *op, const char *params)
'twiddle' command.
int SP_level_duration_adjust(const object *caster, const object *spob)
Adjust the duration of the spell based on level.
void command_statistics(object *pl, const char *params)
Prints out some useful information for the character.
int cast_curse(object *op, object *caster, object *spell_ob, int dir)
Curse an object, reducing its statistics.
player * get_player(player *p)
Create a player's object, initialize a player's structure.
void command_northwest(object *op, const char *params)
'northwest' command.
int singing(object *pl, int dir, object *skill)
Singing skill handling.
static const flag_definition flags[]
Flag mapping.
void command_diff(object *op, const char *params)
Get a diff of specified items.
void monster_do_living(object *op)
For a monster, regenerate hp and sp, potentially clear scared status.
int change_skill(object *who, object *new_skill, int flag)
This changes the object's skill to new_skill.
void quest_load_definitions(void)
void read_map_log(void)
Reads temporary maps information from disk.
void command_who(object *op, const char *params)
'who' command.
void command_overlay_reset(object *op, const char *params)
Removes the overlay for op's current map.
void command_throw(object *op, const char *params)
'throw' command.
int skill_ident(object *pl, object *skill)
Main identification skill handling.
void destroy_object(object *op)
Recursively object_free_drop_inventory() op and its inventory.
int cast_raise_dead_spell(object *op, object *caster, object *spell, int dir, const char *arg)
This handles the raise dead / resurrection spells.
void set_first_map(object *op)
This loads the first map an puts the player on it.
void command_puke(object *op, const char *params)
'puke' command.
void free_knowledge(void)
Free all knowledge data.
int write_mark(object *op, object *spell, const char *msg)
This writes a rune that contains the appropriate message.
void shuffle_attack(object *op)
This routine shuffles the attack of op to one of the ones in the list.
int cast_polymorph(object *op, object *caster, object *spell_ob, int dir)
Polymorph spell casting.
int hit_map(object *op, int dir, uint32_t type, int full_hit)
Attack a spot on the map.
object * get_nearest_criminal(object *mon)
void rod_adjust(object *rod)
Adjusts rod attributes.
the faster the spell may be cast there are several other common only the caster may be affected by the spell The most common spell range is that of touch This denotes that the caster much touch the recipient of the spell in order to release the spell monster
void command_debug(object *op, const char *params)
Player wants to see/change the debug level.
int account_link(const char *account_name, const char *player_name)
Adds a player name to an account.
int find_traps(object *pl, object *skill)
Checks for traps on the spaces around the player or in certain objects.
void scroll_failure(object *op, int failure, int power)
op made some mistake with a scroll, this takes care of punishment.
void plugins_display_list(object *op)
Displays a list of loaded plugins (keystrings and description) in the game log window.
void cleanupPlugins(void)
Call the crossfire_plugin::closefunc on the various plugins, used at server shutdown.
void command_whereami(object *op, const char *params)
'whereami' command.
void receive_play_again(object *op, char key)
Player replied to play again / disconnect.
void set_player_socket(player *p, socket_struct *ns)
This copies the data from the socket into the player structure.
int fire_arch_from_position(object *op, object *caster, int16_t x, int16_t y, int dir, object *spell)
Fires an archetype.
void command_overlay_save(object *op, const char *params)
Saves the op's map as an overlay - objects are persisted.
int apply_manual(object *op, object *tmp, int aflag)
Main apply handler.
void move_player_attack(object *op, int dir)
The player is also actually going to try and move (not fire weapons).
void apply_by_living_below(object *pl)
Attempt to apply the object 'below' the player.
int ok_to_put_more(mapstruct *m, int16_t x, int16_t y, object *op, uint32_t immune_stop)
Returns true if it is ok to put spell op on the space/may provided.
void command_arrest(object *op, const char *params)
Wizard jails player.
void add_server_collect_hooks()
void party_obsolete_parties(void)
Remove unused parties (no players).
void command_hug(object *op, const char *params)
'hug' command.
void load_races(BufferReader *reader, const char *filename)
Reads the races file in the lib/ directory, then overwrites old 'race' entries.
void command_face(object *op, const char *params)
Player wants to face a given direction.
void command_rename_item(object *op, const char *params)
Changing the custom name of an item.
void initPlugins(void)
Plugins initialization.
void hiscore_check(object *op, int quiet)
Checks if player should enter the hiscore, and if so writes her into the list.
void key_confirm_quit(object *op, char key)
We receive the reply to the 'quit confirmation' message.
void command_petmode(object *op, const char *params)
Player wants to change how her pets behave.
player * add_player(socket_struct *ns, int flags)
Tries to add player on the connection passwd in ns.
void command_rules(object *op, const char *params)
Display the server rules.
void command_grin(object *op, const char *params)
'grin' command.
object * hit_with_arrow(object *op, object *victim)
hit_with_arrow() disassembles the missile, attacks the victim and reassembles the missile.
object * get_nearest_player(object *mon)
Finds the nearest visible player or player-friendly for some object.
void command_stack_clear(object *op, const char *params)
Empty DM item stack.
void cast_dust(object *op, object *throw_ob, int dir)
Handles op throwing objects of type 'DUST'.
void command_nod(object *op, const char *params)
'nod' command.
void pets_move_golem(object *op)
Handles a golem's movement.
int forbid_play(void)
Checks if server should be started.
int cast_detection(object *op, object *caster, object *spell)
Detect magic or invisible items.
Plugin animator file specs[Config] name
void cast_magic_storm(object *op, object *tmp, int lvl)
This is really used mostly for spell fumbles and the like.
void command_west(object *op, const char *params)
'west' command.
void command_shoottype(object *op, const char *params)
'shoottype' command, set range attack.
int pets_summon_object(object *op, object *caster, object *spell_ob, int dir, const char *stringarg)
General purpose summoning function.
int cast_light(object *op, object *caster, object *spell, int dir)
Illuminates something on a map, or try to blind a living thing.
void command_quit(object *op, const char *params)
Tell players to use the 'delete' command.
void dragon_ability_gain(object *who, int atnr, int level)
When a dragon-player gains a new stage of evolution, he gets some treasure.
void dump_races(void)
Dumps all race information to stderr.
void party_join(object *op, partylist *party)
Makes a player join a party.
void command_rskill(object *pl, const char *params)
'ready_skill' command.
pluglist shows those as well as a short text describing each the list will simply appear empty The keyword for the Python plugin is Python plugout< keyword > Unloads a given identified by its _keyword_ So if you want to unload the Python you need to do plugout Python plugin< libname > Loads a given whose _filename_ is libname So in the case of you d have to do a plugin cfpython so Note that all filenames are relative to the default plugin it tries to load all available files in the SHARE plugins directory as plugin libraries It first displays the Initializing the plugin has the opportunity to signal itself by a message on the console Then the server displays an informative message containing both the plugin content and its keyword For the Python the standard load process thus GreenGoblin When a plugin has been it can request to be warned whenever a global event and are named freely by the developer If the directory doesn t nothing will happen< event name > can be login
void account_password(char *buf, int len, socket_struct *ns)
Handles the account password change.
void knowledge_read(player *pl, object *book)
Player is reading a book, give knowledge if needed, warn player, and such.
void store_spell_expiry(object *spell)
Stores in the spell when to warn player of expiration.
int learn_skill(object *pl, object *scroll)
Player is trying to learn a skill.
void spell_effect(object *spob, int x, int y, mapstruct *map, object *originator)
Inserts into map a spell effect based on other_arch.
void remove_door(object *op)
Remove non locked doors.
static event_registration m
void set_darkness_map(mapstruct *m)
Set the darkness level for a map, based on the time of the day.
void knowledge_send_info(socket_struct *ns)
Send the reply_info for 'knowledge_info'.
void command_malloc(object *op, const char *params)
Display memory information.
partylist * party_get_first(void)
Returns the first party from the list of all parties.
void apply_auto_fix(mapstruct *m)
Go through the entire map (only the first time when an original map is loaded) and performs special a...
void command_banish(object *op, const char *params)
Add player's IP to ban_file and kick them off the server.
object * monster_find_nearest_enemy(object *npc, object *owner)
Returns the nearest enemy (monster or generator) which is visible to npc.
void give_initial_items(object *pl, treasurelist *items)
Gives a new player her initial items.
void command_inventory(object *op, const char *params)
Shows the inventory or some item.
void command_kill_pets(object *op, const char *params)
Player wants to get rid of pets.
int teleport(object *teleporter, uint8_t tele_type, object *user)
Teleport an item around a nearby random teleporter of specified type.
int cast_heal(object *op, object *caster, object *spell, int dir)
Heals something.
int use_skill(object *op, const char *string)
Similar to invoke command, it executes the skill in the direction that the user is facing.
void command_accountpasswd(object *op, const char *params)
int slow_living_by(object *op, const int speed_penalty)
void command_forget_spell(object *op, const char *params)
Command for players to forget a spell.
int spell_find_dir(mapstruct *m, int x, int y, object *exclude)
Search what direction a spell should go in, first the center square then some close squares in the gi...
void command_mark(object *op, const char *params)
'mark' command, to mark an item for some effects (enchant armor, ...).
int pick_lock(object *pl, int dir, object *skill)
Lock pick handling.
object * pets_get_enemy(object *pet, rv_vector *rv)
Given that 'pet' is a friendly object, this function returns a monster the pet should attack,...
void command_teleport(object *op, const char *params)
Teleport next to target player.
void command_unregister(command_registration command)
Unregister a previously registered command.
void command_uskill(object *pl, const char *params)
'use_skill' command.
void send_rules(const object *op)
Send the rules to a player.
int free_no_drop(object *op)
Check whether the given object is FLAG_NO_DROP.
int party_confirm_password(const partylist *party, const char *password)
Checks whether a given password matches the party's password.
void enter_player_savebed(object *op)
This is a basic little function to put the player back to his savebed.
const char * determine_god(object *op)
Determines if op worships a god.
void drop(object *op, object *tmp)
Drop an item, either on the floor or in a container.
void play_again(object *op)
Ask the player whether to play again or disconnect.
void command_dump(object *op, const char *params)
Dumps the difference between an object and its archetype.
int playername_ok(const char *cp)
Is the player name valid.
int remove_curse(object *op, object *caster, object *spell)
This function removes the cursed/damned status on equipped items.
void command_take(object *op, const char *params)
This takes (picks up) an item.
void fire(object *op, int dir)
Received a fire command for the player - go and do it.
object * monster_find_throw_ob(object *op)
Find an item for the monster to throw.
int friendly_fire(object *op, object *hitter)
Find out if this is friendly fire (PVP and attacker is peaceful) or not.
int mood_change(object *op, object *caster, object *spell)
This covers the various spells that change the moods of monsters - makes them angry,...
void blind_living(object *op, object *hitter, int dam)
Blind a living thing.
int cftimer_destroy(int id)
Destroys an existing timer.
int move_ob(object *op, int dir, object *originator)
Op is trying to move in direction dir.
void command_north(object *op, const char *params)
'north' command.
void command_save(object *op, const char *params)
Player wants to get saved.
void command_mon_aggr(object *op, const char *params)
When DM is possessing a monster, flip aggression on and off, to allow better motion.
bool map_can_reset(const mapstruct *map, long current_time)
Returns whether a map can be reset, including all other maps in the same reset group.
int check_race_and_class(living *stats, archetype *race, archetype *opclass)
This checks to see if the race and class are legal.
void monster_do_say(const mapstruct *map, const char *message)
Output a NPC message on a map.
void cftimer_init(void)
Initialize timers.
void check_login(object *op, const char *password)
Actually login a player, load from disk and such.
void command_dropall(object *op, const char *params)
Command to drop all items that have not been locked.
void free_races(void)
Frees all race-related information.
int face_player(object *op, int dir)
Face player in the given direction.
const char * account_get_account_for_char(const char *charname)
This looks at all the accounts and sees if charname is associated with any of them.
treasurelist represents one logical group of items to be generated together.
int remove_trap(object *op, object *skill)
This skill will disarm any previously discovered trap.
void check_physically_infect(object *victim, object *hitter)
Possibly infect due to direct physical contact i.e., AT_PHYSICAL.
int64_t calc_skill_exp(const object *who, const object *op, const object *skill)
Calculates amount of experience can be gained for successful use of a skill.
void remove_unpaid_objects(object *op, object *env, int free_items)
This goes throws the inventory and removes unpaid objects, and puts them back in the map (location an...
void command_ssdumptable(object *op, const char *params)
Various string-related statistics.
void account_char_free(Account_Chars *chars)
This frees all data associated with the character information.
void roll_stats(object *op)
Roll the initial player's statistics.
int set_object_face_main(object *op)
Makes an object's face the main face, which is supposed to be the "closed" one.
void examine_monster(object *op, object *tmp, int level)
Player examine a monster.
void party_leave(object *op)
Makes a player leave his party.
void command_listen(object *op, const char *params)
Change the player's listen level.
void cone_drop(object *op)
Drops an object based on what is in the cone's "other_arch".
void knowledge_add_probe_monster(object *op, object *mon)
Display monster details, then add to a player's knowledge if not already.
int account_remove_player(const char *account_name, const char *player_name)
Removes a player name from an account.
int legal_range(object *op, int r)
Check for the validity of a player range.
void command_loadplugin(object *op, const char *params)
Loads the given plugin.
void command_scream(object *op, const char *params)
'scream' command.
bool player_can_find(object *op, object *ob)
Return true if player 'op' can see object 'op' for purpose of locating items for partial item matchin...
void display_motd(const object *op)
Sends the message of the day to the player.
int apply_container(object *op, object *sack, int aflags)
Handle apply on containers.
int transport_can_hold(const object *transport, const object *op, int nrof)
Can transport hold object op? This is a pretty trivial function, but in the future,...
void move_symptom(object *symptom)
Make the symptom do the nasty things it does.
void free_quest(void)
Free all quest status structures.
void command_follow(object *op, const char *params)
Follow a player, or stop following a player.
void process_events(void)
Process all active objects.
int create_bomb(object *op, object *caster, int dir, object *spell)
Create a bomb.
void enter_player_maplevel(object *op)
Move a player to its stored map level.
void server_main(int argc, char *argv[])
Server main function.
void command_strut(object *op, const char *params)
'strut' command.
void delete_character(const char *name)
Totally deletes a character.
void command_chuckle(object *op, const char *params)
'chuckle' command.
int should_director_abort(const object *op, const object *victim)
Check if op should abort moving victim because of it's race or slaying.
void command_unloadplugin(object *op, const char *params)
Unloads the given plugin.
object * lookup_spell_by_name(object *op, const char *spname)
Look at object 'op' and see if they know the spell spname.
void command_think(object *op, const char *params)
'think' command.
void polymorph(object *op, object *who, int level)
Handles polymorphing an object, living or not.
TIPS on SURVIVING Crossfire is populated with a wealth of different monsters These monsters can have varying immunities and attack types In some of them can be quite a bit smarter than others It will be important for new players to learn the abilities of different monsters and learn just how much it will take to kill them This section discusses how monsters can interact with players Most monsters in the game are out to mindlessly kill and destroy the players These monsters will help boost a player s after he kills them When fighting a large amount of monsters in a single attempt to find a narrower hallway so that you are not being attacked from all sides Charging into a room full of Beholders for instance would not be open the door and fight them one at a time For there are several maps designed for them Find these areas and clear them out All throughout these a player can find signs and books which they can read by stepping onto them and hitting A to apply the book sign These messages will help the player to learn the system One more always keep an eye on your food If your food drops to your character will soon so BE CAREFUL ! NPCs Non Player Character are special monsters which have intelligence Players may be able to interact with these monsters to help solve puzzles and find items of interest To speak with a monster you suspect to be a simply move to an adjacent square to them and push the double ie Enter your message
void do_goto(object *op, const char *name, int x, int y)
int cast_create_town_portal(object *op, object *caster, object *spell)
This function cast the spell of town portal for op.
void command_help(object *op, const char *params)
Player is asking for some help.
void show_skills(object *op, const char *search)
Displays a player's skill list, and some other non skill related info (god, max weapon improvements,...
int quest_was_completed(player *pl, sstring quest_code)
Check if a quest was completed once for a player, without taking account the current state.
void counterspell(object *op, int dir)
Nullifies spell effects.
void party_set_password(partylist *party, const char *password)
Sets a party's password.
void command_examine(object *op, const char *params)
'examine' command.
int trap_disarm(object *disarmer, object *trap, int risk, object *skill)
Try to disarm a trap/rune.
with a maximum of six This is not so if you are wearing plate you receive no benefit Armour is additive with all the supplementry forms of which means that it lasts until the next semi permanent spell effect is cast upon the character spell
void legacy_remove_force(object *op)
void leave(player *pl, int draw_exit)
Player logs out, or was disconnected.
void move_firewall(object *op)
Move for FIREWALL.
void command_free(object *op, const char *params)
Totally free an object.
int account_new(const char *account_name, const char *account_password)
Adds an account.
int create_aura(object *op, object *caster, object *spell)
Create an aura spell object and put it in the player's inventory.
void command_cry(object *op, const char *params)
'cry' command.
int identify_object_with_skill(object *tmp, object *pl, object *skill, int print_on_success)
Helper function for do_skill_ident, so that we can loop over inventory AND objects on the ground conv...
void fix_stopped_item(object *op, mapstruct *map, object *originator)
Put stopped item where stop_item() had found it.
int apply_can_apply_object(const object *who, const object *op)
Checks to see if 'who' can apply object 'op'.
int caster_level(const object *caster, const object *spell)
This function returns the effective level the spell is being cast at.
object * fix_stopped_arrow(object *op)
An ARROW stops moving.
void command_kick(object *op, const char *params)
Kicks a player from the server.
void monster_communicate(object *op, const char *txt)
This function looks for an object or creature that is listening to said text.
void command_pout(object *op, const char *params)
'pout' command.
void command_orcknuckle(object *op, const char *params)
Plays the "orcknucke" game.
void knowledge_item_can_be_used_alchemy(object *op, const object *item)
Displays known alchemy recipes an item can be used in.
The archetype structure is a set of rules on how to generate and manipulate objects which point to ar...
void command_search(object *op, const char *params)
'search' command.
void command_abil(object *op, const char *params)
Changes an object's statistics.
void command_flip(object *op, const char *params)
'flip' command.
int pray(object *pl, object *skill)
Praying skill handling.
void dump_spells(void)
Dumps all the spells - now also dumps skill associated with the spell.
int move_to(object *op, int x, int y)
Move an object one square toward a specified destination on the same map.
void command_possess(object *op, const char *params)
DM can possess a monster.
object * find_key(object *pl, object *container, object *door)
We try to find a key for the door as passed.
void command_language(object *op, const char *params)
This is the 'language' command.
void command_dumpallobjects(object *op, const char *params)
Various object-related statistics.
int skill_throw(object *op, object *part, int dir, object *skill)
Throwing skill handling.
int16_t SP_level_spellpoint_cost(object *caster, object *spell, int flags)
Scales the spellpoint cost of a spell by it's increased effectiveness.
void cftimer_process_timers(void)
Processes all timers.
void get_attack_message_for_attack_type(int dam, uint8_t atm_type, const char *victim_name, char *buf1, char *buf2)
Get the attack message for a damage and a type.
int become_follower(object *op, const object *new_god)
This function is called whenever a player has switched to a new god.
void list_players(object *op, region *reg, partylist *party)
Displays the players in a region or party.
int account_is_logged_in(const char *name)
This checkes if an account is logged in.
void init_signals()
Setup our signal handlers.
int detect_magic_on_item(object *pl, object *tmp, object *skill)
Runs a 'detect magic' check on a given item.
void command_giggle(object *op, const char *params)
'giggle' command.
partylist * party_form(object *op, const char *partyname)
Forms the party struct for a party called 'partyname'.
void regenerate_rod(object *rod)
Regenerates a rod's charges.
void command_hide(object *op, const char *params)
Wizard 'hide' command.
void command_accuse(object *op, const char *params)
'accuse' command.
void accounts_clear(void)
This is used purely by the test harness - by clearing the accounts, it can then verify that the data ...
void command_stay(object *op, const char *params)
'stay' command.
Various statistics of objects.
int push_ob(object *who, int dir, object *pusher)
Something is pushing some other object.
object * find_skill_by_name(object *who, const char *name)
This returns the skill pointer of the given name (the one that accumulates exp, has the level,...
void command_dumpmap(object *op, const char *params)
Various map-related statistics.
static std::shared_ptr< inja::Environment > env
Rendering environment.
void accounts_load(void)
This loads all the account entries into memory.
object * drop_object(object *op, object *tmp, uint32_t nrof)
Try to drop an object on the floor.
void command_settings(object *op, const char *ignored)
Wizard wants to know some server settings, so display.
void command_purge_quest_definitions(object *op, const char *param)
int checkbanned(const char *login, const char *host)
Check if a player and/or host is banned.
int SP_level_wc_adjust(const object *caster, const object *spob)
Returns adjusted wc based on the caster and the spell.
void receive_player_name(object *op, const char *name)
A player just entered her name.
int cast_bless(object *op, object *caster, object *spell_ob, int dir)
Improve statistics of some living object.
void command_east(object *op, const char *params)
'east' command.
void command_dumpbelow(object *op, const char *params)
Player wants to dump object below her.
void command_peaceful(object *op, const char *params)
Player toggles her peaceful status.
int transfer_ob(object *op, int x, int y, int randomly, object *originator)
Move an object (even linked objects) to another spot on the same map.
void monster_check_apply_all(object *monster)
Calls monster_check_apply() for all inventory objects.
void command_wimpy(object *op, const char *params)
Player wants to change how soon she'll flee.
void pets_move(object *ob)
Handles a pet's movement.
void quest_first_player_save(player *pl)
Ensure the quest state is correctly saved for a player.
partylist * party_get_next(const partylist *party)
Returns the next party from the list of all parties.
int move_object(object *op, int dir)
Try to move op in the direction "dir".
int trap_show(object *trap, object *where)
Handles showing a trap/rune detonation.
void free_quest_definitions(void)
void dead_player(object *op)
Kill a player on a permanent death server with resurrection.
int probe(object *op, object *caster, object *spell_ob, int dir, int level)
Try to get information about a living thing.
void key_roll_stat(object *op, char key)
Player is currently swapping stats.
void command_bow(object *op, const char *params)
'bow' command.
void init_skills(void)
This just sets up the skill_names table above.
void command_drop(object *op, const char *params)
'drop' command.
void command_shake(object *op, const char *params)
'shake' command.
void command_use(object *op, const char *params)
Try to use an item on another.
void command_fire_stop(object *op, const char *params)
Player wants to stop firing.
void pets_attempt_follow(object *for_owner, int force)
Check pets so they try to follow their master around the world.
void command_motd(object *op, const char *params)
Display the message of the day.
void command_loadtest(object *op, const char *params)
This command will stress server.
int apply_race_and_class(object *op, archetype *race, archetype *opclass, living *stats)
This is somewhat like key_change_class() above, except we know the race to change to,...
void command_smile(object *op, const char *params)
'smile' command.
reply_type
Various kind of messages a player or NPC can say.
int monster_can_see_enemy(object *op, object *enemy)
Assuming no walls/barriers, lets check to see if its possible to see an enemy.
void command_learn_special_prayer(object *op, const char *params)
Wizard wants to learn a god-given spell.
int apply_auto(object *op)
Map was just loaded, handle op's initialization.
void command_applymode(object *op, const char *params)
Players wants to change the apply mode, ie how to handle applying an item when no body slot available...
int swap_map(mapstruct *map)
Swaps a map to disk.
void command_news(object *op, const char *params)
Display the server news.
void command_quest(object *op, const char *params)
Command handler for 'quest'.
int hideability(object *ob)
Look at the surrounding terrain to determine the hideability of this object.
void command_whereabouts(object *op, const char *params)
'whereabouts' command.
void hiscore_init(void)
Initializes the module.
void apply_handle_yield(object *tmp)
This checks whether the object has a "on_use_yield" field, and if so generated and drops matching ite...
void command_afk(object *op, const char *params)
Toggles the afk status of a player.
void command_summon(object *op, const char *params)
Summons player near DM.
void command_knowledge(object *pl, const char *params)
Handle the 'knowledge' for a player.
void clean_tmp_files(void)
Save unique maps and clean up temporary map files unless recycling temporary maps.
void command_reset(object *op, const char *params)
Resets a map.
const char * get_reply_text_own(reply_type rt)
Return the verb for the player's dialog type.
void command_learn_spell(object *op, const char *params)
Wizard wants to learn a regular spell.
int alchemy(object *op, object *caster, object *spell_ob)
Change items to gold nuggets.
int animate_weapon(object *op, object *caster, object *spell, int dir)
Generalization of staff_to_snake().
void command_version(object *op, const char *params)
Server version.
int SP_level_dam_adjust(const object *caster, const object *spob)
Returns adjusted damage based on the caster.
void command_frown(object *op, const char *params)
'frown' command.
void command_toggle_shout(object *op, const char *params)
A simple toggle for the no_shout field.
const char * party_get_password(const partylist *party)
Returns the party's password.
void commands_init(void)
Init standard commands.
void command_snicker(object *op, const char *params)
'snicker' command.
void dump_quests(void)
Dump all of the quests, then calls exit() - useful in terms of debugging to make sure that quests are...
void command_reply(object *op, const char *params)
Reply to last person who told you something [mids 01/14/2002].
int move_disease(object *disease)
Ticks the clock for disease: infect, aggravate symptoms, ...
void command_strings(object *op, const char *params)
Various string-related statistics.
int apply_check_weapon_power(const object *who, int improves)
This checks to see of the player (who) is sufficient level to use a weapon with improves improvements...
void command_yawn(object *op, const char *params)
'yawn' command.
void enter_exit(object *op, object *exit_ob)
Tries to move 'op' to exit_ob.
void move_player_mover(object *op)
This function takes a PLAYERMOVER as an argument, and performs the function of a player mover,...
object * check_spell_known(object *op, const char *name)
Checks to see if player knows the spell.
void command_setgod(object *op, const char *params)
Sets the god for some objects.
void command_pickup(object *op, const char *params)
'pickup' command.
const typedef char * sstring
void roll_again(object *op)
Ask the player what to do with the statistics.
void monster_npc_call_help(object *op)
A monster calls for help against its enemy.
void command_skills(object *op, const char *params)
Player is asking for her skills.
void party_send_message(object *op, const char *message)
Send a message to all party members except the speaker.
int summon_hostile_monsters(object *op, int n, const char *monstername)
Summons hostile monsters and places them in nearby squares.
void receive_player_password(object *op, const char *password)
A player just entered her password, including for changing it.
int cast_create_obj(object *op, object *new_op, int dir)
Creates object new_op in direction dir or if that is blocked, beneath the player (op).
void command_patch(object *op, const char *params)
Wizard wants to altar an object.
void command_dmtell(object *op, const char *params)
Private communication, by a DM (can't be ignored by player).
int check_pick(object *op)
Sees if there is stuff to be picked up/picks up stuff, for players only.
void command_rotateshoottype(object *op, const char *params)
'rotateshoottype' command, switch range attack.
int pets_summon_golem(object *op, object *caster, int dir, object *spob)
Summons a monster.
void command_shiver(object *op, const char *params)
'shiver' command.
int apply_by_living(object *pl, object *op, int aflag, int quiet)
Living thing is applying an object.
void register_all_ob_types(void)
Calls the intialization functions for all individual types.
void spell_failure(object *op, int failure, int power, object *skill)
Handles the various effects for differing degrees of failure badness.
void command_stats(object *op, const char *params)
Displays the statistics of a player.
void pets_follow_owner(object *ob, object *owner)
A pet is trying to follow its owner.
This is used by get_rangevector to determine where the other creature is.
void init(int argc, char **argv)
This is the main server initialization function.
void command_lick(object *op, const char *params)
'lick' command.
int dispel_rune(object *op, object *skill, int dir)
Someone is trying to disarm a rune.
object * monster_check_enemy(object *npc, rv_vector *rv)
Checks npc->enemy and returns that enemy if still valid, NULL otherwise.
int hit_player(object *op, int dam, object *hitter, uint32_t type, int full_hit)
Object is attacked by something.
void command_chat(object *op, const char *params)
'chat' command.
void do_hidden_move(object *op)
For hidden creatures - a chance of becoming 'unhidden' every time they move - as we subtract off 'inv...
void command_southwest(object *op, const char *params)
'southwest' command.
void do_harvest(object *pl, int dir, object *skill)
Player is trying to harvest something.
void free_server(void)
Frees all memory allocated around here:
int apply_special(object *who, object *op, int aflags)
Apply an object.
void command_bounce(object *op, const char *params)
'bounce' command.
void command_smirk(object *op, const char *params)
'smirk' command.
void command_resistances(object *op, const char *params)
Players wants to know her resistances.
int cast_wonder(object *op, object *caster, int dir, object *spell_ob)
wonder is really just a spell that will likely cast another spell.
int player_arrest(object *who)
Put a player into jail, taking into account cursed exits and player's region.
player * find_player_partial_name(const char *plname)
Find a player by a partial name.
int account_change_password(const char *account_name, const char *current_password, const char *new_password)
Change an account password.
void command_slap(object *op, const char *params)
'slap' command.
void check_spell_expiry(object *spell)
Checks if player should be warned of soon expiring spell.
void command_stack_list(object *op, const char *params)
Displays stack contents.
void command_fire(object *op, const char *params)
Player wants to start firing.
int fire_bow(object *op, object *arrow, int dir, int wc_mod, int16_t sx, int16_t sy)
Creature (monster or player) fires a bow.
Player Stats effect how well a character can survie and interact inside the crossfire world This section discusses the various stats
void change_object(object *op)
Replaces op with its other_arch if it has reached its end of life.
void command_invisible(object *op, const char *params)
Wizard wants to become invisible.
void meditate(object *pl, object *skill)
Meditation skill handling.
int steal(object *op, int dir, object *skill)
Main stealing function.
void command_purge_quest(object *op, const char *param)
int knowledge_player_knows(const player *pl, const char *knowledge)
Determines whether a player knows a specific knowledge or not.
void account_char_add(Account_Chars *chars, player *pl)
This adds a player to the list of accounts.
void command_run(object *op, const char *params)
Player wants to start running.
void command_freeze(object *op, const char *params)
Freezes a player for a specified tick count, 100 by default.
void quest_start(player *pl, sstring quest_code, int state)
Start a quest for a player.
player * find_player_options(const char *plname, int options, const mapstruct *map)
Find a player.
void knowledge_give(player *pl, const char *marker, const object *book)
Give a knowledge item from its code.
int save_player(object *op, int flag)
Saves a player to disk.
int monster_move(object *op)
Main monster processing routine.
void command_maps(object *op, const char *params)
'maps' command.
object * stop_item(object *op)
An item (ARROW or such) stops moving.
void command_dumpabove(object *op, const char *params)
Player wants to dump object above her.
bool can_follow(object *op, player *other)
void(* command_function_extra)(object *op, const char *params, const char *extra)
One command function, with a custom parameter specified at registration time.
Structure handling character information for an account.
void command_dumpallarchetypes(object *op, const char *params)
Various archetypes-related statistics.
int fire_swarm(object *op, object *caster, object *spell, int dir)
The following routine creates a swarm of objects.
command_registration command_register(const char *name, uint8_t type, command_function func, float time)
Register a player-issued command.
void process_object(object *op)
Main object move function.
void command_speed(object *op, const char *params)
Changes the server speed.
void player_set_state(player *pl, uint8_t state)
Set the player's state to the specified one.
int cure_disease(object *sufferer, object *caster, sstring skill)
Do the cure disease stuff, from the spell "cure disease".
int trap_see(object *op, object *trap)
Should op see trap?
int reflwall(mapstruct *m, int x, int y, object *sp_op)
Decides weither the (spell-)object sp_op will be reflected from the given mapsquare.
void command_fix_me(object *op, const char *params)
Wrapper to fix a player.
void inventory(object *op, object *inv)
Prints object's inventory.
SockList * player_get_delayed_buffer(player *pl)
Get a delayed socket buffer, that will be sent after the player's tick is complete.
int player_can_view(object *pl, object *op)
Check the player los field for viewability of the object op.
void command_swap(object *op, const char *params)
Mark a map as ready for swapping.
void do_forget_spell(object *op, const char *spell)
Erases spell from player's inventory.
int cast_change_ability(object *op, object *caster, object *spell_ob, int dir, int silent)
Cast some stat-improving spell.
uint64_t command_registration
Identifier when registering a command.
bool check_password(const char *typed, const char *crypted)
Hash a password and compare it to the stored version.
void do_some_living(object *op)
Regenerate hp/sp/gr, decreases food.
void command_dm(object *op, const char *params)
Actual command to perhaps become dm.
void command_addexp(object *op, const char *params)
This adds exp to a player.
void command_goto(object *op, const char *params)
Wizard teleports to a map.
int object_teleport(object *op, mapstruct *map, int x, int y)
Move the specified object in a free spot around the map's x & y.
void command_empty(object *op, const char *params)
'empty' command.
void command_cointoss(object *op, const char *params)
'cointoss' command.
int cast_word_of_recall(object *op, object *caster, object *spell_ob)
Word of recall causes the player to return 'home'.
void command_tell(object *op, const char *params)
Private communication.
command_registration command_register_extra(const char *name, const char *extra, uint8_t type, command_function_extra func, float time)
Register a player-issued command with an extra parameter.
void command_showpets(object *op, const char *params)
Players wants to know her pets.
Account_Chars * account_char_load(const char *account_name)
For a given account name, load the character information and return it.
void key_change_class(object *op, char key)
This function takes the key that is passed, and does the appropriate action with it (change race,...
void receive_party_password(object *op, const char *password)
Player entered a party password.
int account_check_string(const char *str)
Checks a string to make sure it does not have any invalid characters.
int write_rune(object *op, object *caster, object *spell, int dir, const char *runename)
Player is attempting to write a magical rune.
void knowledge_send_known(player *pl)
Send initial known knowledge to player, if requested.
void fix_luck(void)
Fixes luck of players, slowly move it towards 0.
void check_active_maps(void)
Finds maps in memory to swap.
void account_char_remove(Account_Chars *chars, const char *pl_name)
This removes a character on this account.
void commands_clear()
Clear all registered commands.
void drain_rod_charge(object *rod)
Drain charges from a rod.
Player Stats effect how well a character can survie and interact inside the crossfire world This section discusses the various what they and how they effect the player s actions Also in this section are the stat modifiers that specific classes professions bring Player and sps the current and maximum the Current and Maximum The Current Sp can go somewhat negative When Sp is negative not all spells can be and a more negative Sp makes spell casting less likey to succeed can affect Damage and how the characters as well as how often the character can attack this affects the prices when buying and selling items if this drops the player will start losing hit points wd Cleric or Dwarf sm Elf wd Fireborn ft Human ra Mage C Monk me
int attack_ob(object *op, object *hitter)
Simple wrapper for attack_ob_simple(), will use hitter's values.
int cast_create_missile(object *op, object *caster, object *spell, int dir, const char *stringarg)
Create a missile (nonmagic - magic +4).
int stand_near_hostile(object *who)
Determine if who is standing near a hostile creature.
void command_gsay(object *op, const char *params)
'gsay' command, talks to party.
object * find_target_for_friendly_spell(object *op, int dir)
This function is commonly used to find a friendly target for spells such as heal or protection or arm...
void close_modules()
Clean up all modules which are not disabled.
void command_mapinfo(object *op, const char *params)
'mapinfo' command.
void command_gasp(object *op, const char *params)
'gasp' command.
void command_brace(object *op, const char *params)
Player toggles her braced status.
int cast_transfer(object *op, object *caster, object *spell, int dir)
This spell transfers sp from the player to another person.
void confirm_password(object *op)
Ask the player to confirm her password during creation.
void command_body(object *op, const char *params)
This command dumps the body information for object *op.
int account_login(const char *account_name, const char *account_password)
Check if the given account exists, and whether the password is correct.
void command_passwd(object *pl, const char *params)
Player is asking to change password.
int hide(object *op, object *skill)
Main hide handling.
void(* command_function)(object *op, const char *params)
One command function.
int verify_player(const char *name, char *password)
This verify that a character of name exits, and that it matches password.
void pets_control_golem(object *op, int dir)
Makes the golem go in specified direction.
int check_name(player *me, const char *name)
Ensure player's name is valid.
void command_archs(object *op, const char *params)
void command_sniff(object *op, const char *params)
'sniff' command.
int cast_item_curse_or_bless(object *op, object *spell_ob)
This alters player's marked item's cursed or blessed status, based on the spell_ob's fields.
void save_throw_object(object *op, uint32_t type, object *originator)
Object is attacked with some attacktype (fire, ice, ...).
void command_insert_into(object *op, const char *params)
Puts an object into another.
int cast_smite_spell(object *op, object *caster, int dir, object *spell)
The priest points to a creature and causes a 'godly curse' to descend.
void player_unready_range_ob(player *pl, object *ob)
Unready an object for a player.
void account_char_save(Account_Chars *chars)
Saves the character information for the given account.
int cast_earth_to_dust(object *op, object *caster, object *spell_ob)
Basically destroys earthwalls in the area.
int recharge(object *op, object *caster, object *spell_ob)
Recharge wands.
void pick_up(object *op, object *alt)
Try to pick up an item.
int makes_invisible_to(object *pl, object *mon)
This checks to see if 'pl' is invisible to 'mon'.
void examine(object *op, object *tmp)
Player examines some object.
int sack_can_hold(const object *pl, const object *sack, const object *op, uint32_t nrof)
Check if an item op can be put into a sack.
void kill_player(object *op, const object *killer)
Handle a player's death.
int min_casting_level(const object *caster, const object *spell)
This function takes a caster and spell and presents the effective level the caster needs to be to cas...
void command_apply(object *op, const char *params)
'apply' command.
Contains the base information we use to make up a packet we want to send.
void command_cast(object *op, const char *params)
'cast' command, prepares a spell for laster casting.
object * find_applied_skill_by_name(const object *op, const char *name)
Find a skill by name using the last_skill_ob list.
void command_listplugins(object *op, const char *params)
Lists all plugins currently loaded with their IDs and full names.
void command_bowmode(object *op, const char *params)
Player wants to change the bowmode, how arrows are fired.
object * find_marked_object(object *op)
Return the object the player has marked with the 'mark' command below.
void command_title(object *op, const char *params)
Player wishes to change her title.
void drain_wand_charge(object *wand)
Drains a charge from a wand.
void command_wizpass(object *op, const char *params)
Wizard toggling wall-crossing.
void knowledge_process_incremental(void)
Incrementally send knowledge information to players, and remove information for players who left.
void command_create(object *op, const char *params)
Wizard wants to create an object.
void apply_builder_remove(object *pl, int dir)
Item remover.
int cast_invisible(object *op, object *caster, object *spell_ob)
Makes the player or character invisible.
int monster_compute_path(object *source, object *target, int default_dir)
Computes a path from source to target.
void command_dmhide(object *op, const char *params)
A players wants to become DM and hide.
int cast_cone(object *op, object *caster, int dir, object *spell)
Casts a cone spell.
void command_blush(object *op, const char *params)
'blush' command.
int is_true_undead(object *op)
Is the object a true undead?
archetype * determine_holy_arch(const object *god, const char *type)
Determines the archetype for holy servant and god avatar.
const char * account_exists(const char *account_name)
Checks the existing accounts, and see if this account exists.
void command_sneeze(object *op, const char *params)
'sneeze' command.
void command_burp(object *op, const char *params)
'burp' command.
void account_logout(const char *account_name)
Remove 'account_name' from the list of logged in accounts.
void quest_send_initial_states(player *pl)
Send the current quest states for the specified player, if the client supports those notifications.
void put_object_in_sack(object *op, object *sack, object *tmp, uint32_t nrof)
Something tries to put an object into another.
int quest_get_player_state(player *pl, sstring quest_code)
Get the quest state for a player.
void skill_attack(object *tmp, object *pl, int dir, const char *string, object *skill)
Core routine for use when we attack using a skills system.
int cftimer_create(int id, long delay, object *ob, int mode)
Creates a new timer.
int jump(object *pl, int dir, object *skill)
Jump skill handling.
void pray_at_altar(object *pl, object *altar, object *skill)
Player prays at altar.
void command_southeast(object *op, const char *params)
'southeast' command.
void get_name(object *op)
Waiting for the player's name.
void command_laugh(object *op, const char *params)
'laugh' command.
void knowledge_first_player_save(player *pl)
Ensure the knowledge state is correctly saved for the player.
int players_on_map(mapstruct *m, int show_all)
Returns the count of players on a map, calculated from player list.
player * find_player(const char *plname)
Find a player by her full name.
void command_sigh(object *op, const char *params)
'sigh' command.