summaryrefslogtreecommitdiff
path: root/src/map/script.h
AgeCommit message (Collapse)AuthorFilesLines
2013-07-25Expanding script.c interfaceshennetsind1-79/+88
Hercules Renewal Phase One. Signed-off-by: shennetsind <ind@henn.et>
2013-07-18Fixed Bug #7525shennetsind1-0/+1
Item name constants conflicting with script var names will now result in a map server warning/notice and in the background map server will prioritise the script variable over the item name constant. http://hercules.ws/board/tracker/issue-7525-set-variable-is-not-recognized-causing-freezing/ --- Also followup 586c0f7983f81e97ca70c57712e25d4d51453d6b sc_config.txt update Signed-off-by: shennetsind <ind@henn.et>
2013-07-01Fixed Bug #7216shennetsind1-1/+1
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-30Fixed script timer problemshennetsind1-2/+10
Special Thanks to Igniz for bringing it to my attention, ALSO: over 10% script parsing speed boost!<3. Signed-off-by: shennetsind <ind@henn.et>
2013-06-28BG Queue Testingshennetsind1-0/+2
http://hercules.ws/board/topic/1302-bg-queue-debug/ Signed-off-by: shennetsind <ind@henn.et>
2013-06-23Official Item Group/Package/Chainshennetsind1-4/+6
http://hercules.ws/board/topic/1244-official-item-grouppackagechain/ Also Further implemented itemdb.c/storage.c interfaces, and a minor update to db2sql plugin. Signed-off-by: shennetsind <ind@henn.et>
2013-06-15Fixed Bug #7367shennetsind1-2/+10
http://hercules.ws/board/tracker/issue-7367-error-vdb-destroy-during-shutting-down-of-server/ Signed-off-by: shennetsind <ind@henn.et>
2013-06-13Script.c Interface : detach ridshennetsind1-0/+1
Special Thanks to Shizaku for pointing it out! Signed-off-by: shennetsind <ind@henn.et>
2013-06-13Performance Update: Script Parsershennetsind1-0/+3
Now 7% faster, at the expense of (at most 11kb) Signed-off-by: shennetsind <ind@henn.et>
2013-06-08HPM: Update script.cshennetsind1-20/+46
Further implemented the interface Signed-off-by: shennetsind <ind@henn.et>
2013-06-02Follow up 86e9900db60e06738880a57820125ca169c37520shennetsind1-2/+1
Forgot about the Interface. Signed-off-by: shennetsind <ind@henn.et>
2013-06-01Fixed script_rid2sd not being available to HPMshennetsind1-0/+2
Special Thanks to Shikazu Signed-off-by: shennetsind <ind@henn.et>
2013-05-30Memory Slasher - May 30 Patchshennetsind1-0/+38
http://hercules.ws/board/topic/928-memory-slasher-may-30-patch/ Signed-off-by: shennetsind <ind@henn.et>
2013-05-02Introducing Hercules Plugin Manangershennetsind1-5/+124
http://hercules.ws/board/topic/549-introducing-hercules-plugin-manager/ Signed-off-by: shennetsind <ind@henn.et>
2013-04-22Hercules April 22 MEGA-ULTRA-LONG Patch~!shennetsind1-4/+0
http://hercules.ws/board/topic/470-hercules-april-22-patch/ Signed-off-by: shennetsind <ind@henn.et>
2013-02-27Fixed Bug #6527malufett1-0/+1
-Where all NPC don't allow changing of equipments by default and now can be set in 'items.conf'.
2013-02-24Fixed Bug #7092malufett1-1/+1
-Follow up adda8d74c3280ae1e3745591caafd9ce6e81ded7 where 'close2' is not working properly. 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-119/+119
[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-119/+119
Removed /SAFESEH option from MSVC11 projects. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16968 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-08-06Hello World! with this commit trunk will finally be making use of the ↵shennetsind1-0/+4
gorgeous stuff sirius_black last implemented. we want to make sure everything related to this feature is working as intended so for now its being released under a optional define, after the features stability is confirmed the define will be removed along with the previous processings of the feature. By enabling BETA_THREAD_TEST in /src/config/core.h all your mysql logs, query_sql and query_logsql script functions will be handled by a different thread, therefore any slow queries won't have any effect (e.g. slow down) on the game server. Everyone is welcome on helping us test and debug the features, be aware however I DO NOT RECOMMEND YOU TO ENABLE THIS ON PRODUCTION SERVERS AS OF NOW (which is why while we're all testing it still is a optional feature). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16588 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-07-22Added the ability to bind atcommands to NPC events (ex: NPCNAME::OnEvent); ↵cookiecrumbs1-0/+3
original version by ToastOfDoom however heavily modified by I enabling command level at the invoking/character (@/#) level and fixes to prevent console errors as well as fixes aimed to ensure compatibility with rAthena. Updated the script_commands.txt documentation with the following script commands: bindatcmd, unbindatcmd and useatcmd. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16471 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-06-15Fixed bugreport:5740 var reference was not being restored to call ↵greenboxal21-0/+2
buildin_set on assignment statements. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16300 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-28- Updated the script engine to make use of the DBMap* structure for storing ↵epoque111-5/+5
variables (for Ind <3) - Fixed missing new-lines at the end of various files causing warnings git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15997 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-04-27- Added initial support for direct variable assignment (allows assigning ↵epoque111-1/+3
values to variables without the use of 'set') - Note: the set; function is still required to be defined in the source git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15982 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-01-17* Merged changes up to eAthena 15067.eathenabot1-0/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15481 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-12-31Added 4 new all-handy script functions; special thanks to KeyWorld!shennetsind1-0/+1
* getargcount() -- to be used inside functions/callsub labels, returns quantity of arguments provided * is_function(<function name>) -- checks weather a "user" function exists, returning 1 if function is found and 0 otherwise. * freeloop(<toggle>) -- lets you to enable/disable (1 or 0) the loop infinity protection for that specific npc instance, allowing your script to loop as much as it may need. * get_revision() -- retrieves the current svn revision git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15340 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-06-30Replaced custom type 'intptr' with standard 'intptr_t'.ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14873 54d463be-8e91-2dee-dedb-b68131a5f0ec
2011-02-08* Moved script constant manipulation code into separate functions ↵ai4rei1-0/+3
script_get_constant / script_set_constant. [Ai4rei] - Added protection against overwriting existing names in script constant creation code. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14701 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-12-21* Added script_setarray_pc for setting temporary character array variables ↵ai4rei1-0/+1
outside of script.c without requiring them to use script-interal code (add_str and reference_uid). - Applied script_setarray_pc to assignment of dynamic shop arrays (related r5841). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14613 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-12-21* Fixed dynamic shop arrays @bought_nameid, @bought_quantity, @sold_nameid ↵ai4rei1-0/+2
and @sold_quantity not getting reset to zero before use, thus providing attached script with wrong/old data, if it did not clear them by itself in previous call (bugreport:1574, since r5841). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14611 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-12-11* Added support for checking argument data type of built-in script functions ↵ai4rei1-0/+1
(bugreport:1701, topic:261833, related r14573). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14577 54d463be-8e91-2dee-dedb-b68131a5f0ec
2010-11-28* Fixed a crash uncovered with r14501, caused by outdated local variables ↵ai4rei1-0/+3
when a script is about to suspend or terminate (bugreport:4577). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14511 54d463be-8e91-2dee-dedb-b68131a5f0ec
2009-12-02* Autobonus code cleanups.Inkfish1-0/+1
- removed the 'script_parsed' flag to fix the issues with combo items. - introduced a global cache for autobonus scripts so that we don't have to parse scripts everytime invoking status_calc_bl. - fixed such script commands as 'getrefine()' not working inside autobonus scripts. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14180 54d463be-8e91-2dee-dedb-b68131a5f0ec
2009-10-25Hardcoded the even label config settings from r14097.ultramage1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14099 54d463be-8e91-2dee-dedb-b68131a5f0ec
2009-10-25* Implemented the official version of 'OnTouch' named as 'OnTouch_'.(it can ↵Inkfish1-0/+3
be defined in script_athena.conf) * Adapted 'map_foreachinarea' to 'map_forsomeinarea' so that it allows you to specify the number of bl you wanna operate on. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14097 54d463be-8e91-2dee-dedb-b68131a5f0ec
2009-08-12- Optimization to instance system.zephyrus1-2/+0
* Removed the crc feature to generate instance npc names. The instance npc name will be "dup_" + instanceid + "_" + srcnpcid. * Removed the big array under map structure and coded in a different way. It was only used to generate map names, but i just used the instance_id + "origin map name". * Moved all instance features to separated files. * Moved the npc duplication for instances into npc.c as Ultramage says (removed npcname_db from npc.h). * Added recomendations for scripts commands by Saithis. - Testing required, i will prepare Endless Tower script soon. I hope this do almost anything in bugreport 3276. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14003 54d463be-8e91-2dee-dedb-b68131a5f0ec
2009-06-20- Instancing System (Thanks to Sirius White who did most of the code, with ↵zephyrus1-0/+3
some of my work to implement client side information, some optimizations and bugfixes). Also thanks to contributions from UEAUP team and Orcao. - Fixed a bug on areamobuseskill and changed it to make it as Aegis. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13901 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-12-31* Changes to the script engine:FlavioJS1-1/+10
- new stack datatype script_retinfo for C_RETINFO to hold all the return state info that was being stored in the stack. (the script engine in 64bit-ready now) - pop_stack is responsible for adjusting all the stack pointers. - push_* returns the created script_data. - 'return' only converts to value scope variables of the current scope. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13427 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-12-30* Changes to the script engine:FlavioJS1-2/+3
- script ends when run_func can't find the buildin command. (script engine error) - run_script_main doesn't change RERUNLINE to RUN automatically, the buildin command that set it is responsible for that now. The buildin command can use this to detect a rerun. - created functions to alloc/free a script_state. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13426 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-08-21Deleted zombie extern variable declaration which was causing a "static ↵ultramage1-2/+0
declaration follows non-static declaration" gcc compilation error. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13103 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-08-15Some cleaning in script.cultramage1-1/+0
- documentation of functions translation of japanese comments - usage of const char* instead of char* where appropriate - removal of unused isstr() function git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13083 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-08-15Split off mapreg code from script.cultramage1-1/+4
* new mapserver files, mapreg.h, mapreg_txt.c, mapreg_sql.c * removed MAPREGSQL from project files / makefiles * mapreg storage engine is now fully dependent on the server type * added config settings mapreg_txt and mapreg_db to inter config * added get_str() function to complement add_str() * fixed txt mapreg code allowing too long variable names git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13081 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-08-01Removed unused guardian hp columns from the guild castles table in main.sql ↵ultramage1-1/+8
(should have been done in r11915). Corrected incorrect use of the datetime column in the `login` table (bugreport:1962). Refreshed txt account savefile. Cleaned up some random minor source code glitches. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13030 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-04-23* Script parse errors displayed with one ShowError instead of several ↵FlavioJS1-2/+1
ShowMessage's. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12637 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-04-21* Changed the data field of timers from int to intptr.FlavioJS1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12633 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-03-26Adjusted eAthena code to compile cleanly in C++ mode.ultramage1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12436 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-03-24* Reorganized the contents of the mapserver's header files.ultramage1-0/+10
- map.h is no longer a generic dumping spot of all the shared structs, and instead, each such structure now resides in its logical component - map.h now only holds mostly map-related things (needs more cleaning) - there's still a lot of room for improvement (reorganization within individual header files, etc...) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12429 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-02-11* Expanded the script command 'input': (bugreport:811)FlavioJS1-0/+2
- two new optional arguments 'min' and 'max' - return value indicating if it's in the correct range - config variables for the default value of the arguments: 'input_min_value' and 'input_max_value' in script_athena.conf git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12192 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-06- The default event script behaviour is to trigger on labels rather than ↵skotlex1-10/+8
NPCs now. - Removed several script config options which break NPC compatibility when you mess with them (event_script_type, event_requires_trigger, die_event_name, kill_pc_event_name, kill_mob_event_name, logout_event_name, login_event_name, loadmap_event_name, baselvup_event_name, joblvup_event_name) - LoadMap events no longer set the variable "@maploaded$" to the name of the new map. - Optimized/simplified the code now that the previous config options were removed. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11859 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-10Fixed some more gcc incompatibilities...ultramage1-0/+40
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11706 54d463be-8e91-2dee-dedb-b68131a5f0ec