summaryrefslogtreecommitdiff
path: root/src/map/party.c
AgeCommit message (Collapse)AuthorFilesLines
2019-08-26Remove round-trip to the inter-server for the party messagesHaru1-16/+9
Signed-off-by: Haru <haru@dotalux.com>
2019-05-05Dont allow invite players, who refused party invitesAndrei Karas1-0/+6
2018-07-24Implementation of the official Achievement System.smokexyz1-0/+4
Source: http://ro.gnjoy.com/news/update/View.asp?seq=163&curpage=1 Script Commands - ``` achievement_progress(<ach_id>,<obj_idx>,<progress>,<incremental?>{,<char_id>}); ``` Includes an achievement_db.conf generator that reads from the item_db, mob_db (server side) and achievement_list.lub files to determine valid achievement entries based on item/monster availability. Achievements containing unsupported entries are commented out. This feature, although renewal-only in official servers, is capable of being used in pre-renewal mode on Hercules. Does not include the title system yet. A big thanks to - @MishimaHaruna for constantly reviewing. @4144 for all the support. @Asheraf for a lot of official information. Co-authored-by: "Dastgir" <dastgirp@gmail.com>
2018-07-01Change functions to static where possible (Part 4 - map)Haru1-56/+75
This fixes issues with plugins defining symbols with the same names Signed-off-by: Haru <haru@dotalux.com>
2018-06-02Merge pull request #2038 from 4144/msiHaru1-1/+4
Improve msgstring table usage
2018-05-312012-2018 !Maytichai Saowa1-1/+1
2018-05-29Add autogenerated messages list headers with original strings and translation.Andrei Karas1-0/+3
Also add packet version checks for used messages.
2018-05-29Fix wrong values in clif_messages enum.Andrei Karas1-1/+1
Also use official constant names with custom prefix in clif_messages enum.
2017-08-01add option to restrict party leader change to same mapgumi1-0/+5
2017-02-12Follow-up 946b7f8490e952fbd90c6760f256ddfdd1e98137KirieZ1-13/+41
2016-12-23Follow-up 19c07f4KirieZ1-1/+1
2016-12-20Follow-up ea449a7, fixed coding-styleKirieZ1-5/+5
2016-12-18Changed behavior when party leader leaves it from party being disbanded to ↵KirieZ1-0/+12
leader being changed to the second user. Closes #1107
2016-12-03Clarify some Job Class vs MapID confusion (2/2)Haru1-4/+3
This commit ensures that `sd->job` and related variables only contain MapIDs (i.e. the serverside optimized values, where High Novice is MAPID_NOVICE | JOBL_UPPER) and are never checked against the client-based Job Class values. As a rule of thumb, from now on, when a variable is named `job` or `jobid`, it is intended to contain a MapID and not a Job Class ID. The type of such variable shall be an unsigned `uint16` or `uint32`. To ensure that related third party code is also verified when this commit is merged, the variable `struct map_session_data::class_ (i.e. `sd->class_`) is renamed to `job`. Some issues in related lines are also fixed, including: - The atcommand `@mount` would not check properly that the requesting character is a 2nd class Swordsman type. - `pc->addfame()` would silently accept invalid MapIDs, sending unknown values to the client (more on this in a subsequent commit). - `pc->famerank()` would not use the passed job as a bitmask, causing the caller to have to mask it beforehand (more on this in a subsequent commit). - The Soul Linker check in TK_JUMPKICK wasn't future-proof (no harm caused currently). - Gunslingers would be able to be targeted by Spiritual Bestowment (`MO_KITRANSLATION`) and Spiritual Sphere Absorption (`MO_ABSORBSPIRITS`) due to a faulty check introduced when the Rebellion class was implemented (causing unintended interaction with Coins). Signed-off-by: Haru <haru@dotalux.com>
2016-12-03Clarify some Job Class vs MapID confusion (1/2)Haru1-2/+3
This commit ensures that `sd->status.class` and related variables only contain Job Classes (i.e. the client-compatible values, where High Novice 4001) and are never checked against the bitmask-based MapID values. As a rule of thumb, from now on, when a variable is named `class`, it is intended to contain a Job Class ID and not a MapID. The type of such variable shall be a signed `int16` or `int`. To ensure that related third party code is also verified when this commit is merged, the variable `struct mmo_charstatus::class_ (i.e. `sd->status.class_`) is renamed to `class`. Some issues in related lines are also fixed, including: - A wrong check in the char server would prevent the correct detection of babies in code related to the family exp sharing. - Baby Arch Bishops would not be affected by Eucharistica. - A wrong check would cause the `questinfo()` script command not to display its information for most classes (except 1-1 classes). - Map IDs and Job Classes were mixed up in `itemdb_jobid2mapid()` and `itemdb_jobmask2mapid()` for 1-1 classes (causing currently no harm, since they just happen to coincide). - The Baby Sura class would not cause parties to be marked as containing a monk type character (for SLS Team Up purposes). - Baby Geneticists would bypass the cart check when trying to equip ammunitions. - Baby Mechanics would bypass the Mado Gear check when trying to equip ammunitions. - Transcendent Shadow Chasers would lose the Stalkers' ability to clone transcendent skills. Signed-off-by: Haru <haru@dotalux.com>
2016-12-02Merge pull request #1494 from Emistry/party_check_stateIbrahem Hossam1-5/+9
Update party_check_state
2016-10-28Fixed copyright year for 2016Lemongrass31101-1/+1
2016-10-27Update party_check_stateEmistry Haoyan1-5/+9
- missing classes checking.
2016-07-25Added a missing entry into messages.conf and added some comments where ↵epuncker1-5/+4
missing, ref #1282
2016-07-02Removed some unused variablesHaru1-8/+0
Follow-up to ff75470f7085c3ca23a9b16be43881b6bc953345 Signed-off-by: Haru <haru@dotalux.com>
2016-06-29Fix EXP modifiers to match aegis modifiers calclution.hemagx1-9/+0
- Now Renewal Level Penalty being calculated in pc_calcexp only - Now Guild Tax is being paid after experience modifiers and not before - Now Experience modifiers being calculated in right way as in aegis (Race modifiers -> PK modifiers -> Premium modifiers -> Buff modifiers)
2016-06-24Add missing checks into party.cAndrei Karas1-2/+47
2016-04-23Removed the 'len' argument from various message-related functionsHaru1-4/+8
- The argument was redundant, since the passed value is always the same as the passed string's length (it doesn't make sense otherwise). The argument is implicit now. Less typing and less errors. - Affected functions: `clif->bg_message()`, `bg->send_message()`, `party->send_message()`, `guild->send_message()`. Signed-off-by: Haru <haru@dotalux.com> Signed-off-by: Haru <haru@dotalux.com>
2016-03-20Dropped typedef from DBIteratorHaru1-7/+7
Signed-off-by: Haru <haru@dotalux.com>
2016-03-20Dropped typedefs from union DBKey and struct DBDataHaru1-1/+2
Signed-off-by: Haru <haru@dotalux.com>
2016-02-27Replaced various '-1' with the correct constantHaru1-9/+18
INFINITE_DURATION, INVALID_TIMER, SC_NONE, INDEX_NOT_FOUND, depending on context. Signed-off-by: Haru <haru@dotalux.com>
2016-02-24Added const qualifier to several variable/argument pointersHaru1-5/+6
- This is necessary for compatibility with a const RFIFOP. Signed-off-by: Haru <haru@dotalux.com>
2016-01-06Replaced the remaining explicit casts with BL_CAST/BL_UCASTHaru1-2/+2
Signed-off-by: Haru <haru@dotalux.com>
2016-01-06Replaced some explicit casts with BL_UCAST/BL_UCCASTHaru1-2/+10
- Replaced casts in foreach callbacks. - Added assertions and nullpo checks where applicable. Signed-off-by: Haru <haru@dotalux.com>
2016-01-06Change all TBL_MOB to struct mob_data as per strly guidelineshemagx1-2/+2
Signed-off-by: Haru <haru@dotalux.com>
2016-01-06Change all TBL_PC to struct map_session_data as per style guidelineshemagx1-8/+10
Signed-off-by: Haru <haru@dotalux.com>
2015-12-15Added GPL-compliant header to all sources and build scriptsHaru1-4/+20
Signed-off-by: Haru <haru@dotalux.com>
2015-10-19rename malloc.c/h to memmgr.Andrei Karas1-1/+1
2015-10-11Cleanup of the HPluginData implementation (second part)Haru1-4/+2
- Changed the hplugin_data_store's array into a VECTOR. Signed-off-by: Haru <haru@dotalux.com>
2015-10-11Cleanup of the HPluginData implementation (First part)Haru1-20/+5
- 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>
2015-09-25More aggressive whitespace cleanup. Follow up to 51329e6Haru1-24/+18
Signed-off-by: Haru <haru@dotalux.com>
2015-08-15HPM compatibility improvementsHaru1-0/+1
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>
2015-06-19Removed ".." from include directivesHaru1-24/+24
- Include directives are now directory-independent. - This will allow building plugins from other directories in future. Signed-off-by: Haru <haru@dotalux.com>
2015-06-01Replaced some of the hardcoded values with constants (map)Haru1-1/+1
- Replaced several hardcoded values with the appropriate enums. - Added documentation for some hardcoded values that haven't been replaced by enums (yet) - Minor code legibility improvements. Signed-off-by: Haru <haru@dotalux.com>
2015-02-23Hercules Ultimate Localization Designshennetsind1-5/+5
Servers can now run on any number of languages, without editing npc files. Designed by Haruna and Ind http://hercules.ws/board/topic/8687-hercules-ultimate-localization-design/ Signed-off-by: shennetsind <ind@henn.et>
2015-01-20Minor fixes and tweaks suggested by cppcheckHaru1-17/+16
- Variable scopes reduced - Parenthesized ambiguous expressions - Removed or added NULL checks where (un)necessary - Corrected format strings - Fixed typos potentially leading to bugs Signed-off-by: Haru <haru@dotalux.com>
2014-12-31Add some missing null pointer checks after automatic checks.Andrei Karas1-14/+17
2014-11-16Whitespace cleanup (no code changes)Haru1-18/+18
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>
2014-09-21Fixed Bug 8293shennetsind1-5/+3
Implemented official party-leader-changed-packet Special Thanks to kyeme! http://hercules.ws/board/tracker/issue-8293-change-party-leader/ Signed-off-by: shennetsind <ind@henn.et>
2014-05-30Fixed typos inside src/Shido1-2/+2
2014-05-13Removed trailing whitespace (sources)Haru1-1/+1
Signed-off-by: Haru <haru@dotalux.com>
2014-05-10Re-commit of "Fixed order of includes in all source files"Haru1-20/+23
This reverts commit 94657284973f4037596bae468ebfbee5c217e02b.
2014-05-10Revert "Fixed order of includes in all source files"panikon1-23/+20
This reverts commit b6b3f58795288701d0e162d43fa6f0a47af913b3. Fixes issue 8184 http://hercules.ws/board/tracker/issue-8184-cart-related/
2014-05-09Fixed order of includes in all source filesHaru1-20/+23
- 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>
2014-02-14sc sourcesshennetsind1-2/+2
Signed-off-by: shennetsind <ind@henn.et>