 |
Crossfire Server, Trunk
1.75.0
|
Go to the documentation of this file.
52 if (!strcmp(
name,
"north"))
54 if (!strcmp(
name,
"north_east"))
56 if (!strcmp(
name,
"east"))
58 if (!strcmp(
name,
"south_east"))
60 if (!strcmp(
name,
"south"))
62 if (!strcmp(
name,
"south_west"))
64 if (!strcmp(
name,
"west"))
66 if (!strcmp(
name,
"north_west"))
81 object *op = animation->
victim;
121 object *op = animation->
victim;
163 cf_log(
llevError,
"CFAnim: Error in animation - possible values for 'invisible' are 'yes' and 'no'\n");
182 cf_log(
llevError,
"CFAnim: Error in animation - possible values for 'wizard' are 'yes' and 'no'\n");
201 cf_log(
llevDebug,
"CFAnim: init say: parameters: %s\n", parameters ? parameters :
"null");
211 cf_log(
llevError,
"CFAnim: Error in animation: nothing to say with say function\n");
223 object *current_container;
251 if (current->
name == parameters)
316 if (current->name == parameters) {
332 cf_log(
llevError,
"CFAnim: Error in animation: possible values for 'ghosted' are 'yes' and 'no'\n");
340 || (!
id && !animation->
ghosted))
348 corpse->
contr = NULL;
352 animation->
corpse = corpse;
385 mapname = strstr(parameters,
" ");
390 mapx = atoi(parameters);
392 parameters = mapname;
393 assert(parameters != NULL);
395 mapname = strstr(parameters,
" ");
400 mapy = atoi(parameters);
402 if (mapname[0] ==
'\0')
464 if (sscanf(parameters,
"%d %d", &x, &y) != 2)
507 if (parameters && animation->
victim->
map) {
520 if (sscanf(parameters,
"%ld", &connection) != 1 || connection <= 0) {
546 if (olp->
value ==
id) {
654 while (fgets(
buffer, buffer_size, fichier)) {
678 parameters = strstr(
name,
" ");
682 while (*parameters ==
' ')
684 if (*parameters ==
'\0')
693 if (!animationhook) {
709 current->
next = next;
728 if (!strcmp(&
buffer[strlen(
buffer)-strlen(
"\n")],
"\n"))
730 *value = strstr(
buffer,
"=");
737 (*variable)[strlen(*
variable)-1] =
'\0';
738 while ((strlen(*value) > 0) && ((*value)[strlen(*value)-1] ==
' '))
739 (*value)[strlen(*value)-1] =
'\0';
740 while (**value ==
' ')
742 if ((**
variable ==
'\0') || (**value ==
'\0'))
769 else if (*strg ==
'n')
771 else if (*strg ==
'Y')
773 else if (*strg ==
'N')
775 else if (*strg ==
'1')
777 else if (*strg ==
'0')
793 if (current->
victim == ob) {
834 while (origin && !origin->
map)
835 origin = origin->
env;
837 if (!origin || !origin->
map)
845 for (x = 0; x < w; x++) {
846 for (y = 0; y < h; y++) {
848 if (ob->name == sname)
872 object *victim = NULL;
874 int always_delete = 0;
881 int errors_allowed = 0;
883 const char *animationitem = NULL;
887 int errors_found = 0;
890 fichier = fopen(file,
"r");
891 if (fichier == NULL) {
900 if (!strcmp(
buffer,
"\n"))
909 if (strncmp(
buffer,
"[Config]", 8)) {
910 cf_log(
llevError,
"CFAnim: Fatal error in %s: [Config] must be the first group defined.\n", file);
919 if (!strcmp(
buffer,
"\n"))
927 if (value[strlen(value)-1] ==
'"')
928 value[strlen(value)-1] =
'\0';
930 }
else if (!strcmp(
variable,
"victimtype")) {
931 if (!strcmp(value,
"player"))
933 else if (!strcmp(value,
"object"))
935 else if (!strcmp(value,
"any"))
937 else if (!strcmp(value,
"byname"))
941 }
else if (!strcmp(
variable,
"victim")) {
943 if (!strcmp(value,
"who"))
945 else if (!strcmp(value,
"activator"))
947 else if (!strcmp(value,
"who_owner"))
950 cf_log(
llevError,
"CFAnim: Warning: object \"who\" doesn't exist and you're victimized it's owner\n");
953 else if (!strcmp(value,
"activator_owner"))
956 cf_log(
llevError,
"CFAnim: Warning: object \"activator\" doesn't exist and you're victimized it's owner\n");
958 victim = activator->
env;
959 else if (victimtype == 3) {
963 }
else if (!strcmp(
variable,
"unique")) {
966 }
else if (!strcmp(
variable,
"always_delete")) {
969 }
else if (!strcmp(
variable,
"delete_event_end")) {
972 }
else if (!strcmp(
variable,
"parallel")) {
975 }
else if (!strcmp(
variable,
"paralyzed")) {
978 }
else if (!strcmp(
variable,
"invisible")) {
981 }
else if (!strcmp(
variable,
"wizard")) {
984 }
else if (!strcmp(
variable,
"errors_allowed")) {
987 }
else if (!strcmp(
variable,
"verbose")) {
990 }
else if (!strcmp(
variable,
"time_representation")) {
991 if (!strcmp(value,
"second"))
993 else if (!strcmp(value,
"tick"))
997 }
else if (!strcmp(
variable,
"animation")) {
1012 cf_log(
llevError,
"CFAnim: Errors occurred during the parsing of %s\n", file);
1016 if (!animationitem) {
1017 cf_log(
llevError,
"CFAnim: no animation specified when using %s\n", file);
1035 if (always_delete) {
1040 if (((victim->
type ==
PLAYER) && (victimtype == 1))
1041 || ((victim->
type !=
PLAYER) && (victimtype == 0))
1042 || (errors_found && !errors_allowed)) {
1044 cf_log(
llevError,
"CFAnim: No correct victim found or errors found, aborting.\n");
1051 if (unique && !always_delete) {
1057 current_anim->
victim = victim;
1058 current_anim->
event = event;
1059 current_anim->
paralyze = paralyzed;
1061 current_anim->
wizard = wizard;
1062 current_anim->
unique = unique;
1065 current_anim->
corpse = NULL;
1067 current_anim->
verbose = verbose;
1071 while (
buffer[0] ==
'[') {
1072 while (strncmp(&
buffer[1], animationitem, strlen(animationitem))) {
1076 if (value == NULL) {
1077 cf_log(
llevError,
"CFAnim: no matching animation %s in file.\n", animationitem);
1150 time_t sec_elapsed = second.tv_sec - first.tv_sec;
1151 long nsec_elapsed = second.tv_nsec - first.tv_nsec;
1152 return (sec_elapsed * 1e6) + (nsec_elapsed / 1e3);
1162 struct timespec now;
1163 static struct timespec yesterday;
1164 static int already_passed = 0;
1165 long int delta_milli;
1167 clock_gettime(CLOCK_MONOTONIC, &now);
1168 if (!already_passed) {
1191 free(current->
name);
1195 previous_anim = current;
1220 const char *propname;
1224 va_start(args,
type);
1225 propname = va_arg(args,
const char *);
1227 if (!strcmp(propname,
"Identification")) {
1228 buf = va_arg(args,
char *);
1229 size = va_arg(args,
int);
1233 }
else if (!strcmp(propname,
"FullName")) {
1234 buf = va_arg(args,
char *);
1235 size = va_arg(args,
int);
1265 va_start(args,
type);
1266 event_code = va_arg(args,
int);
1281 object *who, *activator, *event;
1284 va_start(args,
type);
1286 who = va_arg(args,
object *);
1287 activator = va_arg(args,
object *);
1288 va_arg(args,
object *);
1289 buf = va_arg(args,
char *);
1297 query = va_arg(args,
int);
1298 event = va_arg(args,
object *);
1300 if (query == 1 && strcmp(
message,
"query_object_is_animated") == 0) {
1311 if (activator != NULL) {
1313 }
else if (who != NULL) {
Available animation move.
@ mr_again
Move should continue next time.
static void animate_one(CFanimation *animation, long int milliseconds)
Checks if an animation can execute one or more moves, and if so does them.
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 se Ninja hi Priest C Quetzalcoatl mw Swashbuckler si Thief st Viking ba Warrior or Wizard C Wraith C Class Prof Str Dex Con Wis Cha Int Pow Net Skills Enclosed are codes used for the skills above The ones in and fighting should all be pretty self explanatory For the other skills
static long int initsay(const char *name, char *parameters, CFmovement *move_entity)
void cf_log(LogLevel logLevel, const char *format,...)
Wrapper for LOG().
int cf_map_get_height(mapstruct *map)
sstring cf_add_string(const char *str)
Wrapper for add_string().
#define FOR_MAP_FINISH()
Finishes FOR_MAP_PREPARE().
sstring cf_map_get_sstring_property(mapstruct *map, int propcode)
static struct Command_Line_Options options[]
Actual valid command line options.
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 occurs(global events are 'shout', 'login', 'death', and so on). A complete list of events is available in the include/plugin.h file. Specific notes related to the Python plugin. -------------------------------------------- The Python plugin supports all global events. The const ant PYTHON_DEBUG defined at the start of the plugin_python.c file increases the verbosity of the plugin. Global event scripts go into SHARE/maps/python/events/< event name >
#define AP_APPLY
Item is to be applied.
@ llevError
Error, serious thing.
int cf_object_teleport(object *ob, mapstruct *map, int x, int y)
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 se Ninja hi Priest C Quetzalcoatl mw Swashbuckler si Thief st Viking ba Warrior or Wizard C Wraith C Class Prof Str Dex Con Wis Cha Int Pow Net Skills Enclosed are codes used for the skills above The ones in and fighting should all be pretty self explanatory For the other a brief description is for a more detailed look at the skills doc file Skill remove use magic items C
void cf_object_apply_below(object *pl)
Wrapper for apply_by_living_below().
static anim_move_result runsay(CFanimation *animation, long int id, void *parameters)
CF_PLUGIN int eventListener(int *type,...)
time_enum
Time units the animation can use.
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
CF_PLUGIN anim_move_result cfanim_runPluginCommand(object *op, char *params)
oblinkpt * next
Next value in the list.
#define NDI_GREEN
SeaGreen.
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the you MUST download a map set point to where you installed Crossfire install Grab map set from official SourceForge page The following sets are at ZipGenius
static long int initapply(const char *name, char *parameters, CFmovement *move_entity)
static void prepare_commands(void)
static int ordered_commands
oblinkpt * buttons
Linked list of linked lists of buttons.
static anim_move_result runmoveto(CFanimation *animation, long int id, void *parameters)
static long int initmoveto(const char *name, char *parameters, CFmovement *move_entity)
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the server
static anim_move_result runghosted(CFanimation *animation, long int id, void *parameters)
char * cf_strdup_local(const char *str)
Wrapper for strdup_local().
static long int initwizard(const char *name, char *parameters, CFmovement *move_entity)
#define FOR_BELOW_PREPARE(op_, it_)
Constructs a loop iterating over all objects below an object.
float speed
Frequency of object 'moves' relative to server tick rate.
int16_t invisible
How much longer the object will be invis.
CF_PLUGIN int closePlugin(void)
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 but due to updates or the length of time the server instance has been up may be much shorter MN US< br > link< br >< a href="http: text_comment=Latest SVN 1.x branch, Eden Prairie, MN US archbase=Standard mapbase=Standard codebase=Standard num_players=3 in_bytes=142050710 out_bytes=-1550812829 uptime=909914 version=1.11.0 sc_version=1027 cs_version=1023 last_update=1214541369 END_SERVER_DATA ---- Multigod -------- This is a brief description of the MULTIGOD hack. It is preserved here for mostly historical reasons. Introduction ~~~~~~~~~~~~ The intention of this code is to enhance the enjoy-ability and playability of clerical characters in the new skills/exp scheme. This is done by giving players gods to worship who in turn effect clerical magic and powers. Included in this patch are several new spells which (hopefully) will allow the priest characters a better chance to gain xp at higher levels. Notably, the "holy orb" and "holy word" spells have been revamped. When MULTIPLE_GODS flag is defined in include/config.h, this code is enabled. This code (described below) encompasses 3 main parts: an array of gods that players/NPCs may worship, new clerical spells which rely on the worshiped god's attrib- utes in Gods[] array and, altars/praying--the interface between a worshiper and their god. b.t. thomas@astro.psu.edu Implementation Details ~~~~~~~~~~~~~~~~~~~~~~ This code is flexible and easy to configure (just edit the god archetypes). Part of the reason for creating this code was to allow server maintainers to develop their own "mythos". From my personal point of view, I hate having the old "Christian" aligned mythos, but if that's what you like, you can replicate it with this code too (see below). Properties of the Gods ~~~~~~~~~~~~~~~~~~~~~~ Here is a fuller description of Gods archetype values. ---- name - name of the god (required) other_arch - archetype that will be used for the summon holy servant spell. title - diametrically opposed god, leave blank if none exists attacktype - favored attack of this god, used in spells of summon avatar, holy word. Recipients of "holy possession" get this too. immune - Avatars/holy servants/recipient of "holy possession" gets this. protected - all of the above AND recipient of god's blessing and the priest of this god gets this. vulnerable - Avatar/servant/recipient of gods curse/priest of this god get this. path_attuned - priest of this god and recipient of "bless" gets this path_repelled - priest and recipient of "curse" gets this path_denied - priest and recipient of "curse" gets this slaying - comma delimited list of the races of creatures that are aligned with the god. "summon cult monsters" uses. this list to find creatures. Summon avatar/call servant code assigns this value to prevent them from attacking aligned races. Value is blank if no race(s) exists. race - comma delimited list of the races of creatures "holy word", "holy possession" spells will effect. Value entry is blank if no such race(s) exists. hp,dam,ac,wc - base stats for the summoned avatar. ---- IF MORE_PRIEST_GIFTS is defined (in gods.c) then ADDITIONAL gifts/limitations will be assigned to the priest: Flags ^^^^^ Now, the following flags, in addition to being used by the god (if planted on a map) are assigned to the worshiping priest: can_use_weapon, can_use_armour, is_undead, is_blind, reflect_missile, reflect_spell, make_invisible, stealth, can_see_in_dark, xrays NOTE: if can_use_armour/can_use_weapon flags are NOT present, then the priest will be forbidden the use of these items. Stats ^^^^^ The following stats are used: ---- luck - how lucky the god (and the priest) are. last_eat - how fast priest digestion is last_hp - how fast priest healing is last_sp - how fast priest mana regeneration is last_grace - how fast priest grace regeneration is ---- Designing New Gods ~~~~~~~~~~~~~~~~~~ To examine the gods properties, use the '-m8' flag (ie 'crossfire -m8'). Note some of the big differences here in terms of spell_paths, races, etc. Most of these entries were designed with roughly polar opposite gods. For designing new gods. You should make sure that worshiping a god will be "unique" in some way. But playbalance first! You must consider the balance between the following: . spellpaths . priest gifts . priest limitations . special spells . attacktypes . summoned monster lists . properties of the avatar and holy servant. Here are some hard and fast rules for designing gods: - Decide how the cleric will get experience. The god should be either a 'summoning', 'turning' *or* a 'wounding' god. If summoning/turning, make sure the aligned_race/enemy_race list(s) has enough creatures to summon/slay at low, medium and high levels. DONT give a god attuned to wounding AND turning||summoning (in fact, at minimum, one of these 3 paths should be repelled/denied). - make sure the summoned avatar is stronger than the servant (!) - examine the avatar/servant stats. If set inproperly, you will give wimpy/super values. For example, Avatars/servants with less than 50 hp (and a high ac/no armour) will vanish quickly. Shoot for stats like: ---- type | A V E R A G E S T A T S | hp | ac | wc | arm | dam | speed ----------|----------------------------------- servant | 50 | 5 | 5 | 20 | 5 | 0.15 avatar | 350 | -5 | -1 | 50 | 50 | 0.25 ---- Its difficult to give measurements on how to trade these off. To help guide your choices try to conserve the value of speed*dam and (armour+1)*hp. * avoid giving the potent attacktypes of death, weaponmagic and paralysis. * gods have a vulnerability for every immunity. Not all attacktypes are the same. Immunity to physical, magic and common attacktypes (like fire/cold/electric) are very potent. Similarly, vuln to these is a big negative. * SPELL paths. Carefull treatment is needed here. Give a path_denied/ or a couple path_repelled for every path_attuned. BUT note: not all paths are of equal use. (ex path_abjuration has a very large list of spells). The main clerical paths are restoration, abjuration, protection, turning, wounding and summoning. For balance, make 3-4 of these repelled/denied and 1 or 2 attuned. Be sure to check out the special spells list (below). Attuned paths like DEATH, WOUNDING and (especially) PROTECTION are very potent. Allow for some balance else where if you assign (one!) of these as a path_attuned. * If using the MORE_PRIEST_GIFTS define: priest limitations of no weapons and no armour are very negative, be sure to compensate with more than an attunded path. Of course, you may break these 'rules' to create your god. When you do that, you had better make up for the bonus elsewhere! Otherwise, you will create a 'mega-god' whose worship (by the player priests) will unbalance the game. Designing a good god takes a bit of work. Special Spells ~~~~~~~~~~~~~~ Here is a possibly *incomplete* list of the special spells that a god may grant use to a worshiper. Check the file spellist.h for the 0 bookchance clerical spells to find all of these. (This list was complete on 10/96). ---- INFO perceive self PROTECTION defense; immuntity to cold, fire, electricity, poison, slow, paralysis, draining, attack, and magic RESTORE remove damnation; reincarnation; raise dead; resurrection; regeneration WOUNDING cause critical wounds; retributive strike LIGHT daylight; nightfall DEATH face of death; finger of death SUMMONING insect plague CREATE wall of thorns ---- Ideas ~~~~~ * Allow sacrifices. This is an excellent way to give a cleric xp. Need to create enemy_race creatures w/ bodyparts we can sacrifice, and designate a pointer in Gods to the appropriate array of stuff we can sacrifice for xp. Experience ---------- Obsolete file kept for historical reasons. Introduction ~~~~~~~~~~~~ This patch represents a "developer 's" version of the exp/skills system. While I have now achieved all of the objectives in sections "B" and "C" of the coding proposal (see README.PROPOSAL) and have play-tested as much of the code as possible, I am sure some big bugs must remain. (One for sure is that exp gained when using rod/horn/wand is wrong.) Below this section I outline 1) coding philosophy, 2) gross description of how the code impinges/interacts within older code. 3) designer's notes on the changes to the code. Comments on any area of this coding would be appreciated. Personally, I would like to see the Pow stat and a 2-type system of magic come into being. After all of you check out the code, I would like to discuss enhancements/bug fixes/implementation. For instance, is it too hard to figure out how to use the code! Sometime tomorrow exp2.tar.gz will be available in pub/thomas on ftp.astro.psu.edu. b.t. Code Philosophy ^^^^^^^^^^^^^^^ To move CF over to a new skills-based experience system. In this implementation several kinds of experience will exist. Players will gain experience in each kind of experience (or category) based on their actions in the game. The sum of all the various categories of experience equals the player "score", from which dam, wc, and hp are determined. All experience gaining actions will be through the use of certain skills -- so called "associated skills". Associated skills are each related to 1 kind of experience. Thus, for example, "stealing" is a skill associated with "agility" experience. There exists also "miscellaneous" skills which allow the use of a unique skill, but which are not related to any kind of experience and whose use does not generate experience points. In this implementation, skills and objects are both treated as objects in the inventory of the user. Experience "objects" each represent one kind of experience and are always invisible. Skills objects each represent one kind of skill available in the game. Skills objects may either be invisible or have an associated bitmap (in which case they are "tools"). All experience gaining actions will be through the use of certain skills -- called "associated skills". Associated skills are each related to 1 kind of experience. Thus, for example, "stealing" is a skill associated with "agility" experience. Both Players and NPC's may only use skills which are in their inventories. NPC's do not use experience objects. A breakdown of the properties of skills and exp objects objects is as follows: ---- Object Property NPC use? ------ ----------------------------------- ------- Experience Each represents a different kind of NO experience in the game. The object in the player inventory keeps track of player experience in that category. Always is invisible. Skill- Represents a skill the player may YES associated perform. May be either invisible or visible as a "tool". Successful use of this skill generates experience. Experience is allocated to appropriate experience object. Skill- Same as above, *but* this skill is not YES miscell. related to any experience category, and use of this skill generates *no* experience. ---- Linking of associated skills to experience categories is done during initialization of the code (in init()) based on the shared stats of both. How skills and experience categories are named and linked may be changed by editing the skills/experience object archetypes. Implementation Details ~~~~~~~~~~~~~~~~~~~~~~ The most important thing is that I moved most of the code into the server/skills.c and server/skill_util.c files. The skills code is loosely implemented along the lines of the spell code. This is to say that: . skills use (do_skill) is called from fire(). . there is a skills[] table similar to spells[]. . server files skills.c and skill_util.c parallel spell_effect.c and spell_util.c in respective functionallity. Particular notes about the implementation are outlined below. Defines ^^^^^^^ #define MAX_EXP_CAT be > I had to make use of several global parameters These swamp
float speed_left
How much speed is left to spend this round.
static anim_move_result runwizard(CFanimation *animation, long int id, void *parameters)
struct mapstruct * map
Pointer to the map in which this object is present.
Destination for moveto command.
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
int cf_object_apply(object *op, object *author, int flags)
Wrapper for apply_manual().
int tick
Move duration, units depending on parent's time_representation.
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 in
int cf_object_move_to(object *op, int x, int y)
Wrapper for move_to().
void cf_object_free_drop_inventory(object *ob)
Wrapper for object_free_drop_inventory().
#define FLAG_WIZCAST
The wizard can cast spells in no-magic area.
sstring cf_find_string(const char *str)
static long int initnotice(const char *name, char *parameters, CFmovement *move_entity)
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 and press< Return > You can also use say if you feel like typing a little extra Other NPCs may not speak to you
Used to link together several object links.
int cf_player_move(player *pl, int dir)
static anim_move_result runteleport(CFanimation *animation, long int id, void *parameters)
@ mr_finished
Move completed.
And the skill structure used by the skills[] table is
static long int initteleport(const char *name, char *parameters, CFmovement *move_entity)
static int get_boolean(const char *strg, int *bl)
This function gets a string containing [Y/y](es)/[N/n](o), 1/0 and set bl according to what's read if...
static object * find_by_name(object *origin, const char *name)
#define HUGE_BUF
Used for messages - some can be quite long.
static long int initvisible(const char *name, char *parameters, CFmovement *move_entity)
static anim_move_result rundropobject(CFanimation *animation, long int id, void *parameters)
Plugin animator file specs[Config] name
#define FOR_BELOW_FINISH()
Finishes FOR_BELOW_PREPARE().
Release notes for Crossfire September
long int id
Identifier, used for various things.
int16_t y
Position in the map for this object.
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 and press< Return > You can also use say if you feel like typing a little extra Other NPCs may not speak to but display intelligence with their movement Some monsters can be and may attack the nearest of your enemies Others can be in that they follow you around and help you in your quest to kill enemies and find treasure SPECIAL ITEMS There are many special items which can be found in Crossfire
CFAnimRunFunc funcrun
Function to run the move.
static anim_move_result runtrigger(CFanimation *animation, long int id, void *parameters)
struct player * contr
Pointer to the player which control this object.
int teleport(object *teleporter, uint8_t tele_type, object *user)
Teleport an item around a nearby random teleporter of specified type.
static int start_animation(object *who, object *activator, object *event, const char *file, const char *message)
Create a new animation object according to file, option and activator (who)
How to Install a Crossfire Server on Windows
the server will also quite happily load unpacked files as long as they have the right file which is convenient if you want to edit your maps and archetypes live It also contains a few files
Used to link together several objects.
objectlink * link
Items for this value.
#define EVENT_CLOCK
Global time event.
void cf_object_say(object *op, const char *msg)
static long int initfire(const char *name, char *parameters, CFmovement *move_entity)
object * cf_map_insert_object_there(object *op, mapstruct *m, object *originator, int flag)
Wrapper for object_insert_in_map().
void(* f_plug_api)(int *type,...)
General API function.
static int is_animated_object(const object *ob)
Is specified object currently being animated?
CF_PLUGIN char SvnRevPlugin[]
void * parameters
Parameters to the function.
static anim_move_result runpickup(CFanimation *animation, long int id, void *parameters)
#define FOR_OB_AND_BELOW_FINISH()
Finishes FOR_OB_AND_BELOW_PREPARE().
long value
Used as connected value in buttons/gates.
int cf_init_plugin(f_plug_api getHooks)
object * below
Pointer to the object stacked below this one.
static CFanimation * first_animation
Animations we're currently processing.
static int compareAnims(const void *a, const void *b)
CFmovement * nextmovement
static int get_dir_from_name(const char *name)
Returns the direction from its name.
static anim_move_result runpickupobject(CFanimation *animation, long int id, void *parameters)
@ time_tick
One server tick.
static long int initmovement(const char *name, char *parameters, CFmovement *move_entity)
static int equality_split(char *buffer, char **variable, char **value)
This function take buffer with a value like "blabla= things" and extracts some things.
uint8_t type
PLAYER, BULLET, etc.
object * cf_object_clone(object *op, int clonetype)
Clone an object.
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
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 Python
void counterspell(object *op, int dir)
Nullifies spell effects.
#define CFAPI_MAP_PROP_PATH
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
static long int inittrigger(const char *name, char *parameters, CFmovement *move_entity)
#define FLAG_WIZPASS
The wizard can go through walls.
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 effects(as for "self", the caster may cast the spell on himself). A "special" range for missile spells indicates that the spell will last until it impacts an object(a PC
static long int initmessage(const char *name, char *parameters, CFmovement *move_entity)
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the you MUST download a map set point to where you installed Crossfire install Grab map set from official SourceForge page The following sets are at http
void cf_map_message(mapstruct *m, const char *msg, int color)
Partial wrapper for ext_info_map().
#define FOR_OB_AND_BELOW_PREPARE(op_)
Constructs a loop iterating over an object and all objects below it in the same pile.
static anim_move_result runnotice(CFanimation *animation, long int id, void *parameters)
int8_t facing
Object is oriented/facing that way.
void cf_object_drop(object *op, object *author)
CFmovement * next
Next move in the animation.
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the you MUST download a map set Note
CF_PLUGIN void * getPluginProperty(int *type,...)
static anim_move_result runmovement(CFanimation *animation, long int id, void *parameters)
void cf_free_string(sstring str)
Wrapper for free_string().
anim_move_result
Result of one animation move.
#define MAX_BUF
Used for all kinds of things.
object * cf_object_find_by_name(const object *who, const char *name)
Wrapper for object_find_by_name().
void cf_object_pickup(object *op, object *what)
static long int initdropobject(const char *name, char *parameters, CFmovement *move_entity)
Crossfire Protocol which is used between clients and servers to play Crossfire This documentation is intended primarily for client implementers This manual is the collective result of various authors compiled over the course of many most of the time several years after the actual code was written As such it will surely contain omit certain important and possibly make life miserable many working open source server and client implementations of this protocol are available Fixes and improvements to this documentation are welcome History the communications plan was set to be a text based system It was up to the server and client to parse these messages and determine what to do These messages were assumed to be line per message At a reasonably early stage of Eric Anderson wrote a then the data itself you could send many data and after the other end could decode these commands This works fairly but I think the creation of numerous sub packets has some performance hit Also
static long int initapplyobject(const char *name, char *parameters, CFmovement *move_entity)
static anim_move_result runapplyobject(CFanimation *animation, long int id, void *parameters)
#define FOR_MAP_PREPARE(map_, mx_, my_, it_)
Constructs a loop iterating over all objects of a map tile.
enum time_enum time_representation
int cf_object_move(object *op, int dir, object *originator)
CFAnimRunFunc func
Function to run for this move.
static CFanimation * create_animation(void)
Create a new animation.
void cf_system_register_global_event(int event, const char *name, f_plug_event hook)
#define FLAG_WIZ
Object has special privilegies.
How to Install a Crossfire Server on you must install a python script engine on your computer Python is the default script engine of Crossfire You can find the python engine you have only to install them The VisualC Crossfire settings are for but you habe then to change the pathes in the VC settings Go in Settings C and Settings Link and change the optional include and libs path to the new python installation path o except the maps ! You must download a map package and install them the share folder Its must look like this
#define NDI_UNIQUE
Print immediately, don't buffer.
this information may not reflect the current implementation This brief document is meant to describe the operation of the crossfire as well as the form of the data The metaserver listens on port for tcp and on port for udp packets The server sends updates to the metaserver via udp The metaserver only does basic checking on the data that server sends It trusts the server for the ip name it provides The metaserver does add the ip address and also tracks the idle time(time since last packet received). The client gets its information from the metaserver through connecting by means of tcp. The client should retrieve http the body s content type is text plain The current metaserver implementation is in Perl But the metaserver could be in any language perl is fast enough for the amount of data that is being exchanged The response includes zero or more server entries Each entry begins with the line START_SERVER_DATA and ends with the line END_SERVER_DATA Between these lines key value pairs("key=value") may be present. The entries are sent in arbitrary order. A client should apply some ordering when displaying the entries to the user. TODO b additional information outside BEGIN_SERVER_DATA END_SERVER_DATA maps
sstring slaying
Which race to do double damage to.
sstring name
The name of the object, obviously...
std::vector< archetype * > players
void cf_map_trigger_connected(objectlink *ol, object *cause, int state)
Wrapper for trigger_connected().
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the you MUST download a map set point to where you installed Crossfire Server
static anim_move_result runstop(CFanimation *animation, long int id, void *parameters)
void cf_object_set_flag(object *ob, int flag, int value)
One move in an animation.
object * env
Pointer to the object which is the environment.
CF_PLUGIN int postInitPlugin(void)
const typedef char * sstring
this information may not reflect the current implementation This brief document is meant to describe the operation of the crossfire metaserver
struct CFanimation * parent
Animation this move is linked to.
static long int initpickup(const char *name, char *parameters, CFmovement *move_entity)
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 but due to updates or the length of time the server instance has been up may be much shorter MN US< br > link< br >< a href="http: text_comment=Latest SVN 1.x branch, Eden Prairie, MN US archbase=Standard mapbase=Standard codebase=Standard num_players=3 in_bytes=142050710 out_bytes=-1550812829 uptime=909914 version=1.11.0 sc_version=1027 cs_version=1023 last_update=1214541369 END_SERVER_DATA ---- Multigod -------- This is a brief description of the MULTIGOD hack. It is preserved here for mostly historical reasons. Introduction ~~~~~~~~~~~~ The intention of this code is to enhance the enjoy-ability and playability of clerical characters in the new skills/exp scheme. This is done by giving players gods to worship who in turn effect clerical magic and powers. Included in this patch are several new spells which (hopefully) will allow the priest characters a better chance to gain xp at higher levels. Notably, the "holy orb" and "holy word" spells have been revamped. When MULTIPLE_GODS flag is defined in include/config.h, this code is enabled. This code (described below) encompasses 3 main parts: an array of gods that players/NPCs may worship, new clerical spells which rely on the worshiped god's attrib- utes in Gods[] array and, altars/praying--the interface between a worshiper and their god. b.t. thomas@astro.psu.edu Implementation Details ~~~~~~~~~~~~~~~~~~~~~~ This code is flexible and easy to configure (just edit the god archetypes). Part of the reason for creating this code was to allow server maintainers to develop their own "mythos". From my personal point of view, I hate having the old "Christian" aligned mythos, but if that's what you like, you can replicate it with this code too (see below). Properties of the Gods ~~~~~~~~~~~~~~~~~~~~~~ Here is a fuller description of Gods archetype values. ---- name - name of the god (required) other_arch - archetype that will be used for the summon holy servant spell. title - diametrically opposed god, leave blank if none exists attacktype - favored attack of this god, used in spells of summon avatar, holy word. Recipients of "holy possession" get this too. immune - Avatars/holy servants/recipient of "holy possession" gets this. protected - all of the above AND recipient of god's blessing and the priest of this god gets this. vulnerable - Avatar/servant/recipient of gods curse/priest of this god get this. path_attuned - priest of this god and recipient of "bless" gets this path_repelled - priest and recipient of "curse" gets this path_denied - priest and recipient of "curse" gets this slaying - comma delimited list of the races of creatures that are aligned with the god. "summon cult monsters" uses. this list to find creatures. Summon avatar/call servant code assigns this value to prevent them from attacking aligned races. Value is blank if no race(s) exists. race - comma delimited list of the races of creatures "holy word", "holy possession" spells will effect. Value entry is blank if no such race(s) exists. hp,dam,ac,wc - base stats for the summoned avatar. ---- IF MORE_PRIEST_GIFTS is defined (in gods.c) then ADDITIONAL gifts/limitations will be assigned to the priest: Flags ^^^^^ Now, the following flags, in addition to being used by the god (if planted on a map) are assigned to the worshiping priest: can_use_weapon, can_use_armour, is_undead, is_blind, reflect_missile, reflect_spell, make_invisible, stealth, can_see_in_dark, xrays NOTE: if can_use_armour/can_use_weapon flags are NOT present, then the priest will be forbidden the use of these items. Stats ^^^^^ The following stats are used: ---- luck - how lucky the god (and the priest) are. last_eat - how fast priest digestion is last_hp - how fast priest healing is last_sp - how fast priest mana regeneration is last_grace - how fast priest grace regeneration is ---- Designing New Gods ~~~~~~~~~~~~~~~~~~ To examine the gods properties, use the '-m8' flag (ie 'crossfire -m8'). Note some of the big differences here in terms of spell_paths, races, etc. Most of these entries were designed with roughly polar opposite gods. For designing new gods. You should make sure that worshiping a god will be "unique" in some way. But playbalance first! You must consider the balance between the following: . spellpaths . priest gifts . priest limitations . special spells . attacktypes . summoned monster lists . properties of the avatar and holy servant. Here are some hard and fast rules for designing gods: - Decide how the cleric will get experience. The god should be either a 'summoning', 'turning' *or* a 'wounding' god. If summoning/turning, make sure the aligned_race/enemy_race list(s) has enough creatures to summon/slay at low, medium and high levels. DONT give a god attuned to wounding AND turning||summoning (in fact, at minimum, one of these 3 paths should be repelled/denied). - make sure the summoned avatar is stronger than the servant (!) - examine the avatar/servant stats. If set inproperly, you will give wimpy/super values. For example, Avatars/servants with less than 50 hp (and a high ac/no armour) will vanish quickly. Shoot for stats like: ---- type | A V E R A G E S T A T S | hp | ac | wc | arm | dam | speed ----------|----------------------------------- servant | 50 | 5 | 5 | 20 | 5 | 0.15 avatar | 350 | -5 | -1 | 50 | 50 | 0.25 ---- Its difficult to give measurements on how to trade these off. To help guide your choices try to conserve the value of speed*dam and (armour+1)*hp. * avoid giving the potent attacktypes of death, weaponmagic and paralysis. * gods have a vulnerability for every immunity. Not all attacktypes are the same. Immunity to physical, magic and common attacktypes (like fire/cold/electric) are very potent. Similarly, vuln to these is a big negative. * SPELL paths. Carefull treatment is needed here. Give a path_denied/ or a couple path_repelled for every path_attuned. BUT note: not all paths are of equal use. (ex path_abjuration has a very large list of spells). The main clerical paths are restoration, abjuration, protection, turning, wounding and summoning. For balance, make 3-4 of these repelled/denied and 1 or 2 attuned. Be sure to check out the special spells list (below). Attuned paths like DEATH, WOUNDING and (especially) PROTECTION are very potent. Allow for some balance else where if you assign (one!) of these as a path_attuned. * If using the MORE_PRIEST_GIFTS define: priest limitations of no weapons and no armour are very negative, be sure to compensate with more than an attunded path. Of course, you may break these 'rules' to create your god. When you do that, you had better make up for the bonus elsewhere! Otherwise, you will create a 'mega-god' whose worship (by the player priests) will unbalance the game. Designing a good god takes a bit of work. Special Spells ~~~~~~~~~~~~~~ Here is a possibly *incomplete* list of the special spells that a god may grant use to a worshiper. Check the file spellist.h for the 0 bookchance clerical spells to find all of these. (This list was complete on 10/96). ---- INFO perceive self PROTECTION defense; immuntity to cold, fire, electricity, poison, slow, paralysis, draining, attack, and magic RESTORE remove damnation; reincarnation; raise dead; resurrection; regeneration WOUNDING cause critical wounds; retributive strike LIGHT daylight; nightfall DEATH face of death; finger of death SUMMONING insect plague CREATE wall of thorns ---- Ideas ~~~~~ * Allow sacrifices. This is an excellent way to give a cleric xp. Need to create enemy_race creatures w/ bodyparts we can sacrifice, and designate a pointer in Gods to the appropriate array of stuff we can sacrifice for xp. Experience ---------- Obsolete file kept for historical reasons. Introduction ~~~~~~~~~~~~ This patch represents a "developer 's" version of the exp/skills system. While I have now achieved all of the objectives in sections "B" and "C" of the coding proposal (see README.PROPOSAL) and have play-tested as much of the code as possible, I am sure some big bugs must remain. (One for sure is that exp gained when using rod/horn/wand is wrong.) Below this section I outline 1) coding philosophy, 2) gross description of how the code impinges/interacts within older code. 3) designer's notes on the changes to the code. Comments on any area of this coding would be appreciated. Personally, I would like to see the Pow stat and a 2-type system of magic come into being. After all of you check out the code, I would like to discuss enhancements/bug fixes/implementation. For instance, is it too hard to figure out how to use the code! Sometime tomorrow exp2.tar.gz will be available in pub/thomas on ftp.astro.psu.edu. b.t. Code Philosophy ^^^^^^^^^^^^^^^ To move CF over to a new skills-based experience system. In this implementation several kinds of experience will exist. Players will gain experience in each kind of experience (or category) based on their actions in the game. The sum of all the various categories of experience equals the player "score", from which dam, wc, and hp are determined. All experience gaining actions will be through the use of certain skills -- so called "associated skills". Associated skills are each related to 1 kind of experience. Thus, for example, "stealing" is a skill associated with "agility" experience. There exists also "miscellaneous" skills which allow the use of a unique skill, but which are not related to any kind of experience and whose use does not generate experience points. In this implementation, skills and objects are both treated as objects in the inventory of the user. Experience "objects" each represent one kind of experience and are always invisible. Skills objects each represent one kind of skill available in the game. Skills objects may either be invisible or have an associated bitmap (in which case they are "tools"). All experience gaining actions will be through the use of certain skills -- called "associated skills". Associated skills are each related to 1 kind of experience. Thus, for example, "stealing" is a skill associated with "agility" experience. Both Players and NPC's may only use skills which are in their inventories. NPC's do not use experience objects. A breakdown of the properties of skills and exp objects objects is as follows: ---- Object Property NPC use? ------ ----------------------------------- ------- Experience Each represents a different kind of NO experience in the game. The object in the player inventory keeps track of player experience in that category. Always is invisible. Skill- Represents a skill the player may YES associated perform. May be either invisible or visible as a "tool". Successful use of this skill generates experience. Experience is allocated to appropriate experience object. Skill- Same as above, *but* this skill is not YES miscell. related to any experience category, and use of this skill generates *no* experience. ---- Linking of associated skills to experience categories is done during initialization of the code (in init()) based on the shared stats of both. How skills and experience categories are named and linked may be changed by editing the skills/experience object archetypes. Implementation Details ~~~~~~~~~~~~~~~~~~~~~~ The most important thing is that I moved most of the code into the server/skills.c and server/skill_util.c files. The skills code is loosely implemented along the lines of the spell code. This is to say that: . skills use (do_skill) is called from fire(). . there is a skills[] table similar to spells[]. . server files skills.c and skill_util.c parallel spell_effect.c and spell_util.c in respective functionallity. Particular notes about the implementation are outlined below. Defines ^^^^^^^ #define MAX_EXP_CAT be > I had to make use of several global parameters These are
object * objects
Pointer to the list of used objects.
if you malloc the data for the buffer
static CFanimationHook * get_command(char *command)
char * cf_get_maps_directory(const char *name, char *buf, int size)
Wrapper for create_pathname().
#define CLEAR_FLAG(xyz, p)
CFanimation * nextanimation
static anim_move_result runturn(CFanimation *animation, long int id, void *parameters)
static anim_move_result runapply(CFanimation *animation, long int id, void *parameters)
CF_PLUGIN int cfanim_globalEventListener(int *type,...)
static long int initstop(const char *name, char *parameters, CFmovement *move_entity)
static anim_move_result runfire(CFanimation *animation, long int id, void *parameters)
static anim_move_result runvisible(CFanimation *animation, long int id, void *parameters)
static long int initturn(const char *name, char *parameters, CFmovement *move_entity)
CFAnimInitFunc funcinit
Function to process the parameters of the move.
object * container
Current container being used.
Magical Runes Runes are magical inscriptions on the dungeon which cast a spell or detonate when something steps on them Flying objects don t detonate runes Beware ! Runes are invisible most of the time They are only visible occasionally ! There are several runes which are there are some special runes which may only be called with the invoke and people may apply it to read it Maybe useful for mazes ! This rune will not nor is it ordinarily invisible Partial Visibility of they ll be visible only part of the time They have a(your level/2) chance of being visible in any given round
#define UP_OBJ_CHANGE
Object changed.
Release notes for Crossfire This is see the Changelog file included with the software Major changes since but slower than players without that skill *weather system is hopefully fixed *misc bug fixes Once you have installed the you MUST download a map set point to where you installed Crossfire install Grab map set from official SourceForge page The following sets are available
void cf_player_message(object *op, const char *txt, int flags)
static long int initcamera(const char *name, char *parameters, CFmovement *move_entity)
mapstruct * cf_map_get_map(const char *name, int flags)
Wrapper for ready_map_name().
static void animate(void)
Animates all currently running animations.
static long int initpickupobject(const char *name, char *parameters, CFmovement *move_entity)
How to Install a Crossfire Server on you must install a python script engine on your computer Python is the default script engine of Crossfire You can find the python engine you have only to install them The VisualC Crossfire settings are for but you habe then to change the pathes in the VC settings Go in Settings C and Settings Link and change the optional include and libs path to the new python installation path o except the maps ! You must download a map package and install them the share folder Its must look like doubleclick on crossfire32 dsw There are projects in your libcross lib and plugin_python You need to compile all Easiest way is to select the plugin_python ReleaseLog as active this will compile all others too Then in Visual C press< F7 > to compile If you don t have an appropriate compiler you can try to get the the VC copies the crossfire32 exe in the crossfire folder and the plugin_python dll in the crossfire share plugins folder we will remove it when we get time for it o Last showing lots of weird write to the Crossfire mailing list
void cf_object_update(object *op, int flags)
if you malloc the data for the make sure to free it when done There is also the newclient h file which is shared between the client and server This file contains the definition of the as well as many defined values for constants of varying you will need to grab these constant values for yourself Many of the constants in this file are used in the protocol to denote types Image Caching ~ Image caching has been implemented on the with necessary server support to handle it This section will briefly describe how image caching works on the protocol as well as how the current client does it the client checks for an option denoting the image caching is desired If we initialize all the images to a default value this means we don t need to put special checks into the drawing code to see if we have an image we just draw the default we know what filename to store it as we request the server to do image caching This is done by or ing the cache directive to the image mode we want C when the server finds an image number that it has not send to the it sends us a name command information us the number to name and there is no space between that the and the name Such formating is difficult but the above example illustrates the data is sent The client then checks for the existence of the image locally It is up to the client to organize images and then splits them into sub directories based on the first letters in the above the file would be crossfire images CS CSword If the client does not have the image or otherwise needs a copy from the it then requests it
Release notes for Crossfire This is see the Changelog file included with the software Major changes since version
void cf_object_remove(object *op)
Wrapper for object_remove().
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 plugin
static CFmovement * parse_animation_block(char *buffer, size_t buffer_size, FILE *fichier, CFanimation *parent)
Parse an animation block in the animation file.
*envar *is the environment if one that can also be used as an override If both the flag and the envar are set
int cf_map_get_width(mapstruct *map)
CF_PLUGIN int initPlugin(const char *iversion, f_plug_api gethooksptr)
Plugin initialisation function.
static anim_move_result runcamera(CFanimation *animation, long int id, void *parameters)
CFanimationHook animationbox[]
Available animation commands.
@ llevDebug
Only for debugging purposes.
*envar *is the environment variable
in that case they will be relative to whatever the PWD of the crossfire server process is You probably shouldn though Notes on Specific and settings file datadir Usually usr share crossfire Contains data that the server does not need to modify while such as the etc A default install will pack the and treasurelist definitions into a single or trs file and the graphics into a face(metadata) and .tar(bitmaps) file
static anim_move_result runmessage(CFanimation *animation, long int id, void *parameters)
static long int initghosted(const char *name, char *parameters, CFmovement *move_entity)
const char * name
Name as it appears in the animation file.
long usec_elapsed(struct timespec first, struct timespec second)
Return the number of microseconds between two timespec structures.