Protocol: | pserver | User: | anonymous |
Machine: | crossfire.cvs.sourceforge.net | CVSROOT: | /cvsroot/crossfire |
Filename: object.c | |||
Revision 1.143 | ryo_saeba | 2006/08/26 12:56:21 | +1 -48 |
Remove obsolete event system. | |||
Show difference between Revision 1.142 and 1.143 | |||
Revision 1.142 | ryo_saeba | 2006/08/26 03:08:01 | +5 -2 |
Fix insert_ob_in_map strange behaviour with some flags combo. | |||
Show difference between Revision 1.141 and 1.142 | |||
Revision 1.141 | qal21 | 2006/08/25 22:45:37 | +7 -1 |
Fix potential 'coord outside of map' issue in previous commit. | |||
Show difference between Revision 1.140 and 1.141 | |||
Revision 1.140 | qal21 | 2006/08/25 22:30:15 | +129 -1 |
Make generators work properly with multi-tile objects. | |||
Show difference between Revision 1.139 and 1.140 | |||
Revision 1.139 | qal21 | 2006/08/19 20:23:08 | +33 -12 |
Scatter objects dropped from a multi-tile object being freed. Fixes bug #1542884 | |||
Show difference between Revision 1.138 and 1.139 | |||
Revision 1.138 | ryo_saeba | 2006/08/19 15:22:21 | +66 -1 |
Fix for bug #1460251 (Big monsters generated by generators broken). Tweaks to object dumping. | |||
Show difference between Revision 1.137 and 1.138 | |||
Revision 1.137 | ryo_saeba | 2006/07/29 04:29:15 | +101 -90 |
Fix bug #1526364 (stacking Royal Guards) | |||
Show difference between Revision 1.136 and 1.137 | |||
Revision 1.136 | qal21 | 2006/07/28 01:45:29 | +5 -1 |
Add EVENT_DESTROY. Allow execute_event to be called from common. | |||
Show difference between Revision 1.135 and 1.136 | |||
Revision 1.135 | ryo_saeba | 2006/07/04 16:22:24 | +3 -2 |
Actually commit file I forgot. | |||
Show difference between Revision 1.134 and 1.135 | |||
Revision 1.134 | tchize | 2006/07/02 10:32:34 | +143 -158 |
more progress in unit testing, marked points of interrest in code | |||
Show difference between Revision 1.133 and 1.134 | |||
Revision 1.133 | ryo_saeba | 2006/06/24 05:41:44 | +2 -2 |
Fix merging bug. | |||
Show difference between Revision 1.132 and 1.133 | |||
Revision 1.132 | tchize | 2006/06/18 06:27:10 | +159 -160 |
added some test, corrected some indentation, added some TODO and FIXME | |||
Show difference between Revision 1.131 and 1.132 | |||
Revision 1.131 | tchize | 2006/06/07 16:44:05 | +35 -19 |
update test build process slighlty, changed tests so unimplemented ones success, added some *FIXME* | |||
Show difference between Revision 1.130 and 1.131 | |||
Revision 1.130 | mwedel | 2006/06/07 02:10:46 | +4 -2 |
common/object.c: in insert_ob_in_map() don't stop processing flying objects if the object also has floor set. This fixes crashes when an object is both flying and has floor set. MSW 2006-06-06 | |||
Show difference between Revision 1.129 and 1.130 | |||
Revision 1.129 | mwedel | 2006/06/05 02:23:50 | +22 -3 |
Fix problem with create food when used on transports. Rather than put a specific check in the create food code, modify insert_ob_in_map to check to see of the passed in originator is on a transport, and if so, find out the right info - this probably fixes the same type of bug that happens from other areas of the code. common/object.c: Above change, as well as #if 0 out some unused functions. MSW 2006-06-04 | |||
Show difference between Revision 1.128 and 1.129 | |||
Revision 1.128 | tchize | 2006/06/03 13:28:08 | +21 -7 |
made a few methods in object.c static and created empty checks. Methods in object.c that weren't used anywhere else were made static. Methods in object.c that weren't static where assigned an empty test in check_object.c | |||
Show difference between Revision 1.127 and 1.128 | |||
Revision 1.127 | akirschbaum | 2006/06/02 03:19:35 | +5 -1 |
Do not merge renamed items with differing custom names. | |||
Show difference between Revision 1.126 and 1.127 | |||
Revision 1.126 | akirschbaum | 2006/06/01 15:55:54 | +3 -7 |
Do not merge locked and unlocked items. | |||
Show difference between Revision 1.125 and 1.126 | |||
Revision 1.125 | mwedel | 2006/05/30 02:16:23 | +4 -2 |
Various bug fixes, related to the new map display code. common/loader.c, common/loader.l: Add map_layer attribute so object can override what layer it should go on (fix for levitation boots). common/map.c: Add support for map_layer to override layering. Fix bug where if there were more objects than would fit on a layer, not all would be drawn (same object was duplicated onto multiple layers). common/object.c: Add check for ob->map_layer in can_merge() include/map.h: Add extern declaration for map_layer_name[] include/object.h: Add map_layer to object. socket/request.c: In map1 compatibility mode, make sure we always send the player. MSW 2006-05-29 | |||
Show difference between Revision 1.124 and 1.125 | |||
Revision 1.124 | tchize | 2006/04/06 16:18:34 | +147 -1 |
finished common/arch.c unit test, fixed a few bugs, moved function around and renamed other | |||
Show difference between Revision 1.123 and 1.124 | |||
Revision 1.123 | ryo_saeba | 2006/03/18 09:05:31 | +88 -117 |
Massive cleaning of code. Shouldn't be any functional change. | |||
Show difference between Revision 1.122 and 1.123 | |||
Revision 1.122 | akirschbaum | 2006/02/08 18:48:36 | +19 -19 |
Apply patch #1427979 (code-cleanup: add const, fix warnings) by Stefan Huehner. | |||
Show difference between Revision 1.121 and 1.122 | |||
Revision 1.121 | mwedel | 2006/02/07 01:54:45 | +17 -5 |
Code that adds transports. Transports are described more in detail in docs/Developers/objects. --- loader.l: Add new move type ('boat'). Update move_name field to be aware of this type. common/object.c: Unrelated to transport, but more apparant with transports - fix bug with insert_ob_in_map() and multipart objects - we now only try to fix up map and coordinates if the provided coordinates are out of the map. Before, function would always use the passed map for multipart objects, which is incorrect if we have already set valid coordinates. doc/Developers/objects: Update notes for TRANSPORTS. Update move information to include MOVE_BOAT. include/define.h: Add type TRANSPORT. Add MOVE_BOAT. include/player.h: Add transport field to player structure. include/sproto.h: rebuilt. server/apply.c: Add code to handle applying of transports. Update apply_below to apply transport if player is on one. server/attack.c: Update hit_map() to look for transports, and hit any players with the damage. server/c_object.c: Update put_object_in_sack() to also handle TRANSPORTS so that code can be re-used. server/move.c: Fix handling of multipart objects in move_object() - old code didn't work right with multipart objects moving along seams of tiled maps. Add code to move_ob() to update player map position for all players in a moving transport. server/player.c: Update move_player_attack() too check of player is in tranport, and use that for map and location information. Update move_player() to handle speed related issues with transports. server/time.c: Add code to credit time back to TRANSPORT objects since we remove time in move_player() for TRANSPORTS. socket/item.c: Add add_object_to_socklist() so that same code isn't reproduced in 3 different places in the file. Update draw_look() to handle transports - send transport object itself, then objects in transport. Update esrv_send_inventory() and esrv_send_item() to use add_object_to_socklist(). Update esrv_get_ob_from_count() to look for objects in transport if player is in transport. socket/loop.c: Remove checking of pl->map status, since draw_client_map() does that, and we need to handle if the player is in a transport. socket/request.c: Handle map drawing if player is in a transport. MSW 2006-02-06 | |||
Show difference between Revision 1.120 and 1.121 | |||
Revision 1.120 | mwedel | 2006/02/04 23:27:07 | +7 -2 |
movement type changes. Add move_allow field to explicitly allow certain movement types on spaces. Add suppport for using string names instead of numeric values to specify the MOVE_ values. Add code so when saving data out, use string names instead of numeric value. --- common/loader.l: Remove save_double(), as it isn't used by any code. Add set_move() to set movement types from strings. Add get_string_move_type, which takes integer movement type and returns a string. Update load and save code to use these functions respectively. common/map.c: Change blocked_link() so that we only examine all the objects on a space if there is something alive on the space or space is otherwise blocked. There is no reason to examine all the objects on the space if the object in question can move onto it. Modify update_position() to use the move_allow field to clear bits in the move_block field. common/object.c: Add check in CAN_MERGE for move_allow. Add check for move_allow in update_object to see if we should update the space or not. doc/Developers/objects: Update Movement code section to note use of using strings to set movement types. Add note about move_allow. Section about Transports added, but code isn't there yet. include/object.h: Add move_allow to object structure. MSW 2006-02-04 | |||
Show difference between Revision 1.119 and 1.120 | |||
Revision 1.119 | qal21 | 2006/01/08 17:57:17 | +3 -2 |
Fixed misc 'warning: will never be executed' stuff | |||
Show difference between Revision 1.118 and 1.119 | |||
Revision 1.118 | akirschbaum | 2006/01/01 14:36:07 | +15 -16 |
Make EXITs affect DM players again. | |||
Show difference between Revision 1.117 and 1.118 | |||
Revision 1.117 | akirschbaum | 2005/12/10 08:27:09 | +18 -12 |
common/object.c, server/{pets.c,player.c,spell_attack.c,time.c}, socket/request.c: Properly check for P_OUT_OF_MAP after calling get_map_flags(). | |||
Show difference between Revision 1.116 and 1.117 | |||
Revision 1.116 | akirschbaum | 2005/12/05 17:34:03 | +8 -8 |
Apply patch #1371956 (code cleanup patch) by Stefan Huehner: fix old-style function declarations and prototypes to proper Ansi C syntax. This patch allows the compiler to check function arguments and also removes some warnings when compiling with -Wstrict-prototypes. | |||
Show difference between Revision 1.115 and 1.116 | |||
Revision 1.115 | akirschbaum | 2005/12/05 16:58:34 | +10 -2 |
Fix bug #1173563 (Creator created Bombs malfunction): Creators and Converters now copy items from inventory. Fallback (for empty inventory) is the old behavior to create the new item from other_arch. If the inventory contains more than one item, a random one is picked. | |||
Show difference between Revision 1.114 and 1.115 | |||
Revision 1.114 | akirschbaum | 2005/11/30 14:59:09 | +4 -1 |
common/time.c: In move_teleporter() and move_player_mover() do not affect DMs if FLAG_WIZPASS is set. common/object.c: In check_move_on() do not affect DMs if FLAG_WIZPASS is set. This prevents DMs from triggering traps when walking over them. | |||
Show difference between Revision 1.113 and 1.114 | |||
Revision 1.113 | akirschbaum | 2005/11/28 13:50:34 | +2 -2 |
common/object.c: Fix wrong comparision operator in free_object2() to make monsters drop loot again. | |||
Show difference between Revision 1.112 and 1.113 | |||
Revision 1.112 | mwedel | 2005/11/16 02:16:00 | +122 -42 |
Commit for new blocking code. Not going to dictate all the changes - but will outline the broad points. Note also that the doc/Developers/objects is updated and goes into more details also. - check for P_WALL no longer used - instead, need to use GET_MAP_MOVE_BLCOK and check against movement type of objects. - arch_blocked() changed to ob_blocked(), now takes object. Needed because just looking at archetype move_ values is no longer sufficient. - find_first_free_spot() changed to take object, since it just calls arch_blocked() - FLAG_FLYING removed, now in move type. - walk_on/walk_off/fly_on/fly_off removed - now based on move_on and move_off fields. - Map space structure extended to hold the move_on/move_off, etc values so that we can shortcut some processing by not having to check every object on the space when something enters it if move_on isn't set. - archetypes recollected - boulders needed move_walk to properly trigger buttons. - Note that the new plugin code has to be fixed up for the new movement code. Look for FIXME in plugins/cfpython/cfpython_object.c MSW 2005-11-15 | |||
Show difference between Revision 1.111 and 1.112 | |||
Revision 1.111 | akirschbaum | 2005/11/01 04:08:17 | +10 -1 |
Add new function object_get_env_recursive() to find the outermost environment object for a given object. | |||
Show difference between Revision 1.110 and 1.111 | |||
Revision 1.110 | akirschbaum | 2005/10/28 18:43:30 | +8 -1 |
Prevent problems (crashes) for large item piles. Now limit nrof to less than 2^31. | |||
Show difference between Revision 1.109 and 1.110 | |||
Revision 1.109 | akirschbaum | 2005/10/28 14:08:53 | +2 -2 |
Fix compiler warnings. Most changes do not change the program (remove unused variables, convert "if(x = y)" into "x = y; if(x)"); a few actually fix (possible) problems (fix uninitialized variables, fix printf format specifiers, fix mismatches between signed and unsigned variables, add missing return and default statements). | |||
Show difference between Revision 1.108 and 1.109 | |||
Revision 1.108 | gros | 2005/10/18 11:54:30 | +2 -2 |
Upgrade of the Crossfire server to version 2.0 of the plugin interface. Upgrade of the Python plugin to version 2.0 of the plugin interface. Gros - 18/10/05 | |||
Show difference between Revision 1.107 and 1.108 | |||
Revision 1.107 | ryo_saeba | 2005/10/09 03:49:59 | +2 -2 |
Fix bug in key/value. Can now drop item when applying food/potion/poison. | |||
Show difference between Revision 1.106 and 1.107 | |||
Revision 1.106 | akirschbaum | 2005/10/07 18:35:33 | +11 -5 |
Prevent objects from losing inventory when thrown. include/libproto.h, common/object.c: Add new parameter "free_inventory" to free_object(). Is set, free inventory as well instead of dropping it on the ground. common/object.c: In get_split_ob() prevent inventory of splitted object to be dropped. | |||
Show difference between Revision 1.105 and 1.106 | |||
Revision 1.105 | qal21 | 2005/10/07 14:41:48 | +2 -12 |
Use object_create_clone in get_split_ob; Fixes things inside of objects disappearing when throwing. | |||
Show difference between Revision 1.104 and 1.105 | |||
Revision 1.104 | akirschbaum | 2005/10/07 12:54:48 | +3 -3 |
common/{arch.c, object.c}, crossedit/{Attr.c, Defines.h, Edit.c}, include/libproto.h, server/{plugins.c, time.c}: Rename functions with mixed-case names to lower case only. crossedit/Defines.h: Remove prototypes for nonexisting functions. | |||
Show difference between Revision 1.103 and 1.104 | |||
Revision 1.103 | ryo_saeba | 2005/10/01 11:36:35 | +3 -3 |
Clean some compilation warnings. | |||
Show difference between Revision 1.102 and 1.103 | |||
Revision 1.102 | akirschbaum | 2005/09/02 19:12:03 | +2 -2 |
common/object.c: Fix update of player's ground view in insert_ob_in_map(). Previously the ground view was not updated after applying exits or after being hit by a spell. | |||
Show difference between Revision 1.101 and 1.102 | |||
Revision 1.101 | tchize | 2005/08/31 15:07:22 | +16 -9 |
Accelerated map loading (a lot) and map saving (a bit) codes to improve map transition experience. | |||
Show difference between Revision 1.100 and 1.101 | |||
Revision 1.100 | mwedel | 2005/08/28 22:52:49 | +4 -3 |
Fix up comment so easier to parse - using double negatives just makes things confusing. MSW 2005-08-28 | |||
Show difference between Revision 1.99 and 1.100 | |||
Revision 1.99 | mwedel | 2005/08/23 00:42:58 | +268 -6 |
Apply patch 1200555 - addition of key/value lists which allows arbitrary storing of data in objects - see doc/Developers/key-value for more information --- loader.l, loader.c: Add add_key_value() function which parses the unknown line in the object/archetype. Update get_ob_diff() to make differences for the key/value lists. common/object.c: Add functions for properly comparing the key/value lists, setting and getting the vaues, clearing values upon freeing of object, etc. doc/Developers/Makefile.am: Add key-value file. doc/Developers/key-value: Documentation of this feature. include/libproto.h: Rebuilt include/object.h: Addition of key_value struct, addition of key_values field to object. MSW 2005-08-22 | |||
Show difference between Revision 1.98 and 1.99 | |||
Revision 1.98 | ryo_saeba | 2005/08/12 08:46:34 | +2 -2 |
Fields changed from char* to const char*, cleanup. | |||
Show difference between Revision 1.97 and 1.98 | |||
Revision 1.97 | ryo_saeba | 2005/07/15 08:51:49 | +9 -9 |
Glue cleaning. New plugin function. | |||
Show difference between Revision 1.96 and 1.97 | |||
Revision 1.96 | mwedel | 2005/04/16 00:30:47 | +4 -4 |
Commit patch that makes lighting illuminate in a circular instead of square radius. Patch by Rednaxela - patch 1171646 MSW 2005-04-15 | |||
Show difference between Revision 1.95 and 1.96 | |||
Revision 1.95 | akirschbaum | 2005/02/20 14:43:09 | +2 -2 |
common/object.c, include/libproto.h: change nrof parameter of get_split_ob to uint32 type. server/c_object.c, include/sproto.h: change nrof parameter of drop_object to uint32 type. plugin/{plugin_python.c, include/plugin_python.h}, plugin_animator/{plugin_animator.c, include/plugin_animator.h}, server/{apply.c, attack.c, gods.c, monster.c, player.c, skills.c, time.c, timers.c}: Change type of CFParm.Value[5] and StackParm1[] to uint32 to be able to pass an "nrof" value. | |||
Show difference between Revision 1.94 and 1.95 | |||
Revision 1.94 | mwedel | 2005/01/24 01:29:24 | +3 -3 |
common/object.c: Change CAN_MERGE() from an inline function, since it calls itself and inline functions are not supposed to do that. Update type check in insert_ob_in_map() to check against defined type (EXIT) instead of hardcoded integer value (66). crossedit/xutil.c: Update to just include Defines.h, which then includes all the other necessary files, including global.h. include/global.h: Add #ifdef checks for the UINT*_MAX types, as some systems already define these values, which results in a redefinition error. Also fix up // style comment. include/shstr.h: Include proper cast in TOPBIT definition. server/main.c: Don't display 'xyz left the game' messages if the player is only at the get name or get password prompt. Prevents possible spoofing of that message. server/player.c: Clean up formatting of check_pick() function. If player is using newpickup to pick up booze, also pick up poison unless they know it is cursed. socket/request.c: AskSmooth() - change buffer type to uint8 so that it matches what the SockList structure wants. utils/scores.pl.in: Use skill_praying to find players god, and not the deprecated experience_wis object. MSW 2005-01-23 | |||
Show difference between Revision 1.93 and 1.94 | |||
Revision 1.93 | ryo_saeba | 2004/11/25 12:26:53 | +3 -2 |
Apply patch #1066665 | |||
Show difference between Revision 1.92 and 1.93 | |||
Revision 1.92 | mwedel | 2004/10/15 02:09:39 | +3 -2 |
common/living.c: Fix exp functions to use the player objects expmul value when determining level gains, and not the skills. Also, fix bug where players last hp/sp/grace gain I think was being re-rolled when player gained level in skill. common/loader.l, loader.c: Add better recording of non existant objects (no archetype for them) in maps. Also, handle such objects in players inventories properly (which is to just discard them) common/map.c: Add better logging about discarded archetypes. Since the loader now deals with objects without archs in inventories, that code doesn't need to be in the server. common/object.c: copy_object() was not properly nulling out the next field in the event object, pointer to event list was also incorrect, causing events to not be copied properly. doc/spoiler-html/spoiler.html: Rebuilt. server/apply.c: Apply patch by MT that fixes problem of entire inventory not being copied properly. Fix problem that objects in creatures were not having any sub treasure created (eg, put a pyro_book in a monster on the map, and the pyro_book wouldn't have a spell in it) - now we make sure we process inventory objects as well as map objects, creating treasure as needed. server/monster.c: Reverse order of cast_spell() and drain_rod() in monster_use_range() - drain_rod() should go first, because case_spell() can in rare cases destroy the rod. MSW 2004-10-14 | |||
Show difference between Revision 1.91 and 1.92 | |||
Revision 1.91 | mwedel | 2004/09/03 01:43:42 | +2 -2 |
common/object.c: Fix insert_ob_in_map so right coordinates and map value are used on GET_MAP_OB call - was using values before changes for tiling were applied. MSW 2004-09-02 | |||
Show difference between Revision 1.90 and 1.91 | |||
Revision 1.90 | mwedel | 2004/08/18 02:02:19 | +4 -1 |
If MANY_CORES is defined, and we get call to update_object() with invalid coordinates, call abort to make debugging easier. Ignoring the error seems only marginally useful, as I've observed a crash after a bunch of errors from that area. MSW 2004-08-17 | |||
Show difference between Revision 1.89 and 1.90 | |||
Revision 1.89 | akirschbaum | 2004/06/13 12:30:21 | +1 -3 |
common/object.c include/define.h include/player.h include/sproto.h server/attack.c server/c_object.c server/player.c server/shop.c socket/item.c socket/loop.c socket/request.c: Remove explicit calls to esrv_update_item(UPD_WEIGHT, pl, pl) for player objects. Instead send the new weight whenever it changes. | |||
Show difference between Revision 1.88 and 1.89 | |||
Revision 1.88 | mwedel | 2004/06/11 01:12:57 | +11 -7 |
common/object.c: insert_map_in_ob() - remove CAN_MERGE checks after the map translation - otherwise, we can have bogus coordinates that are used for GET_MAP_OB. random_maps/style.c: pick_random_object() - have it return null object (and probably crash) instead of getting into an infinite loop. server/c_wiz.c: command_kick() - check FLAG_FREED of player. Remove all the broken skill/exp object granting code in command_possess() - this is probably still a broken function. server/spell_attack.c: mood_change() - fix get_map_ob call - wasn't using correct coordinate variables, resulting in crash. MSW 2004-06-10 | |||
Show difference between Revision 1.87 and 1.88 | |||
Revision 1.87 | akirschbaum | 2004/05/18 11:11:52 | +29 -89 |
common/object.c: Correct get_search_arr() to return a proper permutation. Andreas Kirschbaum 2004-05-18 | |||
Show difference between Revision 1.86 and 1.87 | |||
Revision 1.86 | mwedel | 2004/04/14 02:24:30 | +2 -11 |
common/object.c: Change CAN_MERGE() so that it compares the stats structure of the objects being merged. Fixes problems of rings improperly merging with other rings that have different stat values. server/monster.c: Modify check_earthwalls() and check_doors() to take a map structure as an option parameter, and use that structure when calling get_map_ob. Fixes a crash in cases where earthwalls/doors were at the edge of a tiled map, and creature was on other map moving into it. server/move.c: Change move_ob() to adjust coordinates for tiling, and pass in these adjusted coordinages (and map) to the check_() functions in monster.c random_maps/treasure.c: Apply patch by Andreas Kirschbaum so that it does more work in trying to place keys on maps. MSW 2004-04-13 | |||
Show difference between Revision 1.85 and 1.86 | |||
Revision 1.85 | mwedel | 2004/02/23 00:06:29 | +8 -14 |
common/object.c: Change CAN_MERGE() so that we never merge applied objects - whether or not they are rings. server/spell_attack.c: Fix cast_cone() so that it properly hits all directions. MSW 2004-02-22 | |||
Show difference between Revision 1.84 and 1.85 | |||
Revision 1.84 | mwedel | 2004/02/13 01:42:09 | +14 -7 |
common/object.c: change get_owner() so that it also returns no valid owner if the owner is removed. This fixes a crash if a player quits but is still sitting at the play again prompt when something he owns kills something. server/skill_util.c: Fix show_skills() so that if the character has too many skills for whatever reason, we don't crash, and instead print an error to the player. server/spell_attack.c: Fix typo - not sure actual effect, but probably nothing good. '+ +' should just have been '+' MSW 2004-02-12 | |||
Show difference between Revision 1.83 and 1.84 | |||
Revision 1.83 | mwedel | 2004/02/11 02:09:22 | +3 -3 |
common/Makefile.am: Clean up proto - lex seems to toss some new symbols in now days. common/map.c, common/object.c, server/player.c, socket/item.c, socket/request.c: change parameters of get_map_from_coord from int to sint16, so the op->x,op->y can get passed directly in. Update callers of this function. lib/archetypes: Add damned 1 to the shop floors. server/pets.c: Fix problem with big (multisquare) pets following the owner across tiled map boundaries. socket/item.c: Fix problem of players being able to see everything within containers by just looking at them. MSW 2004-02-10 | |||
Show difference between Revision 1.82 and 1.83 | |||
Revision 1.82 | mwedel | 2004/02/11 01:40:17 | +18 -25 |
Clean up even freeing code. Functionality should basically be the same, but IMO is a bit clear/more efficient now. MSW 2004-02-10 | |||
Show difference between Revision 1.81 and 1.82 | |||
Revision 1.81 | mwedel | 2004/02/08 23:36:12 | +70 -47 |
common/object.c: Clean up formatting of copy_object. Only real code change is to fix events - copied event data wasn't getting malloc'd, and thus when another object of that event was freed, it freed the event data for all objects derived from it. common/treasure.c: Fix fix_generated_item() so that books generated by monsters with no_pick set don't inherit that for the book itself. Still do it for other objects of the creator type. MSW 2004-02-08 | |||
Show difference between Revision 1.80 and 1.81 | |||
Revision 1.80 | ryo_saeba | 2004/01/16 17:15:25 | +4 -4 |
Hook strings-related certain crash | |||
Show difference between Revision 1.79 and 1.80 | |||
Revision 1.79 | onefang | 2004/01/12 00:26:28 | +3 -2 |
common/object.c: fix the monsters on tiled maps bug that I may have mentioned a while ago. Seems that the server assumed that all parts of a multi part monster are on the same map as the head while moving. DVS 2004-01-12 | |||
Show difference between Revision 1.78 and 1.79 | |||
Revision 1.78 | mwedel | 2003/12/20 20:13:46 | +28 -29 |
common/object.c: Set op->events=NULL in reset_object(), and move the clearing of the op->events structure to be before the memset in clear_object() - this was otherwise resulting in a memory leak, as memset would clear the pointer without actually freeing the data. server/attack.c: Fix indentation of hit_map(), modify it so that attacks won't destroy items with no_pass set. server/login.c: set op->speed=0, call update_ob_speed() before calling reset_object() - fixes problem with players not moving with recent changes to initting the active lists to NULL. msw 2003-12-20 | |||
Show difference between Revision 1.77 and 1.78 | |||
Revision 1.77 | ryo_saeba | 2003/12/18 14:39:44 | +4 -2 |
GCC 3.3 infinite loop fixes | |||
Show difference between Revision 1.76 and 1.77 | |||
Revision 1.76 | ryo_saeba | 2003/12/14 10:28:47 | +3 -3 |
Compilation warning cleaning | |||
Show difference between Revision 1.75 and 1.76 | |||
Revision 1.75 | mwedel | 2003/10/27 01:24:14 | +2 -2 |
Various bug fixes: common/arch.c: Fix item_matched_string() so that it only passes in the length of the pssed in name in the strncasecmp(), and not the shorter of the passed in string or item name. Otherwise, if player does a 'drop wand of', unidentified wands (name just wand) would match. Similarly, if a player did 'drop ringmail', unidentified rings would match, etc. common/living.c: Fix fix_player() to always process the praying skill with respect to resistances and whatnot. This is necessary because the god give abilities are put in this skill, and those shouldn't go away depending on if the skill is in use or not. Also fix bug in add_exp routines which wasn't multiplying permanent exp by PERM_EXP_GAIN_RATIO common/object.c: Fix find_obj_by_type_subtype() - had extraneous semicolon after the for loop, so the if code that was supposed to be for each object was never called and instead would crash as it would get called with tmp was null. server/attack.c: Fix problem with kill_object() not finding proper skill - it would use the skill object instead of the skill. Fix problem of poisoning not setting up proper skill name in poisoning object. server/c_range.c: If player is invoking a spell, don't update their range_magic value. server/skill_util.c: Fix divide by zero problem if improperly passed skill object. MSW 2003-10-26 | |||
Show difference between Revision 1.74 and 1.75 | |||
Revision 1.74 | mwedel | 2003/10/26 01:56:56 | +3 -3 |
common/glue.c, common/object.c, common/player.c, include/funcpoint.h, server/init.c, server/monster.c, server/shop.c, server/skill_util.c: add find_skill_by_number() function - this replaces find_skill. Locate new function in skill_util.c, which is more a proper place than common/player.c - this change necessitated adding glue function pointers so the other common files can call it. server/spell_effect.c: Fix cast_heal() so if the spell is not one that heals hit points, don't process the code that checks for that and sets a false success value. socket/metaserver.c: Clean up formatting - no code changes. MSW 2003-10-25 | |||
Show difference between Revision 1.73 and 1.74 | |||
Revision 1.73 | mwedel | 2003/09/13 00:01:29 | +184 -67 |
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.72 and 1.73 | |||
Revision 1.72 | temitchell | 2003/09/04 01:25:32 | +2 -3 |
- add new type TRAP, make initial seperations from RUNE in code add in traps triggering stuff if they are detonated | |||
Show difference between Revision 1.71 and 1.72 | |||
Revision 1.71 | tchize | 2003/09/03 07:25:06 | +43 -10 |
generator may now use their inventory as a basis to generated items instead of the other_arch field. Will allow more fine tuned generators | |||
Show difference between Revision 1.70 and 1.71 | |||
Revision 1.70 | garbled | 2003/07/13 02:21:11 | +3 -2 |
Fix the bug where multi-tiled houses end up partially obscured by the snow. | |||
Show difference between Revision 1.69 and 1.70 | |||
Revision 1.69 | gros | 2003/06/26 06:27:43 | +28 -7 |
Re-implemented the event hooks in objects as a dynamically linked list, instead of a static table. | |||
Show difference between Revision 1.68 and 1.69 | |||
Revision 1.68 | mwedel | 2003/04/04 23:39:48 | +3 -2 |
acinclude.m4: Update path to find python includes, since aclocal.m4 gets derived from this file. configure.ac, configure: Add utils/scores.pl to list of files to substitute on. common/loader.l, loader.c: Add subtype for objects - will be used in future work. common/object.c: Add subtype diff check in CAN_MERGE() common/porting.c: Have it use SAVE_DIR_MODE when doing the mkdir, and not have hardcoded 777 permissions. doc/Makefile.in, doc/Makefile.am, doc/Developers/Makefile.am, doc/Developers/Makefile.in: Move some of the spell docs around and merge them together doc/Developers/objects: Add notes about subtype. doc/Developers/spells: New file, contains preliminary work on spell objects. include/config.h: Remove command about DM_MAIL and LIBDIR from file, as they are options no longer present. Update comment about SAVE_MODE, and add SAVE_DIR_MODE include/object.h: Add subtype field to object. server/login.c: Have it use SAVE_DIR_MODE when doing the mkdir, and not have hardcoded 6700 permissions. utils/Makefile.in: Updated to know about scores.pl utils/scores.pl.in: New file - reads player file to generate HTML score file. MSW 2003-04-04 | |||
Show difference between Revision 1.67 and 1.68 | |||
Revision 1.67 | mwedel | 2003/02/12 00:30:26 | +42 -38 |
Add lore/endlore to object structure to hold general information about objects: common/loader.c, common/loader.l: Add loading and saving of lore field. common/object.c: handle lore field for copy/free/other object operations. Also, update CAN_MERGE to look at materialname also. doc/Developers/objects: Add notes about lore. include/object.h: add lore field to object. MSW 2003-02-11 | |||
Show difference between Revision 1.66 and 1.67 | |||
Revision 1.66 | mwedel | 2003/02/03 22:06:13 | +2 -2 |
Oops. Meant materialname, not material. MSW 2003-02-03 | |||
Show difference between Revision 1.65 and 1.66 | |||
Revision 1.65 | mwedel | 2003/02/03 22:01:11 | +2 -1 |
Fix missing initialization of material, causign continous crashes on metalforge. MSW 2003-02-03 | |||
Show difference between Revision 1.64 and 1.65 | |||
Revision 1.64 | garbled | 2003/01/29 18:07:08 | +9 -1 |
New materialtype system for crossfire. Based in concept on my original design, but rewritten from scratch to make it easily extensible. In a nutshell: Each of the old materialtypes (metal, glass, stone, wood) are now a class of materials. When an item in the game is created, if it does not have a specific materialname of it's own, a materialname is generated randomly from the matching entries in the "lib/materials" file. This file contains all of the saving throws, and other material specific modifications for each of the expanded materials. Materials can be manually specified in the arch with the "materialname" directive. Such as the gold coins, which are specified to be made of, you guessed it, gold. Saving throws have been slightly rewritten to use the new materialtypes, and a few other minor details associated with materialtypes have been patched up. Adding a new type of stone or wood, is as simple as adding a new entry in the lib/materials file. The game will automatically start distributing them around randomly. | |||
Show difference between Revision 1.63 and 1.64 | |||
Revision 1.63 | mwedel | 2003/01/21 02:10:05 | +8 -1 |
have it abort() if trying to insert an object outside the map. MSW 2002-01-20 | |||
Show difference between Revision 1.62 and 1.63 | |||
Revision 1.62 | mwedel | 2003/01/08 02:39:17 | +134 -138 |
Bulk of this commit is to improve code for tiled maps - replace wall/blocks_magic/blocks_cleric, etc with get_map_flags which also does map tiling translation as needed. This should fix a lot of the bugs related to map tiling (there are sure to be more out there - all the get_map_ob still need to be checked). Other changes - many spells stopped progressing on spaces that blocked view - that is now removed - didn't make a lot of sense. Other fixes - some cleric spells (eg, word of recall) checked to see if magic was prohibited, didn't check to see if cleric was prohibited. Clean up some bugs in the lighting code that would cause erroneous results. Also, allow players to see immediately around them on outdoor maps no matter how dark the map really is - behaviour on indoor maps is the same. Lots of code reformatted, and lots of obsoleted/dead code removed. Add max range to dimension door. Fix magic map - got broken when the layer stuff was redone - was not showing proper colors. IT also works sensibly on tiled maps now - rather than display based on the map, it gives the player a 50x50 area centered on where the player is. Change fire_bow - move special player fire modes into own function - makes code much cleaner. Hopefully this fixes more bugs than it introduces. common/los.c, common/map.c, common/object.c, crossedit/Edit.c, include/libproto.h, include/sockproto.h, include/map.h, include/spellist.h, include/sproto.h, random_maps/treasure.c, random_maps/wall.c, server/attack.c, server/c_misc.c, server/c_wiz.c, server/disease.c, server/main.c, server/monster.c, server/pets.c, server/player.c, server/rune.c, server/shop.c, server/skill_util.c, server/skills.c, server/spell_effect.c, server/spell_util.c, server/time.c, socket/info.c: See note above server/apply.c: Limit number of times weapon can be enchanted so that it won't overflow item_power. Modify enchant armor to enchant as normal armor is enchanted, also only allows one item to be enchanted. MSW 2002-01-07 | |||
Show difference between Revision 1.61 and 1.62 | |||
Revision 1.61 | garbled | 2002/12/25 00:45:46 | +5 -2 |
New Arrow and Pet Code: Add bowmode and petmode commands. Allowing the player to change the firing style for bows to one of either threewide, or spreadshot. Allow players to change the operating modes of his pet with petmode. Can be either seek and destroy, defend, or normal historical behavior. Change bows to impart speed to arrows based on damage and other magical plusses. Damage decays over distance, to stop arrows from flying forever. Very fast moving arrows will pierce multiple targets. An arrow moving at a speed greater than 10.0 will go straight through a target, losing 1.0 of speed in the process. Change magic missile to use spell_find_dir instead of find_dir to stop it from flying in a circle and hitting the caster, and to make it stop flying into walls to hit creatures behind the walls. | |||
Show difference between Revision 1.60 and 1.61 | |||
Revision 1.60 | mwedel | 2002/11/30 21:46:25 | +77 -57 |
common/object.c, include/object.h: Add INS_BELOW_ORIGINATOR flag to insert_ob_in_map - this is used for treasure chests so the treasure is put below the player. Also fix insertiong of items on spaces that block view - put them in proper order, and not just directly above the floor server/apply.c: Tell player what level they need to be if they are not of sufficient level to improve armor. Modify apply_treasure to use INS_BELOW_ORIGINATOR flag, clean up some of the other logic in apply_treasure. server/c_object.c: Modify command_take to use the container inventory when doing a pickup, and not the container itself. MSW 2002-11-30 | |||
Show difference between Revision 1.59 and 1.60 | |||
Revision 1.59 | garbled | 2002/11/12 18:49:46 | +3 -4 |
#ifdef CASTING_TIME -> settings.casting_time | |||
Show difference between Revision 1.58 and 1.59 | |||
Revision 1.58 | mwedel | 2002/09/07 00:55:18 | +28 -1 |
More bugfixes: common/loader.l, loader.c: Fix up the handling with speed with respect to style maps - the objects were still getting put on the active list. common/map.c: Fix up blocked_link() to behave more like the blocked_two() function - inventory checkers and door handling. Comment out blocked_two since it isn't used anymore. Modify load_objects to remove objects on style maps from the active list. Remove some of the debug messages about map loading. common/object.c: Add remove_from_active_list() function for use in map.c to remove objects from active list. common/porting.c: Comment out debug message if open_and_uncompress() can open a file - caller of the function should print out messages, and it really isn't much of an error in any case. include/libproto.h: rebuilt. random_maps/special.c: Modify place_special_exit() - this should fix bug of very large treasure maps - problem was if the generated map size was too small, when generate_random_map was called, it would generate a newly sized map that was much larger. Code was also re-arranged some to make it a little more readable. server/attack.c: Fix crash when creature may not have an owner and it kills something else. server/move.c: comment added - no code change. socket/request.c: Fix off by one error in esrv_send_animation() - rare condition as it only showed up when trying to send the last animation (zombie) - only an issue if the player is put on top of a zombie for some reason (no other space for them) - observed when leaving the random dungeon in the undead church in scorn without clearing out all the zombies first. MSW 2002-09-06 | |||
Show difference between Revision 1.57 and 1.58 | |||
Revision 1.57 | mwedel | 2002/09/01 01:32:30 | +101 -1 |
This change mostly deals with improving behaviour of pet monstes. Most of the code is from K. Reinert - however, I did some code cleanup/ fixes related to pet monsters, so it is difficult to note where each piece of code came from. One thing this does fix is handling of multipart pets - these now work properly. common/map.c: Update comment for get_rangevector() - no code change. common/object.c: Add get_search_arr() which is used in pet monster code. This returns a semi random scrambling of the freearr array. doc/Developers/protocol: Update documentation about map1a protocol command. include/libproto.h, include/sproto.h: rebuilt. server/attack.c: Have drain attacks return 1 damage so that it is clear that you are actually hitting your opponent. Otherwise, you would get messages that 'you missed xyz', even though you are draining it. This extra point of damage shouldn't change balance in any significant way. server/monster.c: Update hnadling of enemies for pet monsters. It should more intelligently choose the monsters and not switch/clear the enemy field for no reason anymore. Change find_nearest_living_creature to use the get_search_arr() to more randomly choose direction of target - before, there was a proclivity to always look in the north direction. Modify can_hit() to look for closes part of enemy - otherwise, monsters may not attack opponents even if they were right next to them because they couldn't get to the enemies head. Remove move_object from this function - merged with move_ob in move.c server/move.c: Fix move_ob to use 'cleaner' code of move_object, but also have specific features that move_ob had (player handling). Before move_ob didn't handle multipart objects correctly, and the two functions were largely the same. Now move_object() just calls move_ob - the only difference in the functions is that move_ob() takes 3 parameters instead of 2 of move_object() (added parameter is originator). I think this should now mean multipart player objects may now work. server/pets.c: get_pet_enemy enhanced to be much smarter about selecting/finding things for the pet to attack. server/player.c: Remove commented out line of init_beforeplay MSW 2002-08-31 | |||
Show difference between Revision 1.56 and 1.57 | |||
Revision 1.56 | mwedel | 2002/07/14 23:57:12 | +45 -94 |
-- 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.55 and 1.56 | |||
Revision 1.55 | mwedel | 2002/05/30 23:18:33 | +19 -8 |
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.54 and 1.55 | |||
Revision 1.54 | mwedel | 2002/05/18 22:55:48 | +1 -2 |
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.53 and 1.54 | |||
Revision 1.53 | avogl | 2002/03/11 16:02:37 | +16 -3 |
common/object.c: I saw from mids' cores that the server crashed inside the update_object() function. Can't verify the crash, but I put in some extra security-checks which might help. server/attack.c Out-commented the errormessage "hit_map(): next object destroyed". This routine is by no means a bug/error, happens very frequently, and thus doesn't deserve to spam the logs. | |||
Show difference between Revision 1.52 and 1.53 | |||
Revision 1.52 | mwedel | 2002/01/14 00:03:31 | +7 -12 |
TODO: updated with bugs, remove things that have been done and are no longer TODO's. configure.in, configure: Remove lib/xpmtopix.pl file form those to be built, as that file has been removed. common/object.c: Fix bug in check_walk_on which would result in spell objects not being properly processed - the intention is not to process spell objects - we should stop going up (in previous loop) when we get such an object, not on the way down. This fixes directors not working really well. MSW 2001-01-13 | |||
Show difference between Revision 1.51 and 1.52 | |||
Revision 1.51 | garbled | 2002/01/01 17:37:54 | +2 -1 |
Add the concept of overlay maps to the code. An overlay map is a map which is loaded on top of another map, replacing values in the header, and placing objects on top of other objects. This is the fundamental part of the new weather code, but also can be used to allow dynamic editing of the worldmaps by DM's eventually. garbled 2002-01-01 Phase II of the new weather system is done. Please let me know immediately if this causes any bizzare effects. | |||
Show difference between Revision 1.50 and 1.51 | |||
Revision 1.50 | mwedel | 2001/12/23 02:17:36 | +1 -3 |
common/loader.l, common/loader.c, common/object.c, include/object.h, socket/item.c: Remove sub_type and sub_type2 information - these were poorly named fields and not properly implemented. common/treasure.c: Add missing return type to change_treasure function. crossedit/Edit.c: Add SET_MAP_FLAGS macro to set P_NEED_UPDATE flag before calling update_position. include/config.h: Add NEW_WORLD_MAP selection which results in proper emergency save paths if you are using the maps-bigworld distribution. server/c_wiz.c: Fix the formatting (indentation) of the command_create function. No actual changes in how it runs, but the old formatting was really terrible and inconsistent. server/main.c: remove call to send_mapstats_cmd server/monster.c: Update the comment style to be proper, as well as the comments themselves. socket/request.c: Fix up improper indentation in esrv_update_stats. remove send_mapstats_cmd function. MSW 2001-12-23 | |||
Show difference between Revision 1.49 and 1.50 | |||
Revision 1.49 | mwedel | 2001/12/15 21:31:02 | +2 -2 |
common/object.c random_maps/Makefile.in server/c_wiz.c server/player.c server/plugins.c server/timers.c socket/request.c: Most of the changes are to just fix compiling warnings or errors so that it compiles on sparc solaris with the workshop compiler (things like }; should just be }). Declaration for alphasort was missing in plugins.c. random_maps/Makefile.in had the wrong order in linking - the system library needs to be linked in after the crossfire libraries. crossedit/App.c: Fix for running on 8 bit color - colormap was not being initialized to usuable default value. crossedit/xutil.c: Broken code when duplicating faces for undefined images. That code should never really be used, as pixmaps currently are always contiguous. MSW 2001-12-15 | |||
Show difference between Revision 1.48 and 1.49 | |||
Revision 1.48 | michtoen | 2001/11/27 22:44:41 | +7 -3 |
Anim25 Patch This patch do this things mainly: - include same animation sheme for players and monster again - introduce guard/walk/fight animation in 8 direction - direct action: monster change from guard/walk animation when they get attacked and fall back to walk or guard when the enemy is gone - Monster do "intelligent" animation -> facing enemy -> turn and run when scared - fixed some animation flaws which invokes late anim update (monster moves first and hold one frame old facing) - Include real time player animation! -> player starts moving animation when player moves -> fall back to guard anim when player do nothing -> plays fight anim when hit some Hope i got all. This patch is much not so hard as it sounds. Most of these features was easy to include because the old anim engine was able to do about 80% of this. I had just to boost up the logic. | |||
Show difference between Revision 1.47 and 1.48 | |||
Revision 1.47 | michtoen | 2001/11/27 00:08:25 | +10 -2 |
had deleted AVs patch. Thx to mark he see it. | |||
Show difference between Revision 1.46 and 1.47 | |||
Revision 1.46 | michtoen | 2001/11/26 22:33:46 | +7 -0 |
Arch type & subtype patch Added type & subtype system with 2 subtypes. Type & subtype will be send to client. Adding new types: FLOOR 71 WALL 77 LIGHT_SOURCE 78 MISC_OBJECT 79 MONSTER 80 SPAWN_GENERATOR 81 Added subtypes for armor & weapons. new commands are: sub_type <uint8> sub_typ2 <uint16> sub_type2 is for internal server use. Added new command: casting_speed <delay> This will be included later. I will use the sdl client as tester for this patch, older clients will not be effected even when the arches are updated. | |||
Show difference between Revision 1.45 and 1.46 | |||
Revision 1.45 | michtoen | 2001/11/26 11:52:25 | +1 -7 |
Attack Patch 25.11.01 Detailed information in the dev list. The changes are to many to explain here. | |||
Show difference between Revision 1.44 and 1.45 | |||
Revision 1.44 | avogl | 2001/11/21 12:12:25 | +8 -2 |
This is a fix for the bug I mentioned on cf-devel earlier: The order to process objects (with move_apply()) must be top to bottom (like it used to be) and not the other way round. This should fix the problems with the altars in the mak-maps I have no idea why this had changed anyways. | |||
Show difference between Revision 1.43 and 1.44 | |||
Revision 1.43 | mwedel | 2001/11/05 21:39:31 | +8 -3 |
common/object.c: Modify copy_owner so that if a player is passed in as the object to copy, we properly set that player as the owner of the object instead of returning. This fixes the lack of exp when poison inflicted from a weapon kills something. MSW 2001-11-05 | |||
Show difference between Revision 1.42 and 1.43 | |||
Revision 1.42 | michtoen | 2001/11/04 14:22:55 | +0 -0 |
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.41 and 1.42 | |||
Revision 1.41 | michtoen | 2001/11/02 12:39:23 | +3 -1 |
Extended Animation Facings 18 This is the first step of complexer animation system (usable for flat & iso). This is not a fully clean implementation, because it depends on "one arch / one picture" which hopefully comes soon. MT02102001 | |||
Show difference between Revision 1.40 and 1.41 | |||
Revision 1.40 | garbled | 2001/10/31 01:00:24 | +2 -2 |
Big commit time. This does the following: Add weapontypes to the game. These are currently used for nothing other than messages, which are not fully written yet. Players should not see them appear yet. Fix the bug where you opened a door with a key and saw "You ." Fix a bug in the PLUGIN code where current_weapon wasn't set when the player loaded from savefile. Take the setting of current_weapon out of #ifdef PLUGIN garbled 2001-10-31 | |||
Show difference between Revision 1.39 and 1.40 | |||
Revision 1.39 | gros | 2001/10/14 02:57:14 | +82 -24 |
Major changes: Added dynamic plugin support, removed old Guile support. - Gros 10/14/01 | |||
Show difference between Revision 1.38 and 1.39 | |||
Revision 1.38 | mwedel | 2001/10/07 01:45:39 | +5 -4 |
common/map.c: Add INS_ON_TOP flag to insert_ob_in_map calls to preserve stacking order. Modify update_position to generate map spaces with more proper order. common/object.c: Modify insert_ob_in_map so that it preserves stacking if INS_ON_TOP is set. crossedit/CrEdit.c: Add missing code that would draw third face on a space. include/object.h: Add INS_ON_TOP flag/define. random_maps/exit.c: Modify code so that if the random maps leading to a special map are reset, they will properly link in with an already loaded final map (and update exit from final map back up) as needed. Also fix bug in that if the final map has been reset, a new one will now be properly loaded. random_maps/random_map.c:Update minimum size to be 7 (up from 6) - fixes bug which caused crashes when square_spiral maps of 6x6 would fail to generate. random_maps/random_map.h,random_maps/room_gen_onion.c: move OPT_values from room_gen_onion to random_map.h since the square_spiral code uses them. random_maps/square_spiral.c: Update call to map_gen_onion to use OPT_.. values instead of constant integer. random_maps/treasure.c: Add some casts to sprintf statements to eliminate some compiler warnings. server/main.c: Modify enter_exit code such that a random map has reset, we generate a new random map. This can happen when the random_map resets before the map that leads to them resets. MSW 2001-10-06 | |||
Show difference between Revision 1.37 and 1.38 | |||
Revision 1.37 | mwedel | 2001/08/05 17:34:04 | +18 -1 |
common/object.c:decrease_ob_nr modified to correctly update client when player uses item from container that is on the ground (bookshelf for example) server/time.c: move_teleporter modified to skip over wall/floors and teleport whatever is above them. MSW 2001-08-05 | |||
Show difference between Revision 1.36 and 1.37 | |||
Revision 1.36 | mwedel | 2001/08/05 00:07:20 | +9 -4 |
common/map.c: modify link_multipart_objects to preserve name and title of head when making the more parts. modify update_position so that it should never show an invisible face to the player. common/object.c: fix check_walk_on so that spells will now properly get affected by spinners and directories. include/sockproto.h: Rebuilt to include MapNewmapCmd server/hiscore.c: Fix crash if player savebeds map on map which does not have a name. Use the path instead. server/move.c: modify teleporter function to send MapNewmapCmd to client if player got teleported. Needed for fog of war code. server/time.c: modify move_teleporter so that it will not teleport walls. socket/Makefile.in: Modified to use cproto to generate proto files. MSW 2001-08-04 | |||
Show difference between Revision 1.35 and 1.36 | |||
Revision 1.35 | mwedel | 2001/08/03 01:19:52 | +2 -2 |
Fix bug of using uninitialized value that would then crash the server. MSW 2001-08-02 | |||
Show difference between Revision 1.34 and 1.35 | |||
Revision 1.34 | mwedel | 2001/07/31 01:33:23 | +2 -2 |
common/map.c free_map Set in_memory status to MAP_SWAPPED - fixed bugs of maps not getting reset properly common/object.c: insert_ob_in_map - was passing wrong value to check_walk_on, resulting in some things not working as expected. doc/Protocol: Clarify how the sending of the version command works. server/move.c: move_ob redone. It should hopefully be more efficient (only' remove objects after verifying they can in fact move). IMO, code is also simpler, and hopefully has fewer bugs. socket/init.c: InitConnection - modified to set faces_sent[0] to one so that we will never send any information about face 0 to the client. facecode 0 is sent in the map1 command to clear spaces/layers. MSW 2001-07-30 | |||
Show difference between Revision 1.33 and 1.34 | |||
Revision 1.33 | mwedel | 2001/07/20 01:14:28 | +9 -2 |
common/object.c: remove_ob - set P_NEED_UPDATE before calling update_position to prevent warnings from update_position being called with P_NEED_UPDATE being set. MSW 2001-07-19 | |||
Show difference between Revision 1.32 and 1.33 | |||
Revision 1.32 | mwedel | 2001/07/13 23:04:53 | +407 -571 |
common/Makefile.in: Remove ltostr.c and sqrt.c from list of files common/ltostr.c, common/sqrt.c: Moved into porting.c common/anim.c, common/button.c, common/item.c: Update calls to update_object common/living.c: have fix_player calculate light value for player/monster. common/logger.c: Remove code that has server exit if too many LOG messages happen too quickly. This was not a reliable mechanism, and it should really be up to the functions doing the logging to know if they can continue or not. common/los.c: Changes on how it deals with lighting on maps - get light value from map space array instead of using the linked list. Functions that managed the light list have been removed. Change logic of line of sight function to be more efficient (before, we may examine the same space multiple times). rename update_all_los to update_all_map_los, and change update_all_los to take coordinates so that we only have clients within view of the change recalculate los. Also, have update_all_los check for tiled maps that may have clients that need to get updated. common/map.c: remove refresh_map - this used to be used to try to recover from map errors if many_cores was not set - IMO better to core and just restart and really fix the error than try to deal with possible corruption that may otherwise result. Move open_and_uncompress and close_and_delete functions to porting.c - they are 'common' functions that are not related to the map code. Remove some lighting related code, as that is no longer done with a list. Many modifications because of new map structure. And logic to load and save the new map structure format. Modify many of the functions to take map tiling into account. Change way multipart objects are saved, and add logic to relink objects when maps are loaded up. Remove some functions that are only used by the editor into the editor. Move update_position from object.c to map.c as it is better placed in map.c. Modify function to figure out light for a space. Make out_of_map a function that knows about map tiling. New function - get_map_from_coord which knows about map tiling and does coordinate and map translation. common/object.c: Have update_object take another parameter which tells update object what has changed about the object. This lets the function know if it should call update_position right away or if it can just mark the space as needing an update at a later time. move update_position to map.c. insert_ob_in_map: now takes another parameter that describes actions not to do. modified to know about map tiling and do appropriate translation. Does some object sorting so it should handle spell objects more efficiently. insert_ob_in_map_simple is now replaced by using appropriate flag to this changed version of insert_ob_in_map. Clean up remove_ob - seemed to have done things in a more complicated fashion that is no longer necessary. Modify check_walk_on to look at all objects on space, not those below the object - with changes to insert_ob_in_map, new object won't always be on top. common/porting.c: functions from ltostr.c, sqrt.c, as open_and_uncompress close_and_delete, make_path_to_file from map.c common/treasure.c: Modified to use updated insert_ob_in_map MSW 2001-07-13 | |||
Show difference between Revision 1.31 and 1.32 | |||
Revision 1.31 | mwedel | 2001/06/29 00:59:46 | +1 -2 |
common/object.c, common/player.c, include/object.h, server/skill_util.c: Remove the unused LINKED_SKILL code. common/Makefile.in: Use cproto to make prototypes - cextract fails for some reason and now seems unsupported. Cproto generates a bunch of warnings, but does do the job. common/arch.c,server/apply.c, server/main.c, server/monster.c: cleanup some compile warnings (unusued variables, returns without value doc/playbook/Makefile.in: Create proper dependencies for files. doc/playbook/treas2-extract: Add player_force to value to ignore. doc/spoiler-html/spoiler.html: rebuilt server/skill_util.c: Remove the unused LINKED_SKILL code. Prevent characters that have meditation skill from learning melee weapon skill. MSW 2001-06-28 | |||
Show difference between Revision 1.30 and 1.31 | |||
Revision 1.30 | jbontje | 2001/06/13 17:04:05 | +22 -1 |
bugfix - uninitialized script_... and script_str_... fields of new objects are now set to NULL by default, patch made by gros 2001-06-14 mids | |||
Show difference between Revision 1.29 and 1.30 | |||
Revision 1.29 | mwedel | 2001/06/04 01:41:02 | +3 -1 |
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.28 and 1.29 | |||
Revision 1.28 | mwedel | 2001/05/28 23:41:53 | +1 -7 |
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.27 and 1.28 | |||
Revision 1.27 | mwedel | 2001/05/12 18:55:24 | +39 -13 |
anim.c, map.c, object.c: various enhancements for memory debugging/leak detection. doc/programming_guide: some updates on comments and indentation style. MSW 2001-05-12 | |||
Show difference between Revision 1.26 and 1.27 | |||
Revision 1.26 | mwedel | 2001/05/09 01:58:12 | +18 -5 |
Various improvements to make finding memory leaks easier. common/anim.c: Add free_all_anim function common/arch.c: Modify free_all_arch to free more data common/init.c: If running under MEMORY_DEBUG, don't pre-allocate objects. common/map.c: Add free_all_maps functiion. common/object.c: Modify object allocations if using MEMORY_DEBUG to only malloc one object at a time, and not pre-allocate objects. common/readable.c: Fix memory leak. common/shstr.c: Include autoconf.h so it can pull in dmalloc.h file. include/config.h: Remove notes of what was removed a long time ago. Add MEMORY_DEBUG option. include/libproto.h, include/sockproto.h, include/sproto.h: automatic rebuild server/c_misc.c: Fix 'malloc info command so it reports right memory total for maps. Add command_style_map_info which sums up memory used by style maps. server/commands.c: Add style_info wiz command which dumps memory usage for style maps. server/init.c: Have sighup handler call cleanup function. server/main.c: Fix clean_tmp_files which could result in crash if one of the maps in memory has 0 reset time. Modify cleanup function to free more data. server/player.c: op_on_battleground: Fix compile warning about unuused variable. socket/init.c: Change name of free_all_ericserver to free_all_newserver, have it free all face data. MSW 2001-05-08 | |||
Show difference between Revision 1.25 and 1.26 | |||
Revision 1.25 | mwedel | 2001/05/04 22:30:02 | +3 -2 |
Further refinement to not send unnecessary object updates to client, but still send necessary ones. MSW 2001-05-04 | |||
Show difference between Revision 1.24 and 1.25 | |||
Revision 1.24 | mwedel | 2001/04/30 01:34:28 | +14 -1 |
common/object.c: Add clear_owner function. include/libproto.h: rebuild. server/player.c: Modify op_on_battleground to look for battleground anyplace on space. Temp for for wall of thorns on space - as long as maps don't try to abuse the use of battlegrounds, should be OK. server/time.c: Add clear_owner call to stop_arrow. Fixes problem of thrown objects not getting saved. MSW 2001-04-28 | |||
Show difference between Revision 1.23 and 1.24 | |||
Revision 1.23 | mwedel | 2001/04/29 22:36:35 | +4 -9 |
Instead of re-sending entire space when object face changes and it is not a normally animated object (ie, button), just send an update face command. MSW 2001-04-29 | |||
Show difference between Revision 1.22 and 1.23 | |||
Revision 1.22 | mwedel | 2001/04/28 00:54:32 | +13 -23 |
common/object.c: Have update_object map the look window for redraw if the object is not something the client normally animates (like a lever). MSW 2001-04-27 | |||
Show difference between Revision 1.21 and 1.22 | |||
Revision 1.21 | mardahl | 2001/04/07 01:04:24 | +26 -1 |
This hack prevents burnouts and firetrails from stacking themselves many deep. I've noted a huge reduction in the number of objects to be processed from this mod alone, in situatons where a lot of comets are flying. PeterM | |||
Show difference between Revision 1.20 and 1.21 | |||
Revision 1.20 | michtoen | 2001/04/06 14:07:43 | +3 -3 |
win32: change // to /* */ | |||
Show difference between Revision 1.19 and 1.20 | |||
Revision 1.19 | michtoen | 2001/04/05 19:44:50 | +4 -3 |
*** empty log message *** | |||
Show difference between Revision 1.18 and 1.19 | |||
Revision 1.18 | mwedel | 2001/03/29 01:46:49 | +3 -3 |
configure, configure.in, include/autoconf.h, includes.h: add check for time.h and include it if we find it. socket/item.c: esrv_move_object - have it check to see if the object is already on the ground before we try to re-drop it. Likewise, check to see if it is already in players inventory before we try to pick it up. common/object.c: Don't send face updates to the client or make the space as needing to be redrawn. Client now deals with animation of the look window on its own. MSW 2001/03/28 | |||
Show difference between Revision 1.17 and 1.18 | |||
Revision 1.17 | mwedel | 2001/03/23 14:23:01 | +4 -1 |
common/object.c: have update_position just update the flag that the server needs to send the look window to the client and don't send the item at this point, as sending the look will do that. server/main.c: process_players1: Remove call to draw (which updates the client map) - the handle newclient in socket/loop.c already does this and there is no reason to send multiple instances of the same map. MSW 2001/03/23 | |||
Show difference between Revision 1.16 and 1.17 | |||
Revision 1.16 | mwedel | 2001/03/21 01:48:12 | +2 -2 |
common/object.c: Modify find_free_spot to call arch_out_of_map so that it properly deals with multipart objects. server/main.c: Fix enter_map so that we first use the golem (and not player) when calling find_free_spot. Also, modify code so that it properly updates coordinates of the multipart golem. MSW 2001/03/20 | |||
Show difference between Revision 1.15 and 1.16 | |||
Revision 1.15 | mwedel | 2001/03/20 23:28:14 | +2 -2 |
common/object.c: Modify update_position so that we don't show invisible players to other players. MSW 2001/03/20 | |||
Show difference between Revision 1.14 and 1.15 | |||
Revision 1.14 | cvs | 2001/02/01 00:18:31 | +5 -5 |
common/object.c: Fix that that spells cast on spaces with no floors get set properly after the spell expires. MSW 2001-01-31 | |||
Show difference between Revision 1.13 and 1.14 | |||
Revision 1.13 | cvs | 2001/01/23 23:01:36 | +8 -2 |
MSW 2001/01/23: Various cleanups/fixes as detected by purify: common/anim.c: animation[0] was given a null pointer as the name, but bsearch/or comparison function will try to de-reference it. Give it a unique name. common/loader.l: msgbuf was being used initialized in the main loading function. loader.c also regenerated. common/object.c: find_free functions were not checking to see if the spaces they were examining were out of the map. Added checks to do so. server/apply.c: buf was being used initialized in the function. socket/init.c: input buffer needs to be initialized as we do a strncasecmp against the buffer which may not have any data in it. | |||
Show difference between Revision 1.12 and 1.13 | |||
Revision 1.12 | cvs | 2001/01/15 16:33:32 | +2 -2 |
MSW 2000/01/15: Various fixes for friendly object code: common/button.c: Add missing call to remove_friendly_object common/friend.c: Pretty much completely re-written. add_friendly_object now checks to make sure the object being added isn't already on the list, remove_friendly_object will remove objects whose tags don't match, and added clean_friendly_list. common/object.c: No reason to use the function pointer to remove_friendly_object since that function is in the lib. common/time.c: Make DEBUG_TIME always on (no longer compile time option). other areas use the global var pticks, so if it was turned off, compile would break anyways. common/treasuer.c: No longer print debug messages on artifacts created. Cluttered log file making it hard to see more important errors. include/config.h: Remove DEBUG_TIME define. include/libproto.h: Rebuilt for clean_friendly_list function. server/main.c: rewrote do_specials to do things based on pticks variable. This allows various specials to be spread out across multiple ticks easier. Also, added clean_friendly_function to part of what this does. server/skills.c: add missing call to remove_friendly_object. Also, removed from #if 0 .. #else .. #endif code. End of MSW 2000/01/15 checkin. | |||
Show difference between Revision 1.11 and 1.12 | |||
Revision 1.11 | cvs | 2000/12/03 18:40:03 | +5 -6 |
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.10 and 1.11 | |||
Revision 1.10 | cvs | 2000/11/08 01:19:37 | +63 -30 |
MSW 2000-11-07 common/item.c: query_base_name was not return plural version of items with 'of' in name. Also, much of the function was not using safe_strcat, which could result in buffer overlow problems. common/object.c: Change update_position so that we always generate 3 images per space. This fixes players standing on top of dragon transports, but generally works for things like monsters standing on objects. insert_ob_in_map: change 'return' statement to 'return NULL'. Also remove unused map pointer. decrease_ob_nr: Fix bug for client updates when player drops item that is then consume. It was using op->above after object was removed to find the player. Store above pointer before we remove the object. socket/item.c: Don't terminate pointer as returned by query_base_name - instead, terminator buffer after we copy it. For simple object, query_base_name may directly return a pointer to the objects name which is only long enough to hold the name itself. socket/lowlevel.c: Abort if we are trying to send the client a packet longer than supported by the protocol. Since that buffer is static, overflowing it will just create memory corruption - easier to stop then than try and debug it later. End of MSW checkin 2000-11-7 | |||
Show difference between Revision 1.9 and 1.10 | |||
Revision 1.9 | jec | 2000/11/06 17:06:47 | +75 -70 |
* stop_item() / attack fix patch 2000-11-06 | |||
Show difference between Revision 1.8 and 1.9 | |||
Revision 1.8 | cvs | 2000/06/26 22:34:34 | +14 -1 |
Patch by Jeffry Hantin which fixes glow objects in map. insert_ob_in_map_simple now will call the appropriate light updating code. Applied by MSW 6/26/2000 | |||
Show difference between Revision 1.7 and 1.8 | |||
Revision 1.7 | jec | 2000/06/08 11:08:41 | +9 -1 |
common/button.c: do_mood_floor(): Bugfixes: Only players can have pets. Call add_friendly_object() for friendly monsters. server/spell_effect.c and server/spell_util.c: Several functions: Only add a pet if there really is a pet's owner, and it's a player. server/spell_effect.c: cast_charm() and cast_charm_undead(): Bugfixes: Only players can cast these spells. This fixes server crash if a monster casted a charm spell, and the charmed pet was killed. Call add_friendly_object for friendly monsters. common/friend.c: remove_friendly_object(): Use llevError for error messages. common/living.c: fix_player(); server/gods.c: tailor_god_spell(); server/spell_effect.c: summon_avatar() and animate_weapon(): Bugfix: Set a string to NULL after calling free_string(). This fixes a nasty bug that caused the string's reference count drop below 0, which resulted in corruption of malloc()'s internal data structures (and possibly server crashes). server/time.c: move_creator(): Bugfix: Call free_string() to free old values of op->name and op->title before overwriting them with new values. common/object.c: insert_ob_in_map_simple() and insert_ob_in_map(): Check that we don't insert freed objects. server/attack.c: hit_player_attacktype() and hit_player(): Bugfix: Check that find_god() really found a god, and that 'god->slaying' is not NULL. Fixes crash if a monster casted turn undead and actually hit something. server/attack.c: hit_player(): Check that a pet's owner is a player. Prevents server crashes if a monster has a pet monster due to a bug somewhere. Use llevError for error message. server/time.c: move_arrow(): Use llevDebug level for "Arrow had no map" message. server/c_object.c, server/spell_effect.c, server/spell_util.c: Bugfixes: Added some missing checks for destroyed objects. Use was_destroyed() or return value of insert_ob_in_map() to check for destroyed objects, not FLAG_FREED or FLAG_REMOVED. Don't use op->count of destroyed objects. server/shop.c: get_payment2(): Type of tag is 'tag_t', not 'long'. server/spell_effect.c: animate_bomb(): Fix environment checks. server/spell_util.c: fire_bolt(): Bugfix: Set level of bolt. server/spell_util.c: explosion(): Bugfix: Set FLAG_NO_APPLY before moving the exploding object to the top. server/spell_util.c: put_a_monster(): First create the monster completely, then just insert its head. server/time.c: generate_monster(): Bugfix: Don't free generators that are used up in this function. process_object() already does this. This fixes steambolt (which is a generator but must not used up here - generate_monster() wasn't looking at FLAG_IS_USED_UP) and all generators which should really be used up (because process_object() didn't expect generate_monster() to destroy the object). | |||
Show difference between Revision 1.6 and 1.7 | |||
Revision 1.6 | cvs | 2000/05/27 01:02:58 | +6 -5 |
include/define.h: Add MIN_ACTIVE_SPEED value to determine what threshold something will be put on the active list or not instead of using varying values throughout the source code. common/item.c, common/object.c, server/monster.c, server/pets.c, server/spell_effect.c: Updated to use the MIN_ACTIVE_SPEED instead of hardcoded values. MSW 5/26/2000 | |||
Show difference between Revision 1.5 and 1.6 | |||
Revision 1.5 | jec | 2000/05/26 04:50:45 | +75 -36 |
* apply() cleanup patch 26/5/2000 | |||
Show difference between Revision 1.4 and 1.5 | |||
Revision 1.4 | jec | 2000/05/22 08:06:15 | +60 -22 |
common/object.c: Splitted set_owner() into set_owner_simple() and set_owner. copy_owner(): New function. server/spell_util.c: explode_object(): Use copy_owner() instead of setting skill and experience objects manually. Bugfix: Don't use op->owner directly (fixed by using the caster in call to SP_level_dam_adjust(), not the owner, which was wrong anyway). server/spell_util.c: fire_arch_from_position(): Use copy_owner() instead of set_owner() if 'op' isn't the real owner but only a spell object owned by somebody else. server/spell_util.c: move_swarm_spell(): Use the swarm spell object as the owner in call to fire_arch_from_position(), which now handles this case correctly. server/spell_util.c: fire_swarm(): Call tailor_god_spell(). server/gods.c: determine_god(): op->type==SWARM_SPELL is a spell. server/gods.c: tailor_god_spell(): op->type==SWARM_SPELL is a spell. Always abort function if we couldn't find a god. Always add god's attacktype if the spellop's attacktype has AT_GODPOWER. | |||
Show difference between Revision 1.3 and 1.4 | |||
Revision 1.3 | cvs | 2000/03/16 01:06:57 | +4 -1 |
Added comment about find_free_space only checking head of object. - msw 3/15/2000 | |||
Show difference between Revision 1.2 and 1.3 | |||
Revision 1.2 | cvs | 1999/07/13 01:02:42 | +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:03 | None |
Initial revision | |||
First version | |||
Revision 1.1.1.1 | uid200 | 1999/04/02 13:10:03 | +0 -0 |
First CVS revsion: crossfire-0.95.3 | |||
Show difference between Revision 1.1 and 1.1.1.1 |