150 Commits

Author SHA1 Message Date
AshiHanna
a7f0aab600
Add the stockall command (#8008)
* The command will transfer all items from the cart to the inventory based on the item type.
2023-12-12 08:12:06 -05:00
Vincent Stumpf
833966f47b
Convert guild_db to unordered_map (#7612)
* Refactor guild db to STL container

* Split up struct guild and MapGuild/CharGuild
2023-06-16 19:42:55 -07:00
Atemo
aa8f501388
Added atcommand "setcard" (#7804)
Thanks to @aleos89 and @Lemongrass3110 !
2023-06-08 20:08:26 +02:00
Atemo
38d335a267
Added more information for atcommand refine (#7803) 2023-06-08 14:01:43 +02:00
Aleos
5b832de199
Minor cleanup to mapflags (#7782)
* Adds missing documentation for mf_norodex.
* Updates atcommand mapflag to display information on some missing mapflags.
* Removes "Other Flags2" and combine list with "Other Flags" for atcommand mapflag.
2023-06-07 10:11:32 -04:00
Vincent Stumpf
08a1c41d1b
Refactor MapFlag accessors (#7783)
Use methods instead of direct member access.
2023-06-03 17:38:29 -07:00
Pokye
9907721a69
Added a mapflag to block BANK (#7773) 2023-05-22 12:23:46 -04:00
Vincent Stumpf
7dd6eb5182
Add other player in mail transactions (#7568)
* Add other player's char_id in mail transactions

Thanks to @tokeiburu

Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2023-03-14 02:30:23 -07:00
Vincent Stumpf
8f4a1d2932
Remove relative includes for 3rdparty imports (#7609)
This also changes the imports for config, custom to use the src include path
2023-03-07 16:21:28 -08:00
Aleos
240f71cbce
Converts Homunculus Database to YAML (#4659)
* Converts the Homunculus Database and Homunculus Skill Tree Database into one YAML flat file.
* General cleanups and optimizations.
* Includes CSV2YAML converter.
Thanks to @Lemongrass3110 and @Atemo!
Co-authored-by: Atemo <capucrath@gmail.com>
2023-02-15 14:42:51 -05:00
Vincent Stumpf
e235c9cab4
Change common and config includes to use <> (#7596) 2023-02-12 12:46:06 -08:00
Lemon
7e62670882
Improved itemlink logic (#7532)
Fixed tags and separators for various packet versions.

If itemlink is disabled it will output the item name with the refine as prefix and the slots as suffix (if equipment)
It will also append [0] if the item is an equipment and has 0 slots (to make it easier to tell from non-equipment items)

Disabled feature on packet versions older than 2015-11-04 until proven otherwise

Fixes #7441

Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2023-01-23 10:49:18 +01:00
Lemongrass3110
14cb61d598
Removed mapindex from char-server (#7533)
Converted last_point to mapname
Converted save_point to mapname
Converted memo to mapname
Converted start point to mapname
Removed default map
Converted party member to mapname
Converted maplists to mapname
Removed mapindex loading
Fixed instance loading with multiple map-servers
Fixed castle loading with multiple map-servers
Fixed battleground loading with multiple map-servers
Fixed warping between map-servers

Thanks to @aleos89 for his help!
2023-01-11 16:54:53 +01:00
Lemongrass3110
c9aaf540bf
Added reloadbarterdb (#7530)
Fixes #7520

Thanks to @attackjom
2023-01-06 00:23:25 +01:00
Lemongrass3110
2c4ee64b59
Start refactoring the core to C++ (#7303) 2022-12-20 23:37:31 +01:00
Lemongrass3110
d1e184e46c
Initial version of cashmall (#7450)
Introduces the cashmall
Added Cachua_Coupon exchange NPC
Enabled Devil Enchant Master and moved to Cash Mall
Moved Mergician
Added Basta, Mighty Hammer and Brock
Moved Shadow Blacksmith
Added Cash Hair Stylist
Added a feature switch for Stylist UI
Updated Hair Stylist

Thanks to @aleos89, @Atemo and @eppc0330!

Co-authored-by: aleos <aleos89@users.noreply.github.com>
Co-authored-by: Atemo <Atemo@users.noreply.github.com>
2022-12-18 00:39:50 +01:00
Singe Horizontal
8eac71f57f
Cleaned struct tokens for map_session_data and status_change (#7490)
Fixes #7492
2022-12-16 19:16:29 +01:00
Vincent Stumpf
1f4c068c39
Refactor status change entries (#7356)
* Make map_session_data a class, call constructor/destructor on alloc/free

* add getSCE

* add create, delete, clear SCE

* Use getSCE, make data access private

* add a cache for last-fetched status
2022-12-13 23:47:53 -08:00
Aleos
ee2dcf816e
New macro detection features (#7359)
* Adds battle config macro_detection_punishment to ban or jail characters.
* Adds battle config macro_detection_punishment_time to adjust the duration of ban/jail for players who fail the captcha challenges.
* Adds script command macro_detector which invokes the captcha challenge.
* General cleanups to the jail functions to remove duplicate code.
* General cleanups to the macro punishment calls to remove duplicate code.
* Ending SC_JAILED will now properly remove the jail status rather than trying to reset the timer to 1 second resolving any possibility of players getting stuck.
Thanks to @Lemongrass3110!
2022-12-13 15:44:42 -05:00
Lemongrass3110
a090a0a7ba
Added an atcommand for roulette (#7433) 2022-11-14 21:32:10 +01:00
SapitoSucio
55d3c1578c
Itemlink command and integration (#7291)
Co-authored-by: Akkarinage <mike.langford@industrial-illusions.net>
Co-authored-by: Aleos <aleos89@users.noreply.github.com>
Co-authored-by: Atemo <Atemo@users.noreply.github.com>
Co-authored-by: cydh<cydh@users.noreply.github.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
Co-authored-by: secretdataz<secretdataz@users.noreply.github.com>
2022-11-11 18:04:41 +01:00
Aleos
d7bf5ebb58
Adds support for macro detection (#7315)
* Adds the official client macro detection system.
* Includes the ability to load imagery at server boot.
* See doc/captcha_db.txt for more information!
Thanks to @Asheraf and @Lemongrass3110!
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2022-10-14 10:54:19 -04:00
Lemongrass3110
fa4666d7af
Fixed some packets for 2022 clients (#7276)
Migrates a few packets from FIFO to structs.
Migrates friendlist to struct and fixed invalid version check.
Added a new guild related packet that does nothing for the time being.
Synced to latest Hercules' packet definitions.
Fixed name of ZC_SOULENERGY.

Thanks to @Dia and @Pokye.
2022-09-22 01:50:24 +02:00
Lemongrass3110
b1b371f4b8
Cleaned up status_change_end (#7211)
* Removed leftover old debug info that made it necessary to the hide the real function behind a define.
* Introduced a C++ default argument for timer id, as the timer id is only needed a single time, when the status expires naturally.
* Replaced all currently existing calls that had INVALID_TIMER as argument and made use of the new default argument.
2022-08-26 22:23:40 -04:00
Atemo
a2747b2023
Script command for enchantgrade (#7180)
* Added several commands to manage the enchantment grade of equipment
* Added grade atcommand
** Works like refine atcommand for grade system

Thanks to @Lemongrass3110 !
2022-08-22 22:41:40 +02:00
Aleos
8038e71322
Speed up item and mob information commands (#7084)
* Fixes #7081.
* Small refactor of the atcommands: iteminfo, mobinfo, whodrops, and idsearch.
* Item information gathering is now sped up.
* Refactored itemdb_searchname_array to store results in a std::map so that the data is sorted by ID automatically.
* Cleanups across the board to remove extra calls for itemdb_exists().
Thanks to @voyfmyuh, @CairoLee, and @Lemongrass3110!
2022-07-22 15:11:44 -04:00
Aleos
256735a136
Fixes mob and item atcommand sorting issues (#7058)
* Fixes #7055.
* Fixes several atcommands used for mob and item information were not properly accounting for order.
* Resolves an issue where YAML databases were not properly utilizing the cache feature.
* Increased MAX_SEARCH to 10 by default as in renewal there are many more items with duplicated names.
Thanks to @Playtester!
Co-authored-by: Playtester <Kenji.Ito@gmx.de>
2022-06-24 09:53:31 -04:00
Lemongrass3110
001981cf66
Initial implementation of enchantgrade UI (#6913)
Includes walkscript conversion of kRO scripts

Thanks to @Asheraf, @Balferian, @JohnnyPlayy, @aleos89, @Atemo, @eppc0330 and @Pokye.

Co-authored-by: JohnnyPlayy <lenon32@gmail.com>
Co-authored-by: Asheraf <Asheraf@users.noreply.github.com>
Co-authored-by: Balferian <balfear@yandex.ru>
Co-authored-by: Aleos <aleos89@users.noreply.github.com>
Co-authored-by: Atemo <Atemo@users.noreply.github.com>
2022-06-07 16:45:35 +02:00
imlevi
b8c3e885da
Fix optional argument not being considered in setbattleflag (#6973) 2022-05-23 12:21:37 -04:00
Daegaladh
2bb740115e
Renamed NoMineEffect mapflag to ForceMinEffect to clarify it's behavior (#6940) 2022-05-14 13:20:10 +02:00
Aleos
8bd77496da
Fixes atcommand reloadatcommand (#6891)
* Fixes #6874.
* Removes an extra config file check that is no longer needed.
Thanks to @reunite-ro!
2022-05-03 23:13:28 -04:00
Lemongrass3110
51ddc63a02
Converted player groups to YAML (#6488)
Finally adds import functionality for player groups and therefore atcommand and permission defining.

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2022-04-15 23:47:44 +02:00
Lemongrass3110
01261dbf3d
Cleanup after RYML merge (#6785)
Speeded things up even more by making use of C++'s reference feature.
Fixed #6770 warning while at it.
Added back support for case insensitive booleans.
Fixed a very rare issue with cached databases.
Removed .children() calls
Added back type safety reports
Added ryml to login-server makefile

Thanks to @aleos89, @Atemo and @idk-whoami
2022-04-03 04:02:13 +02:00
Cydh Ramdh
16ccad42e8
Update vending and buyingstore on warp (#6718)
Fixed #6671, vendor & buyer location never been updated if the location is changed
Added MF_NOBUYINGSTORE and CELL_NOBUYINGSTORE to separate from MF_VENDING & CELL_NOVENDING
Added some missing check for buyingstore states
Updated mapflag doc
Added new constants

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2022-03-31 23:08:35 +02:00
Jittapan Pluemsumran
d1b7061f5a
YAML loading optimization (#5997)
* Use rapidyaml library to parse YAML databases instead of yaml-cpp.
* Drastically reduces the parse time for yaml databases.
* Removes yaml-cpp content from main servers, except for tool emitter.
Co-authored-by: Vincent Stumpf <vincents.995@gmail.com>
Co-authored-by: Atemo <capucrath@gmail.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2022-03-30 16:38:52 -04:00
Aleos
302168d1f3
Fixes SCB calculations (#6733)
Follow up to d739e8f.
Resolves issues with status calculations getting improperly checked.
Thanks to @mazvi, @kaninhot004, and @Rayvakarian!
2022-03-23 10:40:35 +01:00
Cydh Ramdh
c454443a0b
Added @addfame (#6588)
* Added `@addfame`
* Added alias `famepoint`, `famepoints`
* Changed `sd` in `pc_addfame` to reference

Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2022-02-16 01:00:59 +07:00
Lemongrass3110
534c5b2edd
Add more Github Actions (#6530)
Renames "build_servers.yml" to "build_servers_gcc.yml"
Removed Pre-Renewal and Renewal from GCC compilation
Added an action for Pre-Renewal and Renewal
Added an action for VIP
Added an action for different packet versions
Added MSVS build
Changed some make server to make all
Added master building
Disabled LTO by default
Added some missing override declarations
Added Clang building
Disabled Clang 12 and 13 for the time being

Thanks to @aleos89 and @Akkarinage for their help and input.
2022-01-19 00:08:28 +01:00
Lemongrass3110
c22ef3f547
Initial release of stylist UI (#6446)
Fixes #3037

Thanks to @Balferian and @aleos89

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2022-01-09 21:56:58 +01:00
Lemongrass3110
7556453dfc
Merge of Rytech's 4CrAM (#6414)
Merged Rytech2/4CrAM-Open@978d4fc406

Original author is @Rytech2 and all credits belong to him.
Cleanups by @Lemongrass3110, @aleos89 and @Atemo.

Co-authored-by: Rytech2 <rytech16@gmail.com>
Co-authored-by: aleos <aleos89@users.noreply.github.com>
Co-authored-by: Atemo <capucrath@gmail.com>
2021-12-30 20:25:19 +01:00
Atemo
b644bcfe69
Converts the Skill Tree Tables file into YAML (#6070)
* Converts the Skill Tree Tables file into YAML.
* Includes CSV2YAML converter.
* Corrected the tree according to the client (SkillInfoList)
* Removed 3rd jobs tree from pre-renewal, some required stats not being loaded by default

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2021-12-14 00:00:33 +01:00
Atemo
4a778815a3
Converted mercenary_db to YAML format (#6101)
* Converts the Mercenary Tables file into YAML.
* Includes CSV2YAML converter.
* Fixed mercenary name not properly displayed after moving

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2021-12-07 00:49:44 +01:00
Atemo
a205287307
Converted elemental_db to YAML (#6102)
* Converts the Elemental Summons Tables file into YAML.
* Includes CSV2YAML converter.

Thanks to @Lemongrass3110, @aleos89, @secretdataz !
2021-11-26 00:53:35 +01:00
Aleos
6bc0dff20d
Converts Job databases to YAML (#4759)
* Converts the job_db, job_db2, job_basehpsp_db, job_exp, and job_param_db to YAML.
* Optimizes several places utilizing C++ features.
* Removes 3rd class job data from pre-renewal.
* Adds minimal support for 4th jobs.
* Job level bonus stats now supports multiple bonuses per level as well as an integer for the specific stat instead of only being limited to 1.
* Includes CSV2YAML converter.
Thanks to @Lemongrass3110, @Atemo, @Balferian, @attackjom, @dimasshotta!
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
2021-11-17 16:13:07 -05:00
Lemongrass3110
c4df5caa00
Added support for level 2 armors (#6251)
Thanks to @Atemo and @aleos89 for their help.

Co-authored-by: Atemo <capucrath@gmail.com>
Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2021-10-06 16:57:25 +02:00
Aleos
393ec53272
Fixes a potential map crash for atcommand mapflag (#6255)
* Fixes #6254.
* Adds a few checks for MF_RESTRICTED so the status is not disabled if other zones are active for the same map.
Thanks to @xEasycore and @Lemongrass3110!
2021-09-16 16:56:18 -04:00
Atemo
f4fbfb3299
Clean-up the npc_enable_target function (#6248)
* Clean-up the npc_enable_target function

Thanks to @Lemongrass3110 and @aleos89
2021-09-11 14:56:36 +02:00
Atemo
69802a23fb
Suggestion: NPC name as parameter in enablenpc (#6233)
* The required NPC name parameter is now optional for the following script commands:
    enablenpc
    disablenpc
    hideonnpc
    hideoffnpc
    cloakonnpc
    cloakoffnpc
    isnpccloaked
* Updated docs

Co-authored-by: Aleos <aleos89@users.noreply.github.com>
2021-09-09 14:50:24 +02:00
SeravySensei
72aafdadea
Fixed drop rate bonuses (#3986)
Fixes #2613

Co-authored-by: aleos <aleos89@users.noreply.github.com>
Co-authored-by: Lemongrass3110 <lemongrass@kstp.at>
Co-authored-by: Atemo <Atemo@users.noreply.github.com>
2021-08-27 23:00:41 +02:00
Lemongrass3110
6b84115790
Speeded up item name lookup (#6161)
Partial takeover from #5997
Did some further cleanup and took it out of the pull request until secret has time to finish it.

All credits to @secretdataz

Co-authored-by: secretdataz <secretdataz@users.noreply.github.com>
2021-08-08 16:46:44 +02:00