summaryrefslogtreecommitdiff
path: root/src/map/map.c
AgeCommit message (Collapse)AuthorFilesLines
2012-04-29- Removed leftover TXT configs, follow-up to r15503.brianluau1-3/+3
- Edited more ***_config_read() functions to show a warning if "Unknown setting" is found. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16009 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-29A minor memory improvement, and some curly brace love.shennetsind1-9/+12
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16008 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-29Yet another performance improvement: Shut Down processing is now about to 7 ↵shennetsind1-9/+11
times faster. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16006 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-29reasonably-sized performance improvement: @reloadscript is about to 3 times ↵shennetsind1-1/+1
faster. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16004 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-25* Code consistency updates. No functional changes. Credits to Lighta.xazax-hun1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15974 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-22Fixed bugreport:5604 Firewalk and Electric Walk now function properly.shennetsind1-5/+19
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15917 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-20Initial support for Genetic, Sorcerer and Elemental Summons. Special Thanks ↵shennetsind1-1/+10
to 3CeAM for the base. Notice this revision onwards requires you to update your char sql table and add the elemental sql table (check sql-files/upgrade_svn15885_log.sql) If you step by any bugs, let us know at http://rathena.org/board/tracker/ Thank you very much. ARRIBA ARRIBA. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15885 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-09- Spring cleaning of various source filesepoque111-1/+1
- Removed unused src/map/config/Skills/Mage_Classes.h file git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15837 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-23Fixed bugreport:3574 Ice Walls finally are able to stop mobs chasing caster, ↵shennetsind1-3/+3
and they now act as walls meaning mobs will not turn around to attack you unless they were already chasing you git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15777 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-23Fixed bugreport:1017 a item dropping over a ice-wall-occupied cell is no ↵shennetsind1-3/+5
longer lost/deleted. Dev Note: the thing I added to sign icewalls may be suitable for bugreport:3574 as well git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15772 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-22Rehashed Item_delay.txt (bugreport:5487)shennetsind1-0/+3
- Before you could only have MAX_ITEMDELAYS (10) items with delays. Now: you can have up to MAX_ITEMDELAYS (10) concurrent delays. and of course you can always increase MAX_ITEMDELAYS in src/map/itemdb.h as much as you may need. - Item delays are no longer lost on logout, they're persistent until server restarts. - When a item use is denied due to delay still up a message now tells the user why he can't use the item (before would leave the user wondering wtf was going on. it had no response) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15762 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-22Fixed bugreport:5356 Shadow Shaser's Shadow Form. Skill now redirects damage ↵shennetsind1-0/+17
properly and is removed upon either caster or target leaving skill range git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15755 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-22Fixed Mechanic Stealth Field to move accordingly and grant proper effectshennetsind1-0/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15754 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-22Fixed bugreport:5357 Neutral Barrier is now working accordingly.shennetsind1-6/+10
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15753 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-18Added Official Guild Aura Implementation bugreport:667shennetsind1-13/+24
Before: - Guild Aura would only trigger when guild master moved Now: - Guild Aura is triggered when master moves and/or when guild mate gets inside the area - Guild Aura range is no longer hardcoded, you may modify it from skill_unit_db Also: - Added new skill_unit_db target type 'guild' git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15707 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-14Fixed Nick DB code using uninitialized data (bugreport:5439).gepard19841-3/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15687 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-13Enhanced `DBMap` implementation to allow storing integer type data in ↵gepard19841-19/+37
addition to void pointers. - Added enum for data: `int`, `unsigned int` and `void*` - Replaced generic `void*` data with `DBData` struct to hold `int`, `unsigned int` or `void*` (member of `DBNode`) - Added `db_i2data`, `db_ui2data` and `db_ptr2data` functions to cast from `int`/`uint`/`void*` to `DBData` (used in `DBMap::put()`) - Added `db_data2i`, `db_data2ui` and `db_data2ptr` functions to get `int`/`uint`/`void*` from `DBData` - Enabled statistics for new functions in `db_stats` struct - `DBCreateData` functions (used in `DBMap::ensure()`) now return `DBData` instead of `void*` - `DBApply` functions (used in `DBMap::foreach()` and `DBMap::destroy()`) now take `DBData*` as a parameter instead of `void*` - `DBMatcher` functions (used in `DBMap::getall()`) now take `DBData` as a parameter instead of `void*` - `DBReleaser` functions now take `DBData` as parameter instead of `void*` - Default releasers release data if it is `void*` (`DB_DATA_PTR`) type - `DBIterator` functions: `first()`, `last()`, `next()` and `prev()` now return `DBData*` instead of `void*` - `DBIterator::remove()` now returns `int` (1 if node was found and removed, 0 otherwise) instead of `void*` and takes an extra `DBData*` parameter for the data of removed entry - `DBMap::get()` and `DBMap::ensure()` now return `DBData*` instead of `void*` - `DBMap::remove()` and `DBMap::put()` now return `int` (1 if node already existed, 0 otherwise) instead of `void*` and take an extra `DBData*` parameter for the data of removed entry - `DBMap::put()` now takes `DBData` as parameter instead of `void*` - `DBMap::getall()` now puts data into `DBData**` buffer instead of `void**` buffer - Updated macros: - (`i`/`ui`/`str`)`db_get` and (`i`/`ui`/`str`)`db_ensure` were wrapped with `db_data2ptr` to extract data from `DBData*` that is now returned by `DBMap::get()` - added (`i`/`ui`/`str`)`db_iget` and (`i`/`ui`/`str`)`db_uiget` that get `DBData` from `DBMap` and extract `int`/`unsigned int` from it (with `db_data2i`/`db_data2ui`) - `db_put`, `idb_put`, `uidb_put` and `strdb_put` data params were wrapped with `db_ptr2data` to match new signature of `DBMap::put()` (`DBData` instead of `void*`) - added (`i`/`ui`/`str`)`db_iput` and (`i`/`ui`/`str`)`db_uiput` that put `int`/`unsigned int` into `DBMap` (first wrapping it with `DBData`) - added `NULL` in place of extra parameter for removed data in `db_remove` macros - `dbi_first`, `dbi_last`, `dbi_next` and `dbi_prev` were wrapped with `db_data2ptr` to extract data from `DBData*` that is now returned by these `DBIterator` functions - Updated `DBMap` documentation, and fixed a dozen of typos in it. - Updated rest of rA code to reflect `DBMap` changes (mostly required signature changes of `DBCreateData` and `DBApply` functions). - Fixed a bug where `DBMap::put()` would return data of a deleted entry. - Removed some unnecessary pointer casts. - Increased `showmsg.c` static buffer size to fit entire DBMap stats report. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15682 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-03-09Code cleanup: replaced `DBIterator` function calls with macros where possible. gepard19841-5/+4
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15668 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-22Fixed Royal Guard's Banding skill & icon activation (bugreport:5210)xantara1-0/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15627 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-18Initial Support for Shura and a few adjustments here and there.shennetsind1-0/+67
- credits to 3ceam for the base. - should you step by any bugs let us know, http://rathena.org/board/tracker git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15606 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-17Initial support for Shadow Chaser and a few adjustments here and there.shennetsind1-0/+3
- credits to 3ceam for the base - should you step by any bugs let us know, http://rathena.org/board/tracker git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15589 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-16- Removed outdated version number handling (follow-up to r11503).gepard19841-5/+3
- Fixed mapcache compilation issues in Linux. - Added some missing `svn:ignore` properties. - Moved `BLOCK_SIZE` definition from header to source file. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15586 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-08* item_trade.txt is split into re and pre-re folder as per Kenpachi's request.xazax-hun1-1/+1
* skill_tree.txt is split into re and pre-re folder. In renewal version only level 5 spear mastery is required for spiral pierce. * Removed an unnecessary new line on a message. * Enabled mechanic summons in pre-re/mob_db.txt to avoid some startup error messages. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15546 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-31Added proper `mob_delete_timer` (dynamic mobs feature) cleanup on map-server ↵gepard19841-0/+2
shutdown (bugreport:2944). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15528 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-30- Removed more trailing tabs.brianluau1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15527 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-30- Removed trailing tabs, and fixed some spacing.brianluau1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15524 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-20Merged TXT removal branch back to trunk.gepard19841-15/+1
* TXT save engine is removed and no longer supported. * See also tid:53926, tid:57717. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15503 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-17Enabled Mersenne Twister MT19937 as random number generator instead of ↵gepard19841-7/+8
standard `rand()` function (follow-up to r14865, r14870). - It fixes issues caused by RAND_MAX being only 32k in Windows system (bugreport:1927, bugreport:86). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15483 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-04Re-designed /db/ folder structure as previously discussed.shennetsind1-0/+6
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15390 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-01Added new @/# command aliases pattern, all aliases can now be ↵shennetsind1-1/+0
modified/added/removed in the front-end within atcommand_conf (no longer hardcoded). The aliases pattern was defined in this topic: tid:56343 atcommand_conf file rewrite/update belongs to Jguy and BrianL git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15343 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-27* Merged changes up to eAthena 15050.eathenabot1-10/+33
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15287 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-18mob_read_sqlskilldb func [CalciumKid]calciumkid1-0/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15155 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-15BuildBot console report codeshennetsind1-0/+4
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15126 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-14Added support for item_db_re table renaming in inter_athena.confshennetsind1-0/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15114 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-09- Updated some URLs.brianluau1-3/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15037 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-09Battlegrounds bug fix, bugreport:4996shennetsind1-0/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15035 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-05Merging RREmu into rAthena -- quite a few stuff yet to be renamed, but we'll ↵shennetsind1-54/+102
get it sorted. Some of the stuff included in RREmu that is now part of rAthena: - RE Drop Rate Modifier - RE Experience Rate Modifier - RE Weapon MATK - RE Shield ASPD job-specific penalty - RE Cast Time - Renewal-specific item DEF - 3.1 classes. - All-New Mounts - Official Magical Reflection - And other perks, such as fully-functional @mapflag also merged eAthena 15006 into rAthena. For Bugs, Comments and Suggestions: http://rathena.org/board/tracker/ git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15009 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-09-08* Fix C++ compilation issues.flaviojs1-4/+4
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14955 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-08-10- Commiting a bunch of cleanups piled up from the past few weeks/months/years.Skotlex1-1/+1
- Updated unitwarp so that an id of "0" causes the script's rid to be warped. - Updated the Brasilis ontouchNPC warp command to use unitwarp instead. - Signum Crucis's duration is now specified in the skill_cast_db file - Updated @warp/@jump commands so that when an invalid tile is specified, a nearby cell is chosen (rather than using a map-wide random value) - The if(req.weapon) code was broken, since req.weapon is never "0" for a skill. Updated the code so that the requirement of '99' (any weapon) is stored as 0, in order to make the checks effective. - Cleaned up the code for script command warpparty - Fixed the define itemdb_canrefine() - Cleaned up some the status_damage() function - Fixed map_random_dir(), which at times would pick cells that didn't preserve the required distance. - Some aesthetic code cleanups. - Fixed some possible crashes for skills where the code assumes the caster is a player. - Fixed a bunch of idiotic code-snippets that should have embarrassed whoever was responsible for them. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14929 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-07-06* Merged decode_zip/encode_zip from eapp's grfio to replace our direct use ↵flaviojs1-1/+1
of zlib's uncompress/compress. * Fixed strict-aliasing warning in mapcache's GetFloat. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14888 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-07-02* Random updates to instance system.ai4rei1-3/+1
- Introduced a constant for instance name length. - Corrected comments related to instance packets 0x2cb (ZC_MEMORIALDUNGEON_SUBSCRIPTION_INFO) and 0x2ce (ZC_MEMORIALDUNGEON_NOTIFY). - Moved instance finalization out of map.c into instance.c git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14878 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-06-30Replaced custom type 'intptr' with standard 'intptr_t'.ultramage1-3/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14873 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-06-16* Merges from charmerge:flaviojs1-1/+28
- Added DBMap::exists. (r14090) - Added sv_parse_next, a stepped version of sv_parse (delim-separated parser). (r14100 r14104) - Added missing fd check to do_close. (r14145) - Normalized, refactored and restructured some code (in preparation for shutdown/reconnect code). (r14145 r14150) - Changed the char select request code to allow the char-server to reject it. (player in map-server trying to go to char select) (r14150) - Added shutdown support to the servers. (incomplete) (r14152) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14851 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-05-14* Moved bitfield 'boss' inside 'spawn_data' and 'mob_data' into the ↵ai4rei1-1/+1
respective state struct (from r13813, follow up to r14795). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14818 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-05-14* Random accumulated bits and pieces.ai4rei1-2/+24
- Added checks/warnings to pc_paycash and pc_getcash (follow up to r12264). - Added missing packet_db.txt and packet length table entries for packet 0x0859 (follow up to r14799). - Added set of map_id2xx wrappers for map_id2bl for most common map objects, which return NULL when the bl-type is not the expected one (also updated map_id2nd to behave this way). - Fixed missing ',' in mob_skill_db.txt example (follow up to r14270). - Updated mapcache with recent maps (up to que_lhz). - Functions 'msg_txt' and 'job_name' now return a const pointer. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14813 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-05-01* Removed functions 'decode_zip' (ancient) and 'encode_zip' (from r824) from ↵ai4rei1-1/+1
grfio. These were outdated copies of zlib's 'uncompress' and 'compress' respectively (related r1530 and r5152). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14808 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-04-09* Moved duel code into a separate file.ai4rei1-0/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14785 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-03-19Removed leftovers of old charcommand config (follow-up to r13403).Gepard1-3/+0
Added check to ensure character `rename` status will be saved if changed. Fixed Beast Strafing (HT_POWER) damage formula and SP requirement provided by Playtester (bugreport:4675, since r4392). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14748 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-02-14* Fixed drop list of map flag 'pvp_nightmaredrop' not getting cleared upon ↵ai4rei1-0/+1
@reloadscript (bugreport:4282, follow up to r14668). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14706 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-01-19* Fixed solo dance/star gladiator warm AoE no longer following the owner and ↵ai4rei1-0/+1
cloaking wall rules no longer working (bugreport:4720, since r14671). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14677 54d463be-8e91-2dee-dedb-b68131a5f0ec