Age | Commit message (Collapse) | Author | Files | Lines |
|
Added some forgotten <stdio.h> and "common/conf.h" includes to .c files,
that were previously masked by the above.
Signed-off-by: Haru <haru@dotalux.com>
|
|
Signed-off-by: Haru <haru@dotalux.com>
|
|
Follow up b77735473db348a65b749a79549852713f142dc1
|
|
WFIFO/RFIFO.
Change packet database enums to defines in mmo.h
|
|
Signed-off-by: Haru <haru@dotalux.com>
|
|
- sockt->lan_subnet was renamed to sockt->lan_subnets.
- sockt->trusted_ip was renamed to sockt->trusted_ips.
- sockt->allowed_ip was renamed to sockt->allowed_ips.
- Convenience macros for checking IP ranges and subnets are provided
(SUBNET_MATCH, APPLY_MASK).
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Changed the hplugin_data_store's array into a VECTOR.
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Several explicit casts are removed, to have a slightly better
type-checking at compile time.
- A destructor function is provided, to remove code duplication.
Signed-off-by: Haru <haru@dotalux.com>
|
|
Improved compatibility, portability and standards conformance.
- Since it is not possible to portably and reliably re-use the core's
symbols in plugins, symbols are no longer exported unless explicitly
required, in the UNIX builds. This mimics the Windows behavior and
adds HPM compatibility to OSes such as FreeBSD. Credits to Andrei Karas
for making this possible.
- For convenience, it is no longer necessary to call GET_SYMBOL, since
the plugin will automatically import all the available symbols when
it's loaded, depending on the included headers.
- Plugins are now supposed to include the "common/hercules.h" header
before including anything else. Incluing common/HPMi.h,
common/cbasetypes.h or conf/core.h is no longer necessary, as those
are guaranteed to be automatically included by hercules.h.
- HPM API version bumped to 1.1.
Signed-off-by: Haru <haru@dotalux.com>
|
|
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Replaced some macro calls with the proper interface syntax
- Removed useless macros and workarounds
API changes summary:
- WFIFOSET() can now be safely used both inside and outside socket.c
- RFIFOSKIP() can now be safely used both inside and outside socket.c
- do_close() is now sockt->close()
- flush_fifo() is now sockt->flush()
- flush_fifos() is now sockt->flush_fifos()
- getips() is now sockt->getips()
- host2ip() is now sockt->host2ip()
- ip2str() is now sockt->ip2str()
- ntows() is now sockt->ntows()
- make_connection() is now sockt->make_connection()
- make_listen_bind() is now sockt->make_listen_bind()
- realloc_fifo() is now sockt->realloc_fifo()
- realloc_writefifo() is now sockt->realloc_writefifo()
- session_isActive() is now sockt->session_is_active()
- session_isValid() is now sockt->session_is_valid()
- set_defaultparse() is now sockt->set_defaultparse()
- set_eof() is now sockt->eof()
- set_noblocking() is now sockt->set_noblocking()
- str2ip() is now sockt->str2ip()
Signed-off-by: Haru <haru@dotalux.com>
|
|
The subnet.conf system has been rewritten to offer greater flexibility,
and to fix some issues that appeared with 838321a36c79e71117320154c9b611c99e93af03.
It is now possible to enter, separately, LAN subnets:
- `lan_subnets`: This is essentially the same feature present in the old
subnet.conf. Each entry in this list defines a (LAN, private) subnet
the server is in. Clients connecting from the same subnet, will be
redirected to the LAN IP rather than the default public IP. The format
has been simplified, and it only requires one IP and one subnet mask (as
opposed to a character and a map server IP).
- `allowed`: Allowed IPs are IP ranges a server (char to login or map to
char) can connect from. Any attempt to connect as a server from an IP
not included here, will fail. For convenience, a wildcard range
(matching all possible IP addresses) has been provided
(`0.0.0.0:0.0.0.0`), but it is very advisable to edit it to a more
restrictive set.
- `trusted`: Trusted IPs are IP ranges excluded from the IPban checks.
This may be useful, for example, to exclude the server's own IP from
ipbans, in case of false positives. Any IP ranges added to this list are
also implicitly included in the allowed IP ranges.
|
|
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Include directives are now directory-independent.
- This will allow building plugins from other directories in future.
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Rather than failing at runtime, plugins that try to access
non-interfaced, unavailable functions or variables, will now show an
error at compile-time.
Signed-off-by: Haru <haru@dotalux.com>
|
|
This includes, and is not limited to: mixed or wrong indentation, excess
whitespace (horizontal and vertical), misalignment, trailing spaces.
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Complies with CERT DCL37-C
- Fixes issue #293 (special thanks to elfring)
Signed-off-by: Haru <haru@dotalux.com>
|
|
This reverts commit 94657284973f4037596bae468ebfbee5c217e02b.
|
|
This reverts commit b6b3f58795288701d0e162d43fa6f0a47af913b3.
Fixes issue 8184
http://hercules.ws/board/tracker/issue-8184-cart-related/
|
|
- Changed order according to the (upcoming) code style guidelines.
- Fixes several issues caused by missing headers when their include
order is changed or in plugins.
Signed-off-by: Haru <haru@dotalux.com>
|
|
Replaced some tabs in the middle of the line with spaces.
Thanks to KeiKun for pointing out #ifdef<tab>_COMMON_SYSINFO_H_ and
making me realize how many of them were there.
Signed-off-by: Haru <haru@dotalux.com>
|
|
http://hercules.ws/board/topic/4283-introducing-hpm-datacheck/
Signed-off-by: shennetsind <ind@henn.et>
|
|
We designed this one with having as little changes required elsewhere in mind, thus the way most socket-related things are called has not changed.
Plugins may now take a greater advantage of the socket features.
Signed-off-by: shennetsind <ind@henn.et>
|
|
- Sanitized all potentially unsafe macros (related eA:15259)
- Improved some function-like macros to evaluate their argument only
once and keep it in a temporary variable. This improves performance
in the damage calculation related code.
Signed-off-by: Haru <haru@dotalux.com>
|
|
- This fixes an issue with timers that stop working after about 24-49
days when the tick overflows (note that this may happen much earlier
than that, and at hard to predict times, on some systems)
- Updated the RDTSC help message in the configure script to also warn
users about issues with SpeedStep enabled systems.
- On Windows, tick() still has a resolution of 10~15ms (or even as low
as 100ms on some systems). A TODO comment (thanks, Ai4rei) was added
for a follow-up patch, as I want this one to be as small as possible)
- Note: on Windows versions earlier than 6.x (Vista, Server 2008), the
tick overflow issue is NOT fixed, since they don't support the
function used to retrieve a 64 bit tick. This isn't a big issue, since
those platforms are already - or going soon to be - out of their
extended support period, and it's already advisable to upgrade, for
other reasons. If you're the unfortunate user of such a system, it is
recommended that you reboot your machine at least once every 49 days
for Hercules to work reliably.
- Note: To clear some doubts, since I've already been asked, this has
absolutely NOTHING to do with 32/64 bit CPUs or OSes. It's all about
a variable's size, not the size of registers of your CPU, and your
32bit CPU will be able to handle this just fine.
Signed-off-by: Haru <haru@dotalux.com>
|
|
- Custom Packet Support
- Custom Data Struct Support (currently append-able to map_session_data and socket_data)
- Char Server Support
- Login Server Support
http://hercules.ws/board/topic/1934-hercules-plugin-manager-update/
Documentation will soon be updated in http://hercules.ws/wiki/HPM
Signed-off-by: shennetsind <ind@henn.et>
|
|
-where it breaks some skills & in game behaviors.
|
|
Ai4rei; thanks!
Another follow up, now to fix maximum value of chatdori setting;
And fixed a bug where warping to a disable map would cause the map-server to crash.
Signed-off-by: Matheus Macabu <mkbu95@gmail.com>
|
|
http://hercules.ws/board/topic/1302-bg-queue-debug/
Signed-off-by: shennetsind <ind@henn.et>
|
|
http://hercules.ws/board/topic/928-memory-slasher-may-30-patch/
Signed-off-by: shennetsind <ind@henn.et>
|
|
a user-friendly way to notify users when their servers are out of sync, e.g.
http://hercules.ws/board/topic/328-intif-guild-data-size-error/
http://hercules.ws/board/topic/315-error-chrif-authok-data-size-mismatch-52224-52228/
Signed-off-by: shennetsind <ind@henn.et>
|
|
[16969:16991/trunk/src/] will be re-committed in the next 24 hours.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16992 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
Removed /SAFESEH option from MSVC11 projects.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16968 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
more reliable and performance-efficient on-demand flagging.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16854 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
rAthena's overall features by letting we know which options are most and least used.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16785 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
winapi specific stuff, to be able to set the appropriate flags before including it correctly)
Note: this may screw up mingw or cygwin building, ill fix it later...
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16219 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
ZC_SKILLINFO_LIST, and this change breaks big storages
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15613 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15610 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
prevent undefined client behavior (may only affect more recent clients?)
+ added a workaround for too large ZC_SKILLINFO_LIST packets resulting from all_skill group permission by sending excess skills one by one (bugreport:5348 and bugreport:5349)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15609 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
performance improvement.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14876 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
- Improved the compile speed for files which include common/socket.h on windows builds (related r10471).
- Moved FIFOSIZE_SERVERLINK define from common/mmo.h to common/socket.h (since it is a server connection FIFO size setting).
- Fixed script command 'areamobuseskill' canceling monster's skill cast before it determined it's new target, which could be 'none' (bugreport:3272, since r13897).
- Added a protection against attempts to read an empty backup / write to a full backup in skill_dance_switch as per TODO from r11347.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14690 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
- Fixed 'mask' being filled with 'ip' when standard mask was specified (since r9647).
- Fixed 'ip' and 'mask' (bit mask) being stored in wrong byte order (network order instead of host order) (since r10162).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14683 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
- Fixed a typo in basejob_baseclass_upper sample script (since r3893).
- Fixed (for sake of consistency) usage of 'sd' before corresponding nullpo check in party_invite (bugreport:2752).
- Fixed atcommand config reading would not cap level for charcommands, when using atcommand level as fallback (bugreport:2961, since r13409).
- Removed orphaned clif_mob_hp declaration from clif.h (bugreport:2788, since r2092).
- Removed unnecessary look-up in itemdb_available macro, as dummy_item is considered unavailable.
- Removed leftover shortlist linked-list struct (followup to r10507).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14680 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14479 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
- 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
|
|
* 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
|
|
- Abstraction for the sql code (sql.c/h).
- New configure script and makefiles.
- Restored txt zeny logging code. (r10814)
- Rewrote mapserver's sql code - itemdb, mobdb, mapreg, logs. (r10814)
- Fixed a precedence issue (&& and ) in char_sql/char.c. (r10833)
- Improved db reading code a bit for consistency. (r11077)
- Added separate atcommand for mail deletion. (r11077)
- Corrected a few messages that said "new" instead of "unread". (r11077)
- Broadcast (*) messages now use "*" as the target's name (not ""). (r11077)
- Moved StringBuf code from utils.c/h to strlib.c/h. (r11084 r11117)
- Some misc login server cleanups (reformatting etc). (r11136)
- Corrected/modified some header entries. (r11141 r11147 11148)
- Adjusted VS project files. (r11147)
- Adjusted the way the sql charserver does item saving. (r11192)
- Corrected usage of reserved keyword 'friend' in mmo.h. (r11192)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11245 54d463be-8e91-2dee-dedb-b68131a5f0ec
|
|
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
|
|
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
|
|
enabled it.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10507 54d463be-8e91-2dee-dedb-b68131a5f0ec
|