summaryrefslogtreecommitdiff
path: root/src/map/chrif.c
AgeCommit message (Collapse)AuthorFilesLines
2008-01-20Expanded a mapserver's debug message in its interserver parsing function.ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12094 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-01-19Added back periodic user count updates that got replaced in r11703, but are ↵ultramage1-0/+3
neccessary as the current method doesn't work correctly (bugreport:688) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12090 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-31* Added code to reject double logins in clif_parse_WantToConnection and ↵FlavioJS1-6/+2
added debug messages to detect possible double logins that escaped. * Isolated accounts that are waiting for the quit ack. The rest of the game logic no longer has access to them though the id2sd/charid2sd dbs. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11998 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-17* Added flag.server to indicate interserver socketsultramage1-2/+2
- replaces the previous way (setting 'client_addr' to 0) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11930 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-12* Some preparations for the guild script updateultramage1-4/+6
- cleaned up npc event execution code - cleaned up guild data loading/saving code; to be improved later - removed dummy 'account name' expulsion list management code - removed columns 'rsv1' and 'rsv2' from guild member data - removed columns 'rsv1' 'rsv2' 'rsv3' and 'acc' from guild expulsion data - added upgrade_svn11895.sql for SQL git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11895 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-07- removed the timer heap correction code when the timers overflow since ↵skotlex1-62/+49
Flavio points out that it is not needed. - Modified a bit the changesex code so you get saved and quit before changing your sex rather than afterwards. - Cleaned up #changesex - Signum Crucis now works on bosses. - party_recv_data will not set the sd pointer for not-yet-authed characters. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11867 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-22- Changed the status_change structure to use dynamic rather than static ↵skotlex1-14/+14
memory to hold the individual status changes, this should have a noticeable impact on the server's memory consumption. - Had to add a few 'ugly' flags to status_change since now you can't track SC related information while said SC is not active (happens only for Storm Gust, Joint Beat and Magic Power). - Since I am unable to fully test, watch out for any bugs~ git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11786 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-17Removed battle_config.error_log as console_silent already handles thisultramage1-4/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11751 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-09* Re-worked the login-char-map packet spam mechanismultramage1-46/+64
- mapserver no longer sends entire user list to charserver every 10 seconds; similar change done to the char-login connection - user count updates are only sent when the value actually changes instead of servers polling each other every few seconds - the servers now prevent interserver connection timeout explicitly by sending ping/ack packet pairs instead of relying on the usercount polling to do so; keepalive is sent every 'stall_time'-2 seconds - removed the @refreshonline command as refresh happens automatically every 5 seconds git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11703 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-08* Changed EXIT_SUCCESS back to 0 in console.c to avoid an unnecessary include.FlavioJS1-6/+6
* Fixed gm_account_db not being deallocated in login-converter.c. * Refactoring names and documentation in db.h/db.c: - changed 'struct dbt' to 'struct DBMap' and 'DB' to 'DBMap*' - changed 'struct db' to 'struct DBMap_impl' and 'DB_impl' to 'DBMap_impl*' - changed COUNT to DB_COUNTSTAT and made it's existence not depend on DB_ENABLE_STATS - removed some @see links and corrected small typos in the documentation git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11698 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-03Tried to make sense out of timer.c ... and failedultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11647 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-17* Merged do_sendrecv() and do_parse() into do_sockets()ultramage1-0/+1
* Fixed subnet check message displaying incorrect ip addresses * client_addr will now be properly set to 0 for server connections * Removed socket code that attempts to cope with code bugs at runtime * Removed outdated copyright and version number from startup logo git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11503 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-17Using predefined constants as parameters to the exit() function.ultramage1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11501 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-28Removed some redundant code from the sql charserver.ultramage1-47/+33
Fixed a sql-charserver @block crash (missing Sql_NextRow() call). Probably fixed 'random junk' being displayed in @changesex reply text. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11324 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-25* Disabled tick cache (to enable it: define TICK_CACHE to the number of ↵FlavioJS1-1/+1
calls that should be cached). * Added a charid2sd database for fast charid searches. * Reworked the nick cache to only contain offline characters. Note: The tick cache was causing _some_ of the desync problems in eA. Gameplay should be much smother, but desync problems still exist. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11290 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-15Getting some (mostly atcommand) code cleaning out of the way...ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11222 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-19* Cleaned/clarified some #include relationships between headersultramage1-2/+6
* Changed clif_sitting() to use 'bl' instead of 'sd' (for non-player objects) * Removed way messed-up script function 'unitdeadsit' * Tagged 'FIXME' lines written by myself git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11040 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-09The new functions now clear junk from the output buffer, this simplifies the ↵ultramage1-1/+0
code a bit. Added a TODO for one emblem loading problem/crash. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10969 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-08- Changed the structure of the homunculus_db file so that the homunculus and ↵skotlex1-1/+1
its evolved version share the same line. Also added the evolution bonuses to it. - Updated the @homstats command to show evolution bonuses - Cleaned up the homunculus db structure. - Implemented the evolution stat growth bonuses. - Some small cleanups in the mercenary.c file - Corrected initial intimacy of a newly created homunculus (should be 21/1000) - Incremented the size of mob.c:summon.class_[] since mob_pouch has almost 350 entries. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10965 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-08* Cleaned up junk left in the code by the mapcache/mapindex updateultramage1-10/+10
- Added mapindex_getmapname(_ext) to help with ".gat" adding/removing - Moved related processing to the interface (prevents duplicity) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10963 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-07-01Cleaned up some parts of the code.ultramage1-263/+148
Removed obsolete script function 'hasitems'. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10838 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-06-01Some typo fixing / cleaningultramage1-6/+6
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10658 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-28* RFIFOREST returns 0 when the session is eof (input data is implicitly ↵FlavioJS1-2/+1
discarted). * Reworked the player fame update: - would crash if an invalid pos was received - the wrong player could be updated on certain conditions git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10640 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-25Corrected some weird fgets() statements, plus reformatted themultramage1-1/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10616 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-23- Added new flag to skill_castnodex.txt, to allow per-skill tweaking of cast ↵ultramage1-1/+1
time and delay reducibility by item scripts (cards and such) - Fixed Martyr's Reckoning never triggering for gms with all skills - Added MO_TRIPLEATTACK and RG_SNATCHER to @skillall's skill filter - Made gm_skill_unconditional bypass skill blocking (guild timer, etc) - Reverted the weird delay_dependon_agi thing (r8923, r9055, r9059) - Changed a few memsets to strncpy (reading past buffer is a bad idea) - Sped up some memset operations (multiples of 4 are faster) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10613 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-21- Removed the TURBO socket mechanism - it was in fact just using a variable ↵ultramage1-46/+29
to cache a few arithmetic operations (premature optimization) - Since the fifohead mess is gone, fixed leftover bad code structuring git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10599 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-19Reformatting @_@ultramage1-67/+48
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10581 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-09* Added Buuyo-Tama's shortlist for send/eof sockets (defined out for now). FlavioJS1-9/+9
* Replaced toupper/tolower in ladmin by TOUPPER/TOLOWER defines. Shortlist: It's a list of sockets that have data to send and/or are ready for eof processing. It aims to reduce the amount of time spent on do_sendrecv, where it was spending ~13.5% of execution time on a server with 1k users at WoE. thanks to Buuyo-tama for the profile info and code git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10506 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-22- Removed the include of features.h from the console.c plugin. It is ↵skotlex1-3/+3
apparently not needed (and it was preventing compilation on FreeBSD) - Fixed bug which totally broke item group bonuses. - Added warnings when setting a pvp/gvg flag removes the other flags on the same map (gvg and pvp can't coexist on the same map) - Optimized the unequip loop when changing sex. - Removed the check that prevented you from casting soul-collect when you already have 5 spirits. - Corrected Magic Rod so it doesn't displays any skill-use animation until it triggers. - Debuff on logout&2 is again set to default, instead of removing food bonuses now it removes Maximize Power, Maximum Overthrust and Steel Body. - Corrected Steel Body's icon (it actually belongs to AutoBerserk) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10317 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-06I'm still here!DracoRPG1-1/+1
Rewrote fame ranking lists- changed MAP_NAME_LENGTH to 12, now there's MAP_NAME_LENGTH_EXT at 16 for uses where there is / may be the .gat extension, code adjusted accordingly - moved map_normalize_name to mapindex_normalize_name so that everything handling map names uses the same extension-removing function - greatly enhanced the map cache generator, complete documentation on the tool and the map cache format can be found in doc/ - the map cache format changed a bit as a consequence, but of course a new valid one is included (contains latest Nameless Island maps) - fixed a duplicate entry in map index git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10167 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-05typos: recieve -> receiveultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10163 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-05* Made a crazy attempt to at least partially synchronize login&char codeultramage1-93/+54
* Major edit to the way the servers handle ip addresses, making them obey the "host byte order inside, network byte order outside" rule - hopefully covered all entry- and exit-points for IP address data - discovered several places where Gravity's client breaks the convention, will need to come up with a suitable countermeasure for that - other than that, the code should be portable, except for printing and ipban mask testing (those still assume a specific byte order) - tested both txt and sql in all usual situations; tested single- and multi-server setups, all seems to work (but watch out for hidden bugs!) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10162 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-02* Some source code cleaningultramage1-6/+6
- Fixed the badly worded messages during mapserver startup - Cleaned up socket config reading - Split resolve_hostbyname() into 2 separate functions for clarity - Moved the probably obsolete LOWER/UPPER macros to db.c (TODO: remove) - Moved the badly placed compare_item() function to storage.c (see r779) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10119 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-03-23- Made waiting_disconnect on the char server be an int to hold the timer ID ↵skotlex1-0/+11
of the timeout timer. It is now deleted when a player is successfully set offline/online. - Corrected @unjail having the GM level check backwards. - chrif_authok will now reject to store the newly received status data when the player it was received from is still online, should prevent losing data in certain situations. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10060 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-03-19- Rewrote the jail logic to always use a status change. This means that the ↵skotlex1-2/+3
character's save point is not changed when jailed, and the char is always warped back to the point where it was before being jailed on unjail. - Made pc_setpos fail if you are jailed, effectively blocking you from being moved out of the jail map for the duration of jail. - Modified @adjcmdlvl so you can't set a command to require higher level than yourself, and so you can't edit the level of a command which is higher than your own. - Corrected attack_attr_none setting disabling elemental resist cards. - Added missing cap check of 100% to drop rate configs for heal/use/adddrop (cards)/treasures. - Corrected Autoblitz yelling the skill name if the attack splashed. - Corrected Dispell removing Jailed status. - Corrected being able to revive with 0 hp. - Modified the "Restart" code so that it makes you stand on spot when pc_setpos fails to move you back to your originating location. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10028 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-03-18- Removed the old 'mapserver charsave' mechanismultramage1-24/+2
- Fixed some wrong sql login logic - Fixed some compiler warnings, cleaned up mapserver sql-related vars git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10027 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-03-09- Added info on packet 0x86 (simple move packet). Not usable until a clear ↵FlavioJS1-1/+3
separation between entering sight/leaving sight/walking in sight is done. - Propagating const char* from the script engine. - ".gat" is appended to the map name before sending the changemapserver packet to the client. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9979 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-03-04- Removed delete_session from socket.h since it shouldn't be used by them.skotlex1-1/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9955 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-02-28- Made it possible to modify the server packet version from the Makefile.skotlex1-2/+30
- Merged packet 2b22 (from my server) to handle quick fame updates whenever someone's fame in the ranking changes, but no position swaps take place (prevents having to resend the whole fame list in such events, you lazy Draco <.<) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9936 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-02-27- Removed an auth procedure check that is no longer needed (fixes ↵skotlex1-4/+0
double-login checks not working right) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9927 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-02-26- indent cleanupsskotlex1-3/+1
- Fixed Self Destruction causing double-free'd errors and triggering twice when a self-destruct cast makes other objects trigger self destruct as well git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9924 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-01-28Some misc cleanups (typos, formatting, forgotten changelog entry etc)ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9733 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-01-24- Cleaned up some more the Joint Beat implementation, so the status don't ↵skotlex1-1/+1
take effect until the attack connects. - Some minor cleanups. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9704 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-01-07Undid the memset->malloc_set replacementultramage1-4/+4
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9626 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-12-23- Moved "#include <limits.h>" to cbasetypes.h to ensure it's included before ↵FlavioJS1-1/+1
checking if UINT_MAX has been defined. - Minor changes in pc_readdb related to max_level being unsigned. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9561 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-12-05- Massive EOL normalization & 'svn:eol-style native' flag setting for all ↵FlavioJS1-1636/+1636
txt/conf/h/c files. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9410 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-12-04- Changed some pc_authfails to clif_authfail_fd since pc_authfail prints ↵skotlex1-2/+2
errors when invoked after a char is auth'ed. - Added a static +100 Hp to ninjas and gunslingers since it's required for the best approximated hp growth algorythm. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9404 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-12-03- Removed sd->sex since it's redundant (we can always use sd->status.sex)skotlex1-7/+2
- If somehow a player logs out and it's saved with 0 hp, on login his state will be set to dead as well so he can respawn (otherwise that leads to a stuck char) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9398 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-12-01- Fixed txt-converter compilation. skotlex1-5/+5
- Added my_global.h include to login converter - Removed sd->char_id since we can use sd->status.char_id instead. - Small speedup in STRECOVERY, and made it not unlock a mob's target. - Fixed GS_GROUNDDRIFT consuming ammo when it's time expires (so it was consuming 2 grenades instead of one). Also added a "explosion effect" when their time runs out. - gvg_dungeon mapflag won't set pvp related mapflags anymore, pc_dead will force pvp ranking gain/loss on gvg_dungeon maps now. - Now when coming out of hiding land-effects will trigger on the character. - Made the pc_setpos message when being placed on an unwalkable tile tell you which player triggered it. - Fixed land effects not taking effect inmediately on map-load when the invincible timer is disabled. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9374 54d463be-8e91-2dee-dedb-b68131a5f0ec
2006-11-29- Some cleaning on the homunc speed calculating code, so that it correctly ↵skotlex1-5/+5
uses the default walk speed if the player has no speed yet. - Some speed up code when loading status changes (use a pointer instead of memcpy'ing all the time) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9359 54d463be-8e91-2dee-dedb-b68131a5f0ec