Protocol: | pserver | User: | anonymous |
Machine: | crossfire.cvs.sourceforge.net | CVSROOT: | /cvsroot/crossfire |
Filename: newserver.h | |||
Revision 1.41 | mwedel | 2006/09/04 02:21:04 | +1 -32 |
Bulk of this change is updating some files to use draw_ext_info() - all future code should use this, since there is no real reason not to and it provides additional features. One notable change - reversed the order of the new and old formats in draw_ext_info_format() - the order was different than that of draw_ext_info(), which leads to confusion. draw_ext_info_format() wasn't used in many places, so easier to change that than all the draw_ext_info() calls. Only another 1200 new_draw_info calls left in the server. -- doc/mediaTags: Fix some typos, clarify some behaviour (the way it works now so that there will not be confusion in the future). include/define.h: Remove MSG_ tags - moved to newclient.h include/newclient.h: Synchronize with client version. Add MSG_ defines include/newserver.h: Move some defines from here to newclient.h server/apply.c: Reverse format parameters to draw_ext_info_format() calls. server/c_misc.c: Rewrite to use draw_ext_info{_format} - this allows nice formatting of tables, etc. Also general style cleanups, clarify some messages. in help_topics(), don't do linewrap - let the client handle it. remove bug_report() function - no longer used. Remove explore_mode() - wasn't used. Move command_style_map_info() to c_wiz.c since it is a wiz only command. server/c_wiz.c: As per above, move command_style_map_info() to this file since it is a wiz command. server/player.c: Reverse format parameters to draw_ext_info_format() calls. server/shop.c: Update to use draw_ext_info{_format} instead of new_draw_info() socket/info.c: Reverse format parameters in draw_ext_info_format(). Update va_start() to use new last parameter. Remove call to strip_media() if the client supports the tag - that should only be used if the client does not support the tag. socket/request.c: remove commented out MSG_TYPE values. MSW 2006-09-03 | |||
Show difference between Revision 1.40 and 1.41 | |||
Revision 1.40 | ryo_saeba | 2006/05/20 07:36:48 | +2 -1 |
Add a bot flag, to not count in metaserver information | |||
Show difference between Revision 1.39 and 1.40 | |||
Revision 1.39 | mwedel | 2006/05/18 00:27:44 | +15 -6 |
This commit adds support for the map2 protocol command (10 layer map). This changes how the data is stored and sent to the client. This also implements the idea of client handling map animations, so adds some object flags so that the server knows if it should let the client handle animations or not. Support for the original map protocol command is removed. --- aclocal.m4: rebuilt configure.ac: Add checks for zlib.h, libz - not used right now, but will probably be used in the future, so no reason to remove it. common/loader.l: Add client_anim_sync, client_anim_random FLAGS. common/map.c: Add add_face_layer() to set face for a layer. Redo/simplify update_position to store faces away based on layering criteria. common/time.c: Replace long pticks with a uint32, since size of a long will vary, and we now send pticks to the client as a 32 bit value. crossedit/CrEdit.c: Update the draw logic based on the fact there are more layers now. crossedit/Edit.c: Comment out some code that probably should be fixed. Replace calls of SET_MAP_FACE with SET_MAP_FACE_OBJ doc/Developers/protocol: Updated with map2, tick protocol additions. Reorganize the parameters in the setup protocol command so they are now listed in alphabetical order. include/autoconf.h.in: Add HAVE_ZLIB_H define. include/define.h: Update for the FLAG_CLIENT_ANIM values. include/face.h: Remove MapLook structure - no longer used. include/global.h: change extern type for pticks from long to uint32 include/map.h: Change MAP_LAYERS to 10. Add definitions for what each map layer is. Remove GET/SET_MAP_FACE macro - no longer used, GET/SET_MAP_FACE_OBJ replaces it. Add GET_MAP_FACE_OBJS which returns pointer to all the object info for the space. Remove faces from MapSpace structure. include/newclient.h: Update with new defines used for map2 protocol command. include/newserver.h: Change type of faces in map_cell_struct to be uint16 to be consistent. Change 'count' to 'darkness' to more accurately describe what it represents. Add MAP2_COORD_OFFSET define. Add Map2Cmd to MapMode enum. Add map_scroll_x/y to socket structure so we send those as part of map2 command. Add tick field to socket structure to know if we should send tick data to the client. server/login.c: Remove extern long pticks declaration - declared in global.h - don't need to declare it again locally. socket/info.c: Rewrite magic map code to use GET_MAP_FACE_OBJ instead of GET_MAP_FACE macros. socket/init.c: Initialize new fields in socket structure to 0. socket/loop.c: If client wants tick data sent, send one each tick. socket/request.c: Add setup responses for tick, map2 requests. Remove some extra code in Map1a setup. Send error message to client if not using at least Map1 protocol level. Modify map_newmap_cmd() to clear scroll information when using Map2. Remove original (map0) protocol logic. Update map_clearcell() to clear all 10 layers. Replace MAX_LAYERS with MAP_LAYERS. Add add_head() to remove some of the complication from update_space(). Add code in draw_client_map1() to find which 3 layers to send to the client from the 10 we now have. Add map2_add_ob(), map2_delete_layer(), check_space_for_heads(), draw_client_map2() to handle map2 protocol. Add send_tick() - sends tick to client, but also forces flush of data to reduce lag. utils/config.guess.utils/config.sub,utils/ltmain.sh: rebuilt MSW 2006-05-15 | |||
Show difference between Revision 1.38 and 1.39 | |||
Revision 1.38 | ryo_saeba | 2006/03/18 09:05:32 | +8 -8 |
Massive cleaning of code. Shouldn't be any functional change. | |||
Show difference between Revision 1.37 and 1.38 | |||
Revision 1.37 | cavesomething | 2006/01/30 11:00:34 | +5 -1 |
prevent unlimited login attempts by dropping the connection after too many password failures. Document the itemcmd setup flag, and improve that for the item and item2 commands | |||
Show difference between Revision 1.36 and 1.37 | |||
Revision 1.36 | cavesomething | 2006/01/09 13:35:12 | +2 -1 |
spell listing support | |||
Show difference between Revision 1.35 and 1.36 | |||
Revision 1.35 | akirschbaum | 2006/01/08 15:30:41 | +1 -3 |
include/newserver.h, socket/{init.c,request.c}: Remove unused fields ext2 and ext_title_flag from NewSocket structure. | |||
Show difference between Revision 1.34 and 1.35 | |||
Revision 1.34 | akirschbaum | 2005/10/28 13:19:53 | +3 -2 |
Fixes my previous commit. Should now properly allocate/deallocate the faces_sent array. | |||
Show difference between Revision 1.33 and 1.34 | |||
Revision 1.33 | akirschbaum | 2005/10/24 17:51:03 | +2 -3 |
The archetypes now contain more than MAXFACENUM (5000) faces. The following changes remove the fixed limit of the number of faces. The server now allocates enough memory to handle all defined faces. include/newserver.h: Remove MAXFACENUM since it is not used anymore. Change NewSocket.faces_sent from array into pointer. socket/{init.c, loop.c}: Allocate/initialize NewSocket.faces_sent. socket/request.c: Remove safeguard/error message since it depends on MAXFACENUM. | |||
Show difference between Revision 1.32 and 1.33 | |||
Revision 1.32 | akirschbaum | 2005/08/31 16:53:08 | +2 -2 |
Fix bug #1102991 (Duplicate grapical display of the same monster): doc/Developers/protocol: Change semantics of map_scroll command to what the server actually does: big faces outside the viewable area are cleared. Add newmap command. include/newserver.h: Increase MAX_HEAD_OFFSET to 8 (the size of a Greater Demon). socket/request.c: MapRedrawCmd(): Disable mapredraw command; it is now just ignored. MapNewmapCmd(): Clear map state before sending newmap command. check_head(): Remove redundant code. update_space(): Move invariant condition out of loop to speed it up. Fix uninitialized variable. Remove redundant condition. Fix off-by-one array access. update_smooth(): Remove unused code. Properly send cleared big faces. draw_client_map(): Remove duplicate check. Properly clear newly visible area when scrolling the map. | |||
Show difference between Revision 1.31 and 1.32 | |||
Revision 1.31 | tchize | 2005/05/06 16:10:16 | +12 -2 |
added a new command to identify the type of text send to client. media tags can be included inside them. Those text types include scrolls, books, message of the day, signs, aso. See protocol doc for details | |||
Show difference between Revision 1.30 and 1.31 | |||
Revision 1.30 | mwedel | 2005/03/19 03:14:57 | +11 -4 |
This change makes it so that the smoothing information is pushed to the client (if the client is using smoothing) instead of a process were we tell the client the smoothlevel and the client then has to request the face info for smoothing. If we know the client wants the info, much easier to push it to the client. This simplifies the client code (doesn't have to keep track of what is requests). It also fixes the 'problem' that when you join the game, you get a few frames with no smoothing and then the smoothing shows up, which seems a bit odd. My testing shows that old clients that want smoothing use this new logic withouth any problems. -- common/image.c: add smooth_face default so that we don't have to look it up everytime. include/define.h: Add SMOOTH_FACE_NAME used by image.c include/global.h: Add smooth_face extern declaration. include/newserver.h: Update comment on what faces_sent is used for, add NS_FACESENT_* values which determines what info for the face was sent. socket/image.c, socket/init.c, socket/item.c: Update faces_sent checks/set to check against NS_FACESENT bitmask. socket/request.c: Update faces_sent as mentioned above. And SendSmooth(), rewrite AskSmooth() to use SendSmooth(). Modify update_smooth() to send smoothing information to the client. MSW 2005-03-19 | |||
Show difference between Revision 1.29 and 1.30 | |||
Revision 1.29 | mwedel | 2003/09/13 00:01:33 | +5 -5 |
Updated code for skill + spell code. skills and spells are now objects. tuning these now means changing the archetypes. New spells can now be added just by making a new archetype. Lots of code cleanup also done. MSW 2003-09-12 | |||
Show difference between Revision 1.28 and 1.29 | |||
Revision 1.28 | tchize | 2003/06/19 05:59:28 | +29 -3 |
Added support for smoothing to the client. This will allow (i hope) better graphical results while using very little bandwidth overhead. Changes done follows: - Added protocol command MapExtendedInfos and smooth commands to server - Added a SetUp paramater in protocol for activating smoothing (disabled by default) or more general Extended map infos - Added file lib/smooth a text file containing some smoothing info a client might ask the server about. - Changed loader.l to be able to mark an object as 'smoothed' in archetypes (the smoothlevel parameter) and rebuild loader.c accordingly - Changed lib/Makefile.am to install lib/smooth file in shared folder - Rebuild the Makefiles.am and the Configure script (using autogen.sh) To be able to smooth, A client commit (the common part+ the gtk part) will follow and an archetypes commit will also follow. I will also detail changes to the protocol within a few days Server has been tested with older client to check backward compatibility | |||
Show difference between Revision 1.27 and 1.28 | |||
Revision 1.27 | mwedel | 2003/03/19 02:04:50 | +1 -2 |
common/anim.c: Pass direction to animate_object() - needed for player animations as player's facing may not match direction. crossedit/Attr.c, server/main.c, server/time.c: Update calls to animate_object() include/libproto.h: rebuilt include/newserver.h, plugin_animator/animator_box.c, socket/init.c, socket/request.c: Remove newanim field from socket structure - not needed - how to animate is determined by object, not by socket. server/move.c: Add check to P_OUT_OF_MAP in teleport function. server/player.c: change move_player to call animate_object, so it gets full power of functionality it supports instead of 4 way hardcode animation information. server/spell_effect.c: When altars are consecrated, don't look to arch name for first portion of name - always call them Altar of %s - fixes problem where altar is special god altar that has god's name in archetype, resulting in altar of .. of ... MSW 2003-03-18 | |||
Show difference between Revision 1.26 and 1.27 | |||
Revision 1.26 | mwedel | 2002/07/14 23:57:12 | +3 -3 |
-- Start body commit notes -- Major commit. This adds body locations which is used for equipping items. Equipment has information which body part it gets equipped to, and monsters have information on how which body locations they can have. As part of this work, I also did a lot of code cleanup. To use this, you must use up to date archetypes - the ones included in this commit are fine - just make sure you install them. If you don't, players will not be able to equip items. common/arch.c: Initialize body_used to be same as body_info for archetypes - this way when monsters are created, they can start equipping items right away. common/exp.c: update new_exp() - some flags it checked for before no longer exist or have new names. common/info.c: describe_item() now takes second parameter - update dump_abilities to use new calling convention. common/item.c: Add table that describes the body_info locations and their names. Add functions that calculate item power for objects that don't have it set. Update display functions to show item_power in items. Update describe_monster() - use_horn/wand/rod merged into just use_range. Modify describe_item() to take second paramater - who the item is being described for. Show item_power in describe_item. common/living.c: Pull out MAXLEVEL from being defined in this file - define in in define.h, since other files use it. Add NUM_STATS define - replace hard coded values of having just 7 stats with it. Update change_abil to not display that the player has a new attacktype when equipping a bow that has it - fix_player() ignores the attacktype of the bow, so it was incorrect information. fix_player(): Initialize player ranges structure to null - will get filled in by code in function, updated to deal with updating the body_used data from body_info in the objects. Replace instances of last_heal with gen_sp_armour. Rearrange some code to make function more readable. common/loader.c, common/loader.l: Remove the variable_const information - no longer needed and confusing for new people when adding in new object elements. Add set_body_info() - parses the string from the load file and sets the appropriate array element. Add check_loaded_object() - does sanity checking for an object after finished loading - replaces need for long processing directive in the actual rules by having seperate function. Remove unused flags from load directives (apply_once, no_pretext, can_apply), add some new ones (item_power, gen_sp_armour), update others to can_use_range. Replace flag_links with simple array that contains the name for each corresponding flag. Update get_ob_diff to not use the V_ values and just include the actual string name - all recent changes have done this, just updated for old stuff. Update get_ob_diff to save new values that have been added. common/object.c: clear_object: Modify to use memset to clear the structure to zero - this is less error prone than listing all the specific values, and probably faster. Also, makes it easier to add new elements - no need to update object.c in most cases. common/player.c: Remove get_player_ob routine - this is now merged in with get_player_ob in server/player.c. Remove generate_ext_title - not used. common/readable.c: Update to pass second argument to describe_item. common/treasure.c: Update to calculate item_power of generated items. Clean up a lot of code formatting. Update add_abilities to use gen_sp_armour values, not last heal (note, it appears the last_heal values weren't being used before). Update calls to describe item to take second parameter. doc/Developers/objects: Update will_apply notes, add note about item_power, body location. include/define.h: Comment out unused flags (flag_apply_once, flag_paralyzed, flag_no_pretext, flag_ready_rod, flag_read_horn). Add flag_use_shield. rename flag_use_wand to flag_use_range. rename flag_ready_wand to flag_ready_range. Add flag_ready_scroll. Update ARMOUR_SPELLS access macro. Add AP_PRINT flag to apply flags. Add CAN_APPLY_.. return types for can_apply_object function. include/includes.h: add strftime, mktime checks to this file. include/libproto.h: rebuilt. include/living.h: Add NUM_STATS define, update extern declarations to use it for sizing. include/loader.h: remove the V_.. info and xbm_.. externs that were not used. include/newserver.h: Remove ext_tile information. include/object.h: Add Body_Locations structure, NUM_BODY_LOCATIONS define. Add definitions for WILL_APPLY values. Clean up object structure - formatting is now consistent, ordering of values groups values together more logically. Update all types to use the int8/int16/int32 types. Several unused fields removed. include/player.h: Update rangetype enum. Add unapplymode enum. Clean up player structure - type updates, unused fields removed, formatting fixed up. include/spells.h: remove range_name extern. Update SpellTypeFrom field to combine wand/rod/horn into spellMisc - none of the spell casting code was differentiating these. include/sproto.h: rebuilt. lib/Makefile.in: Add new help files (applymode, bind, brace) lib/archetypes: rebuilt for body_info, gen_sp_armour, item_power, can_use_shield information. lib/artifacts: updated for item_poer and gen_sp_armour changes. lib/treasures: remove unused _force for player treasure. plugin/plugin_python.c: Change FLAG_USE_WAND to FLAG_USE_RANGE. server/apply.c: Move stftime, mktime to include/includes.h. Remove draw_find() - one line function can just as easly be in the code itself. Update calls to long_desc to pass second parameter. move gravestone_text() to player.c file. Add direction parameter to apply_scroll() - in this way monsters can use it properly. Remove dead code. Update apply_special function. Add unapply_special(), get_item_from_body_location(), unapply_for_ob(), and can_apply_object() functions. server/attack.c: Remove SET_FLAG(op, FLAG_PARALYZED) line - no code was ever checking status of FLAG_PARALYZED. server/c_misc.c: add command_body() which dumps body information for player. Update who as idle element in player structure removed - was not being used by anything. Add command_applymode() to set players prefered unapply method. Remove calls to unlock_player() in various functions - unlock_player() has not done anything meaningful for a while. server/c_object.c: Modify long_desc to take a second parameter which is who is examing the object. this is needed so that we can pass it down to some of the lower level functions. Update calls to describe_item to pass this second parameter. remove FLAG_NO_PRETEXT code - no archetyps were using it. When examining objects, also tell player where to put them on. server/c_range.c: Update legal_range() - we now store the object that is responsible for a range in the player object, so code is much simpler. Update change_spell() to not destroy golem just by readying another spell - we now let players regain control of golems after switching to another range. Update change_spell to use item name of object for range description. server/c_wiz.c: remove reference to count_left from player object - field removed from structure. server/commands.c: add new commands (applymode, body) to command dispatch table. server/login.c: Remove unlock_player() and lock_player() and calls to it - current checking of names at login should be sufficient to prevent duplicates. Remove dead code from check_name. Update load/save code for unapply mode value. Add set_flag(op, FLAG_USE_SHIELD) if player is allowed to use armor - needed since flag_use_shield is really a class feature and so is not automatically updated for old player files. server/main.c: Remove references to count_left. memset marker object to NULL - seems to increase stability on metalforge server. server/monster.c: Many updates related to the body info - monsters follow some rules as players. Add monster_should_cast_spell function - monsters will use this for all spellcasting related actions (abilities, scrolls, wands, etc). Update for merged rod/horn/wand ranges. Update bow use by monsters - they don't actually need to equip it to fire - this way we don't need to constantly swap the monsters weapons between the bow and melee item. Use fire_bow from player.c for most of the work. Modify scroll usage - monster will use it when player is near, not when it first picks it up. Add FLAG_READY_SCROLL to denote the monster has a scroll to use. Also, monster now casts it in appropriate direciton. Merge the monster_use_wand/rod/horn into monster_use_range. Modify check_good_weapon and check_good_armour to just look at the stats of the two items without needing the monster to apply it first. server/player.c: Print motd in green so it is more noticable. Update get_player function to do work it did before as well as that of get_player_ob. Have get_player take a parameter which is the object of the player if he has one. Modify to use memset to clear the player structure - more sure fire than explicitly listing values to initialize. Remove calls to unlock_player. Modify fire_bow so that monsters can also use the function. Add fire_misc_object() to fire_wand/rod/horn - removes code from fire(). Add gravesetone_text() to this file. server/shop.c: Update to pass second parameter to describe_item(). server/skill_util.c: Update check_skill_to_fire since there are fewer rangetypes now. change range_scroll name to range_golem, as that is a bit more accurate for what it actually does. Modify show_skills() to show player his item power and total of items he has equipped. server/skills.c: Add second paramater to long_desc, remove references to count_left. server/spell_effect.c: Add second paramater to long_desc, remove references to count_left. Update range_scroll to range_golem server/spell_util.c: remove references to count_left. Update messages if player trying to cast where he can't with new range names. socket/info.c: Update range information and how we display what it is - we will use the object name of the range if available. Remove reference last_known_spell, last_shoot, last_spell, last_value player structure fields. socket/init.c: Remove ext_title information. socket/request.c: Add element for life_stealing in the resistance array. Remove references to idle, count_left in player structure. remove ext2 title information. MSW 2002-07-14 -- End body commit notes -- | |||
Show difference between Revision 1.25 and 1.26 | |||
Revision 1.25 | mwedel | 2002/05/30 23:18:33 | +2 -1 |
Main change is the addition of name_pl and client_type to object structure. The name_pl contains the proper plural name instance - fixes problem of '2 tooths'. client_type is sent to the client so that client doesn't need to figure out sorting on its own. Client_type is an object attribute, so can be modified in maps to hide the real type. -- common/arch.c: item_matched_string() modified to use the name_pl field when trying to match names, and not to try to make the name plural itself. common/item.c: query_short_name(),query_base_name() modified to use name_pl instead of trying to make the name plural. common/loader.c, common/loader.l: Add code to load and save the name_pl value and client_type. Add logic when object is finished loading to set name_pl value to same as name or arch name if no name_pl is specified - this supports old maps/characters in which the objects dont have a name_pl field yet. Disable logic for need_an and need_ie flags since they are no longer needed. Fix bug that caused elevation not to get saved. common/object.c: Add client_type check for CAN_MERGE function. Add appropriate logice in functions to handle setting, clearing, and copying of name_pl values. Remove unused anim_... fields initialization. doc/Developers/objects: Add information about the name_pl field and client_type. doc/Developers/protocol: Remove item protocol command info - it has been obsoleted. Add information about item2 protocol command. include/define.h: Remote ST1_* values - they were not being used. comment out FLAG_AN and FLAG_NEED_IE values. include/newserver.h: Add itemcmd to socket structure - this is the version of the item protocol command that will be sent to the client. include/object.h: Add name_pl and client_type field to object structure. Remove unused anim_* values. lib/archetypes: rebuilt with new archetypes that contain client_type and name_pl information. lib/bmaps, lib/bmaps.paths, lib/crossfire.1, lib/crossfire.0, lib/faces: rebuilt. server/monster.c: Remove anim_ references that were not being used. socket/init.c: Initialize itemcmd version in the socket to 1. socket/item.c: Remove special handling for clients of old versions - all clients now have to be at least sc_version 1024 (which has been around for a long time). This simplifies a lot of the object code that deals with sending or not sending plural names to the client - now always send them. Change code that sends item to client to use the item revision (currently 1 or 2) that the client wants. If version 2, send along client_type information. socket/request.c: Handle 'itemcmd' parameter in setup command. Make sure it is in proper range. If client is very old (sc_version < 1024) tell them so. MSW 2002-05-30 | |||
Show difference between Revision 1.24 and 1.25 | |||
Revision 1.24 | mwedel | 2002/05/19 22:11:49 | +2 -3 |
crossedit/png.c, crossedit/xutil.c: Increase size of temporary buffers that are used when loading images - necessary to allow the editor to run without crashing. include/newserver.h: Remove quick_pos from the MapCell structure. server/main.c: Add code to set the coordinates to the EMERGENCY_X/Y values if using the EMERGENCY_MAP. socket/request.c: Fix code that was causing darkness to get repeatedly sent for some spaces. MSW 2002-05-19 | |||
Show difference between Revision 1.23 and 1.24 | |||
Revision 1.23 | mwedel | 2002/05/18 22:55:48 | +25 -7 |
The bulk of this commit is to modify the server to only send the lower rightmost part of multipart archetypes that use the same head. This allows support of big images in the client. common/arch.c: Modify first_arch_pass to figure out the tail_x/y values for multipart archs. Rename the prev variable to head, as that it really what it is. Remove quick_pos info. common/object.c: remove quick_pos info from object. doc/Developers/images: Add notes about using merged images. doc/Developers/protocol: Add information about the map1a command, which is used to for big image support. Remove map2 documentation. include/map.h: Add MAP_LAYERS define instead of using hardcoded value of 3. include/newserver.h: Change the MapCell to use MAP_LAYERS - saves considerable memory. Add defines for MAX_CLIENT_ map sizes. Remove map1cmd, map2cmd elements from socket structure - instead use enumeration of mapmode - only one map type will be used at any time by the client, so no reason to have individual elements - it also makes it easier to add new mapmode commands. include/object.h: remove quick_pos, update_tag from object structure. Add tail_x, tail_y values to archetype structure. include/player.h: Remove some now unused values from the player structure (drawn, floor, floor2, darkmask). These have been superseded by the map cells in the socket structure for quite a while. include/sockproto.h: rebuilt server/player.c: Remove code that initialized the drawn values in the player structure since they no longer exist. socket/init.c: Replace map1cmd, map2cmd elements in socket structure with mapmode element. Modify init_ericserver so that it properly passes an int when setting the SO_REUSERADDR field. socket/request.c: Modify code in SetUp function to use the new mapmode enumeration in the socket structure. Add support for map1acmd setup option. Throughout map code, replace MAXMAPCELLFACES with MAP_LAYERS. modify map_clearcell to take options for values to clear the cell to. Add have_head, check_head, and update_space commands - used with the map1 command to store and find head information. draw_client_map1 modified to support map1a extensions, as well as added logic for checking for heads in blocked and out of viewable map spaces. Some of the code is simplified by using the update_space function, since the logic for processing each layer was otherwise the same. remove draw_client_map2 function. esrv_map_scroll has same logic - some variables and code formatting changes. MSW 2002-05-18 | |||
Show difference between Revision 1.22 and 1.23 | |||
Revision 1.22 | mwedel | 2002/03/26 01:18:57 | +2 -2 |
Update to improve image caching and faceset support in the client. The main change is adding the 'requestinfo image_info' and 'requestinfo image_sums' commands. common/image.c: Checksum the bmaps file when we load it - we send this as part of the image_info data. doc/Developers/protocol: Document the requestinfo data. include/global.h: Add extern for bmaps_checksum, and the define for ROTATE_RIGHT which is used for checksumming. include/newserver.h: Update SC version to 1027 so that clients can know if they can issue requestinfo commands. include/sockproto.h: rebuilt lib/adm/collect_images.pl: Add support for it to make a crossfire-images distribution that the client can use to bootstrap its image set. socket/image.c: Change SendFaceCmd to take a NewSocket parameter instead of a player parameter - in this way, it can be used before the AddMe command - this allows the client to download images before issuing that command. Add send_image_info and send_image_sums function which send the requestinfo data to the client. socket/loop.c: Move the askface command from the player commands to the newsocket commands. Add RequestInfo functino that determines the type of request and calls the specific function to deal with it. MSW 2002-03-25 | |||
Show difference between Revision 1.21 and 1.22 | |||
Revision 1.21 | mwedel | 2001/12/31 02:35:48 | +9 -19 |
This change lets the server have multiple image sets. The client can then request which image set to use, and the server will use that image set, falling back to other sets as necessary. I have tested this with CVS client, and works fine at least in terms of old functionality. = doc/Makefile.in: Add images file which describes image guideline. doc/Protocol: Various updates - some things missing, added other notes about facesets. doc/images: New file, describes guidelines for image sets, as well as some of the internals include/newserver.h: Update for multiple image set - redid most of the image definitions as they were out of date with only png being supported. include/sockproto.h: rebuilt lib/Makefile.in: remove crossfire.png, add crossfire.0, crossfire.0. Update build directions to use crossfire.0 instead of crossfire.png lib/adm/collect_images.pl: Modified to collect all the image sets, remove support for collect xpm and xbm images. lib/crossfire.0: new file, base images lib/crossfire.1: new file, alternate images lib/image_info: New file, describes image sets. lib/crossfire.png, lib/xpmtopix.pl.in: Removed - no longer needed. socket/Makefile.in: add image.c file. socket/image.c: Moved all image related data in this file - this includes loading the image files, as well as the protocol commands. socket/init.c: move read_client_images to image.c file. set ns->faceset and ns->facecache to 0. Move freeing of image data to image.c socket/request.c: fixed some indentation inconsistencies.add setup commands for faceset as facecache. Move SetFaceMode,SendFaceCmd,esrv_send_face to image.c file. MSW 2001-12-31 | |||
Show difference between Revision 1.20 and 1.21 | |||
Revision 1.20 | mwedel | 2001/12/03 01:51:40 | +5 -4 |
This checkin for the most part removes support for xpm and xbm graphics - now the only image supported is the png. common/arch.c: comment out printing on warning of object having no type - getting 300 meaningless messages at startup is annoying. common/image.c: Remove X11 color information from colorname array. Remove processing of color_fg and color_bg information from face file - only use color_fg if no magicmap information is available - foreground and background infoformation was only needed for bitmap graphics. common/loader.c, loader.l: Add elevation element, comment out some logging messages that are excessive and only really relevant for people who want to fix them (really should be in the collect script anyways). Remove some unused code. common/map.c: add outdoor field to map structure - add support for loading and saving it. crossedit/App.c,crossedit/CrUtil.c, crossedit/Defines.h, crossedit/crossedit.c crossedit/xutil.c: Remove support for non png graphics. crossedit/Attr.c: Add support for elevation variable, remove code for non png graphics. doc/map-technical: Add note about outdoor field. include/face.h: remove fg, bg fields from face struecture. include/global.h: Update colorname array definition. include/loader.h: Add V_ELEVATION field. include/map.h: Add outdoor field to map structure. include/newserver.h: Update types so it only loads/knows about png information. include/object.h: Add elevation field to object structure. lib/Makefile.in: Remove support for building crossfire.xpm and crossfire.xbm files. lib/animations, lib/archetypes, lib/bmaps, lib/bmaps.paths, lib/crossfire.png, lib/faces: Rebuilt. Main difference is a few sea types, and the fact that it hadn't been collected for a while. server/spell_effect.c: Modify dimension door so that it calls MapNewmapCmd so that fog of war does not get confused. Also, removes call to draw as functions further up will do that. server/spell_util.c: Remove color information from attack information that shuffle_attack uses. socket/init.c, socket/request.c: Remove support for non png images. MSW 2001-12-02 | |||
Show difference between Revision 1.19 and 1.20 | |||
Revision 1.19 | michtoen | 2001/11/17 15:25:21 | +4 -2 |
commit the ext2 gender & guild system - first part. Sorry, my cvs sytem is still broken, i will write a better doc to the list. Notice some other small fixes too. | |||
Show difference between Revision 1.18 and 1.19 | |||
Revision 1.18 | michtoen | 2001/11/04 14:22:55 | +3 -1 |
One Arch/one pic patch. I use a modified map1cmd, called map2cmd for it. This is a first tryout implementation. The code can more then only submit offset data of multi arch, its also possible to include animation tags for the faces - we have now more free flags. The code is NOT optimized. Iam still unsure , what the best way is to send all this data. Sort & parsing cost time. At this stage, ill quick parse is by server, use slightly more bandwitch and let do the client more work. But thats perhaps not the best way. But this code will allow to install the arches for this one arch/one pic. MT | |||
Show difference between Revision 1.17 and 1.18 | |||
Revision 1.17 | smacfiggen | 2001/07/22 13:48:46 | +2 -1 |
Server side of the fog of war feature to the gtk client. Adds the protocol command newmap and adds a call to MapNewmapCmd in enter_map() in main.c. More additionals will need to be made, for example when someone casts a teleport spell but teleports within the same map. SMACFIGGEN | |||
Show difference between Revision 1.16 and 1.17 | |||
Revision 1.16 | mwedel | 2001/06/16 02:48:20 | +3 -2 |
doc/Protocol: Add 'darkness' setup option documentation. include/newserver.h: add darkness element to socket structure. include/script.h,server/script.c: remove static declaration from script.h, move it to script.c socket/init.c: init darkness element in socket structure. socket/request.c: Add support in setup command for client to set if it wants darkness information or not. Modify map update functions such that if the client does want darkness information, server does not send it. Improve darkness handling so that if using the map1 protocol command, send darkness for first blocked space due to darkness - this makes it possible for client to interpolate results better. MSW 2001-06-16 | |||
Show difference between Revision 1.15 and 1.16 | |||
Revision 1.15 | michtoen | 2001/06/13 07:52:07 | +2 -1 |
Modified Files: player.c loader.l loader.c init.c request.c newserver.h Log Message: Removed 2 compiler warning from Scriptfire patch in loader.l/loader.c and script.c. added a new setup cmd: "newanim" a client giving the newanim cmd, will enable the new animation system. The interface is open and not server controlled at this moment. First using is to enable the player moving in 8 direction. Giving this option to a server without changed arch will invoke broken player animations. This will be changed in the future. MT 2001-06-13 | |||
Show difference between Revision 1.14 and 1.15 | |||
Revision 1.14 | mwedel | 2001/06/08 01:21:34 | +2 -1 |
doc/Protocol: update information for the mapcmd, add map1cmd to section of setup commands. include/newserver.h,socket/init.c: add map1cmd element to socket structure that determines which protocol (map,map1) will be used for sending the map. socket/request.c:add 'map1cmd' to list of setup options. when sending the map, use the map1cmd element to determine what protocol command to use to send it. MSW 2001-06-07 | |||
Show difference between Revision 1.13 and 1.14 | |||
Revision 1.13 | mwedel | 2001/06/04 01:41:02 | +3 -2 |
Checkin of code that supports larger map sizes (configurable in config.h). common/los.c: update los code since it only handled 11x11 maps. Now uses formulatic approach so any map size should be supported. This does result in a few more spaces getting blocked around corners, but it doesn't seem that bad - certainly not compared to the ability to have larger viewable maps. common/map.c, crossedit/CrEdit.c, crossedit/Edit.c, include/global.h, include/map.h,random_maps/monster.c,random_maps/special.c, random_maps/standalone.c, server/apply.c,server/c_misc.c, server/spell_effect.c,socket/info.c: change mapx,mapy to what they really point to, as it prevented using those as variable/structure element names. common/object.c: update_position - if faces for different layers are duplicate, set the duplicates to be blank to increase client update efficiency. doc/Protocol: Add map1 command description, update setup command to describe setting of mapsize. include/config.h: add MAP_CLIENT_X/Y to set maximum map size we can send to the client. include/newserver.h: add mapx, mapy values to socket structure include/player.h: Use MAP_CLIENT_X/Y for sizing arrays that hold map related information in player structure. server/player.c: As per player.h above, use appropriate sizing when initializing player stucture. server/shop.c: Update mapx,mapy like above, but re-do shop listings code as it was doing a lot more work than necessarily (I think some changes got put in for sorting, and the old object manipulation was never removed when that got done) socket/init.c: set default client map size to 11x11 in the socket. socket/item.c: LookAt - change checks for position checking (such that you can only look at things in bounds) use max viewable map size. socket/request.c: Make setup commands a little more forgiving if there are extra spaces. Add 'mapsize' command to setup command. Update old map sending code to use socket map sizes (to support even smaller than normal maps, or 13x13 or 15x15 maps). add draw_client_map1 command which implements the map1 protocol command. MSW 2001-06-03 | |||
Show difference between Revision 1.12 and 1.13 | |||
Revision 1.12 | mwedel | 2001/05/28 23:41:53 | +2 -1 |
Make ALLOW_SKILLS standard part of game (remove #ifdef's for it) Files affected: common/living.c common/object.c common/treasure.c include/config.h include/player.h server/apply.c server/attack.c server/c_move.c server/c_range.c server/c_wiz.c server/commands.c server/init.c server/login.c server/monster.c server/player.c server/rune.c server/skill_util.c server/spell_util.c Make MULTIPLE_GODS standards part of game (remove #ifdefs for it) Files affected: common/readable.c include/spellist.h include/config.h server/attack.c server/gods.c server/skills.c server/spell_effect.c server/spell_util.c doc/Makefile.in, doc/Protocol: Add protocol description file here instead of in the client distribution. include/global.h: Move declaration of MAX_EXP_CAT near top of file so it is set before player.h is included. include/newclient.h: Add CS_STAT_SKILL* values for sending skill experience information to client. include/newserver.h: Add skillexp value to socket struct which determines if client wants skill experience informatiion. include/player.h: Add skill information tracking to player structure so we can easily know when to send updates to client. random_maps/expand2x.c: remove unused variable to prevent compiler warnings. random_maps/square_spiral.c: Include prototype information on all systems, not just win32 to prevent compiler warnings. server/skill_util.c: Initialize skill pointers to make it easier to find skill information when we want to update client. socket/init.c: Init socket->skillexp to 0. socket/loop.c: Fix indentation of table - whitespace change only socket/metaserver.c: Minor fix to prevent compile warnings (on the sprintf that composes the data to send to the metaserver) socket/request.c: Redo SetUp function to be more compact and IMO simpler as wll as easier to read (functionality remains the same). VersionCmd modified to warn users of on dxclients (code on MT) StatsCmd added to send skill information if client wants it. The sending of skill experience is by MT, rest of the changes by me. MSW 2001-05-28 | |||
Show difference between Revision 1.11 and 1.12 | |||
Revision 1.11 | mwedel | 2001/04/09 01:59:46 | +2 -1 |
Main thing this commit does: Undo MT's last commit, which should not have been checked it at this time. As that did not fix any bugs, it should wait until after 1.0 (at least one file also fails to compile) Fix minor bug in server/player.c which prevent keyring weight from getting updated when keys are automatically used out of the rings. move the GETTIMEOFDAY macro to include/global.h so it doesn't have to be done in both arch.c and time.c remove some ^M characters from porting.c MSW 2001-04-08 | |||
Show difference between Revision 1.10 and 1.11 | |||
Revision 1.10 | michtoen | 2001/04/08 19:57:18 | +2 -3 |
add skill exp | |||
Show difference between Revision 1.9 and 1.10 | |||
Revision 1.9 | michtoen | 2001/04/06 22:57:09 | +3 -3 |
setup cmd: change VERSION_CS to 1023 | |||
Show difference between Revision 1.8 and 1.9 | |||
Revision 1.8 | mwedel | 2001/03/30 01:27:48 | +5 -1 |
common/image.c, include/define.h, include/global.h: Add empty_face structure and appropriate code to initialize it. This is used for the server side look selection. include/newserver.h: Add NUM_LOOK_OBJECTS to control number of look objects to send at any one time. add look_position field to the newsocket structure. server/move.c: clear look position as player moves. server/player.c: initalize look_position element in structure. socket/item.c: modify esrv_draw_look to sne NUM_LOOK_OBJECTS at any one time, and to also send pseudo objects that lets the player scroll up and down. modify ApplyCmd so that if it detects the application of one pseudo objects to adjust the look_position. MSW 2001-03-29 | |||
Show difference between Revision 1.7 and 1.8 | |||
Revision 1.7 | cvs | 2001/02/02 23:30:18 | +4 -3 |
MSW 2001/02/02: common/item.c: Don't have armour item types get returned as magical if they have an armour value - that is to be expected. This eliminates the false positives that you otherwise get on armor when you cast detect magic. include/newserver/h: and checksum field to FaceInfo struct. Update version_sc to 1026. socket/init.c: calculate image checksums as we load the images. socket/request.c: If client is at least version_Sc 1026, use face1 protocol command that includes the checksum. | |||
Show difference between Revision 1.6 and 1.7 | |||
Revision 1.6 | cvs | 2000/12/03 18:40:04 | +2 -2 |
Checking for partial resistance code. Various minor errors also fixed (compiler warnings, unused variables, Makefile.in changes, etc). PR code also includes support to send protections to the client. | |||
Show difference between Revision 1.5 and 1.6 | |||
Revision 1.5 | cvs | 2000/08/07 00:16:33 | +2 -2 |
The following change basically does the following: When the server sends an item name to the client, this item name is now two pieces - the first piece of the name is its singular form, the second piece is the plural name. This now makes items in the inventory appear more proper in terms of pluralization and just normal English. I did notice that the server does not know how to properly make 'torch' plural - it turns it into torchs. A matching check in for the client has also been done. include/newserver.h: Update VERSION_SC to 1024 common/item.c: Change query_base_name to take a second option on whether we should generate a plural version of the name or not. socket/item.c: Modify functions to use second argument on the query_base_name function. Update item commands to send two part names (singular & plural). Modify esrv_send_look to use item1 protocol command instead of item command. server/c_object.c: Update item_matched_string to use second option to query_base_name. Modify function to check against both singular and plural versions of name. server/shop.c: Modify shop_listing command usage in query_basename to use second option. It will also generate the singular name, but that is only used on sorting, so I don't think it will generally cause any problems. include/libproto.h: rebuilt because query_base_name has an addition opt. Mark Wedel 8/13/2000 | |||
Show difference between Revision 1.4 and 1.5 | |||
Revision 1.4 | cvs | 2000/06/03 02:01:42 | +7 -6 |
lib/crossfire.png: Some floors modified to no longer have transperencies. include/newserver.h: Add Send_Face_Png made, also update versions of the protocol include/newclient.h: Add CF_FACE_PNG constant. socket/request.c: Add support for receiving PNG facemode request, ad final logic to send png images to the client. Changes by Mark Wedel, 6/2/2000 | |||
Show difference between Revision 1.3 and 1.4 | |||
Revision 1.3 | cvs | 2000/05/13 18:44:43 | +7 -4 |
crossedit/xutil.c: Merge bitmap & pixmap load routine into one called ReadImages, function modified to use above format. crossedit/App.c: Call ReadImages to load images. include/newserver.h: Change FaceInfo structure to have arrays of data and datalength instead of explicity entries for pixmap vs bitmap data. lib/adm/make_xpm_file.pl, lib/crossfire.cfb, lib/xbmtobdf.c: Removed - either note needed or replaced by new naming scheme. lib/adm/collect_images.pl: Replacement/improvement of make_xpm_file.pl above - this handles all image formats (xbm, xpm, png). This is also more intelligent in that it will not try to rebuild the image files if there is not a valid arch directory. lib/crossfire.png, lib/crossfire.xbm (new files): .png file is for png images. xbm is to keep with the new standardized naming convention used and is for the bitmaps. lib/crossfire.xpm: New format used in file. lib/Makefile.in: Modified to collect via new script as well as new directives to collect (png files). socket/init.c: Modified to load with the new format and data structures. socket/request.c: Modified to send data with the new data structures provided. | |||
Show difference between Revision 1.2 and 1.3 | |||
Revision 1.2 | cvs | 1999/07/13 01:02:52 | +0 -0 |
Global commit for 0.95.4 - most files have no changes but just have differing headers between my local RCS and the CVS versions and need to get synced up. | |||
Show difference between Revision 1.1 and 1.2 | |||
Revision 1.1 | uid200 | 1999/04/02 13:10:04 | None |
Initial revision | |||
First version | |||
Revision 1.1.1.1 | uid200 | 1999/04/02 13:10:04 | +0 -0 |
First CVS revsion: crossfire-0.95.3 | |||
Show difference between Revision 1.1 and 1.1.1.1 |