summaryrefslogtreecommitdiff
path: root/src/map/vending.c
AgeCommit message (Collapse)AuthorFilesLines
2015-12-15Added GPL-compliant header to all sources and build scriptsHaru1-4/+20
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-15/+15
- 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-3/+3
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>
2014-11-16Whitespace cleanup (no code changes)Haru1-15/+15
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-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-12/+15
This reverts commit 94657284973f4037596bae468ebfbee5c217e02b.
2014-05-10Revert "Fixed order of includes in all source files"panikon1-15/+12
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-12/+15
- 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-22Changed function types related to SG days in date.cpanikon1-1/+1
Changed types in clif.c: bool clif_setip -> map:ip_set, map: char_ip_set changed as well bool clif_setbindip bool clif_send bool clif_spawn void clif_homskillinfoblock bool clif_sub_guild_invite Note that return values of those types have changed, so if any modification uses their return values it should be changed. clif_disp_onlyself replaced as a macro clif_viewequip_fail replaced as a macro Merged clif_skillup and clif_guild_skillup as they were using the same packet Added packet_len() values in clif_updatestatus
2014-01-08Introducing Hercules Autotrade Persistencyshennetsind1-1/+2
Aka autotrading merchants survive server restarts. Originally sekai's (aka me). Special Thanks to Haruna, Michieru. Signed-off-by: shennetsind <ind@henn.et>
2013-12-15Replaced pc->pc_has_permission/can_give_items/can_give_bound_items with ↵shennetsind1-2/+2
equivalent macros Because 2/3 jumps to perform such a operation is just awful Signed-off-by: shennetsind <ind@henn.et>
2013-12-14Replaced pc->get_group_level with a macro (pc_get_group_level)shennetsind1-1/+1
Because 2 jumps to get a single value is just awful. Signed-off-by: shennetsind <ind@henn.et>
2013-11-07Further item bind adjustmentsshennetsind1-1/+1
Thanks to Haruna! Signed-off-by: shennetsind <ind@henn.et>
2013-11-07Item Bound Fixes/Adjustments/Improvementsshennetsind1-1/+1
Special Thanks to Haruna Signed-off-by: shennetsind <ind@henn.et>
2013-11-06Merge remote-tracking branch 'origin/master'shennetsind1-1/+2
Signed-off-by: shennetsind <ind@henn.et> Conflicts: conf/messages.conf src/common/mmo.h src/map/pc_groups.c src/map/pc_groups.h
2013-11-05Introducing the Hercules Standalone Script Syntax CheckerHaru1-1/+1
- Added a command line argument '--script-check' to check a script's syntax without running the server (and without requiring a SQL connection). Usage: ./map-server --script-check /path/to/the/script.txt - For convenience, a script-checker bash script is provided, to set the path correctly when called from a different directory. Usage: /path/to/Hercules/script-checker /path/to/the/script/to/check.txt - While the script checker will supposedly work under windows as well, no convenience scripts are currently provided for platforms other than UNIX (feel free to open a pull request with a .bat launcher or whatever you like) - Integration with IDEs or text editors is possible. In fact, I already have a fully functional plugin for vim (through vim-syntastic), and if there's enough interest, I'll publish it. - screenshot: http://d.pr/i/NOBD - If you want an online checker, http://haru.ws/scriptchecker/ is running this code, without modifications and will be kept up to date (without any warranty though.) - Special thanks to Ind, Yommy, Streusel, who helped making this possible, in a way or another.
2013-10-31No error after compilation, but when logging in at map server it will crash.sevenzz231-1/+2
Im pretty sure its on the clif.c Signed-off-by: sevenzz23 <sevenzz23@yahoo.com>
2013-09-27Renamed iMap interface to mapHaru1-4/+4
Signed-off-by: Haru <haru@dotalux.com>
2013-09-09Fixed Bug #7540shennetsind1-1/+1
Fixed searchstores crashing when trying to query data of offline vendings (vending db wasn't removing entries upon logout), also changed vending->db index to char id instead of vender id. Special Thanks to hemagx, jTynne. http://hercules.ws/board/tracker/issue-7540-new-map-crash/ Signed-off-by: shennetsind <ind@henn.et>
2013-07-01Fixed Bug #7216shennetsind1-0/+2
Special Thanks to Shikazu, wouldn't have been able to identify this issue without his help! http://hercules.ws/board/index.php?app=tracker&showissue=7216 Signed-off-by: shennetsind <ind@henn.et>
2013-06-25- Added chrif interfaceSusu1-2/+2
2013-06-13Hercules Renewal Phase : Renewalmalufett1-1/+1
Rename SC names to eagis standard. Implement SC Configuration.(see db/sc_config.txt) Skill updates and fixes. Some code optimization. Signed-off-by: malufett <malufett.eat.my.binaries@gmail.com>
2013-06-08Follow up d73783f22b2bb881aab74524d153d89a5932a199shennetsind1-10/+10
Adjusting pc.c interface name to adhere with the rest (pretty much we try to make it as short as we can, and being there were no conflicts we saw no reason to maintain the 'i') Signed-off-by: shennetsind <ind@henn.et>
2013-06-07Hercules Renewal Phase One : pc, party, map, timerSusu1-14/+14
Added iPc, iParty, iMap, iTimer to HPM exported interfaces
2013-04-22Hercules April 22 MEGA-ULTRA-LONG Patch~!shennetsind1-97/+86
http://hercules.ws/board/topic/470-hercules-april-22-patch/ Signed-off-by: shennetsind <ind@henn.et>
2013-03-30Hercules Renewal: clif.c completeshennetsind1-2/+2
Added the last missing functions into the interface, all functions in clif.c are now wired to the interface. http://hercules.ws/board/topic/237-hercules-renewal/ Also shortened clif->displaymessage to clif->message, removed the old clif->message and merged its functionality with clif->disp_overhead (both use the same packet and do the same thing :P) - and a gazillion other stuff: http://hercules.ws/board/topic/316-introducing-hercules-channel-system/ Signed-off-by: shennetsind <ind@henn.et>
2013-03-29Hercules Renewal: clif.cshennetsind1-16/+16
1st Phase Complete. http://hercules.ws/board/topic/237-hercules-renewal/ Signed-off-by: shennetsind <ind@henn.et>
2013-03-08Fixed Bug #7114malufett1-29/+1
-revised/added 'npc_isnear' where it checks if an NPC is nearby when making chat rooms or using vending. Signed-off-by: malufett <malufett.eat.my.binaries@gmail.com>
2012-12-05- Undid r16968: SVN Replaced with source:/trunk/src/@16966 (tid:74924).brianluau1-320/+334
[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
2012-11-25Applied AStyle code formating as discussed on tid:74602.greenboxal21-334/+320
Removed /SAFESEH option from MSVC11 projects. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16968 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-11-12-Add/upd basic documentation for script.cglighta1-10/+10
-Fix some indentation and strange codestyle change to A-Style git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16915 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-11-12-Add Homon-S skills, 1st implementation (all done except Eleanors)glighta1-15/+12
--Upd Skill conf to set land-limit for homonculus by default (ground skill limit) --Mv MH_HEILIGE_STANGE and MH_ANGRIFFS_MODUS skill from Eleanor to Bayeri -Enforce all zeny transaction to use pc_payzeny and pc_getzeny handlers, (auto log and clif) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16914 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-10-29-Add some src basic documentation.glighta1-1/+1
-Change some remaining -1 for status ending timer. -Move some hardcoded msg in msg_athena -Small optimisation on battle_attr_fix git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16835 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-06-06- Follow-up to r16236, additional array increase to accommodate sprintf messagesepoque111-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16237 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-06-04Follow up r16227 & bugreport:5929 fixed typo. super mega hug to malufett <3shennetsind1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16229 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-06-03Adding new config min_npc_vending_distance which simulates the official 'no ↵shennetsind1-2/+26
vending near npcs' feature. super mega credits to masao git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16227 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-13 - Added `libconfig` (configuration file library: ↵gepard19841-2/+2
http://www.hyperrealm.com/libconfig/): - Updated VS9/10 project files. - Updated `configure` & `Makefile`s. - New GM, Commands & Permissions system: - '''This is a backwards compatibility breaking update''', please read tid:58877 - Replaced GM levels with Player Groups. - Commands permissions & other privileges now depend on group, not GM level. - `@help` command improvements: requires "commandname" param and shows more detailed info about commands. - Modified GM whisper system to deliver messages basing on permissions, not GM level. - Remote trade request is now possible only if player is allowed to use `@trade` command as well. - Added a proper permission to use `/changemaptype` command. - `clif_displaymessage` is now capable of displaying multiline messages. - All `ACMD_FUNC`s are static now, and the only way to invoke them is with `is_atcommand()`; all client commands (starting with `/`) are now translated into corresponding atcommands (with exception of `/kick` used on monster, as there is no atcommand to kill single monster). - Removed nonsense "bot check" triggering when player blocked (`/ex`) Server. - Merged `@monster`, `@monsterbig` and `@monstersmall`. - Improved flow of atcommand execution to avoid revealing info about online players or existing commands to non-privileged players. - Merged `atcommand` and `charcommand` script functions (`charcommand` is aliased to `atcommand`). - Fixed `atcommand` script function reading unknown memory area (possible access violation). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15572 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-17* Merged changes up to eAthena 15054. [ai4rei]eathenabot1-3/+3
* clif cleanup: Changed argument types of some clif functions. - Added enumeration for skill failure codes and made clif_skill_fail use it. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15472 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-11Picklog improvements:gepard19841-6/+2
- now it is finally possible to log every item players gain or lose - added 3 log types: `I` for auctioned items, `B` for buying shop transactions and `X` for all other items transactions that don't fall into another category (for detailed explanation on all log types read `conf/log_athena.conf`) - it also fixes items being logged as picked up/gained by player when in fact they were dropped on the ground due to full inventory git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15420 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-24* Merged changes up to eAthena 15040.eathenabot1-6/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15245 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-20follow up to r15188 -- mr.ind forgot this little guy, sorry!shennetsind1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15189 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-20vending bugfix for bugreport:947shennetsind1-3/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15188 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-17- Replaced log_config.enable_logs constants with LOG_ enums that existed ↵brianluau1-1/+1
since r9599. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15150 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-03-27* Added separate character state for vending (like for buyingstore), instead ↵ai4rei1-12/+11
of vender_id != 0 (follow up to r14682, related r14713). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14762 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-03-06* Implemented search store info system (aka. vending and buying store ↵ai4rei1-1/+89
search) together with related items. - Requires 2010-08-03aRagexeRE or later and can be disabled in 'conf/battle/feature.conf'. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14732 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-01-26* Fixed buyers, that are currently in a vending shop could be fooled into ↵ai4rei1-8/+25
buying an item at different price than they see by reopening the vending shop (bugreport:4728). - This implements the official vending shop unique id handling (previously mistaken for char id), made compatible with packets before it's introduction (follow up to r14234). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14682 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-12-26* Fixed opening other player's vending terminating currently running NPC ↵ai4rei1-1/+1
conversation. Vending is now unavailable when talking to an NPC (bugreport:2208). * Fixed vending not accepting 0 Zeny as sell price. The client asks for confirmation when you attempt to sell items at 0 Zeny (bugreport:2595, since r918 and r11344). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14628 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-12-07* Reverted r14563, due to multiple issues which render the source ↵ai4rei1-1/+1
malfunctioning or uncompilable. To be redone later (bugreport:4627). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14567 54d463be-8e91-2dee-dedb-b68131a5f0ec