471 Commits

Author SHA1 Message Date
Cydh Ramdh
09b2ea06ee * Refactor pc_setparam for SP_BASEEXP and SP_JOBEXP.
* Added script command `getexp2` for safety usage of `set BaseExp,n;` and `set JobExp,n` usages.
* Cleanup exp lost functionto `pc_lostexp`.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2016-03-20 12:31:44 +07:00
Lemongrass3110
8636cb2489 Added a sample NPC for the new navigateto script command
Additionally fixed up the documentation some more.
2016-03-06 23:24:33 +01:00
aleos89
809f220b9f Added to script command navigateto documentation
* Small follow up to 179f734.
* Also corrected an invalid constant.
2016-03-06 16:15:54 -05:00
aleos89
179f734249 Added documentation for script command navigateto
* Follow up to 4f13007.
* Corrected a few constants from PLANE -> AIRSHIP.
2016-03-06 16:10:15 -05:00
aleos89
8e283d2a00 Follow up to 0a77835
* Some basic refactoring.
* Cleaned up the documentation for script command getmapxy.
-- Removed UNITTYPE_MOB from the script command.
2016-02-05 12:38:30 -05:00
aleos89
0a77835029 Unit Controller Updates
* Added missing UMOB_CANMOVETICK option.
* Restructured script command getunittype return values to match the order of script command getmapxy to allow for more universal usage.
* Created constants for script commands getmapxy and getunittype.
* Updated NPCs using script command getmapxy to use the new constant values.
* Updated Battleground NPCs to use constant value for script command setunitdata.
2016-02-04 10:47:16 -05:00
Napster
3a8aac4fb0 Follow up d70b173
*Missing document for body style
2016-01-13 16:37:23 +07:00
Napster
c1f843d755 Follow up d70b173
* Remove sctipt command closedressroom not used this
* cleanup some code
* check white space
* add detail&document packets
2016-01-13 13:10:57 +07:00
Napster
d70b1734c8 Add support body style implementation
* This feature require the client support before 2015-05-13 or newer
   Make sure you data&lub support for this

  note : read info to https://rathena.org/board/topic/104205-2015-client-support/

  Special Thanks you to Rytech, @aleos89
2016-01-12 01:55:30 +07:00
Lemongrass3110
33729eb961 Migrated all look constants to source exports 2016-01-07 00:43:26 +01:00
Lemongrass3110
28e337127e Migrated all getmonsterinfo constants to source exports
Created the respective enum on source side and changed the script doc to only refer to the constants not the direct values.
Additionally adjusted the sample script.
2016-01-06 23:55:06 +01:00
Lemongrass3110
a68ab0c88d Migrated all getpetinfo constants to source exports
Created the respective enum on source side and changed the script doc to only refer to the constants not the direct values.
2016-01-06 23:28:05 +01:00
aleos89
649acd8310 Documentation Updates
* Corrected the storage location for different variable types.
2015-12-21 10:22:18 -05:00
Atemo
01e041874c Fixed some typo 2015-12-02 01:54:07 +01:00
Atemo
24ecdadf48 Merge branch 'master' into academie 2015-12-02 00:40:42 +01:00
Atemo
5695dc57e2 Update & fix.
- Updated script_commands.txt
- Fixed typo in bio4_reward.txt
- Fixed getexp command giving 1 exp with 0 value
2015-11-29 16:57:04 +01:00
Atemo
c3e56b9c1b Update 2015-11-26 23:11:22 +01:00
Atemo
7fcd0f5b9d Clean up 2015-11-24 23:22:42 +01:00
Atemo
4f3f483bfa Remove setquestinfo_req state 3 unused in aegis (currently commented) 2015-11-24 18:12:52 +01:00
lighta
8703eacfe4 Merge branch 'academie' of https://github.com/rathena/rathena into academie 2015-11-17 22:19:38 -05:00
aleos89
c389a6c456 Follow up to e276970
* Fixed an issue with ATK/MATK params. Thanks to Lord Ganja.
2015-11-16 11:14:42 -05:00
Atemo
cc8edaaac6 Merged novice academie from Hercules 21564acf13
-> All Credit to Kisuka for this big work.

Added news commands to alter questinfo conditions :
- setquestinfo_level : Add level range criteria for quest info with quest id 'quest_id'.
- setquestinfo_req : Add quest requirement for quest info with quest id 'quest_id'.
   -> Player have / doesn't have the required quest.
- setquestinfo_job : To add additionnal job criteria.
-> Credit to Cydh !
2015-11-16 00:34:00 +01:00
aleos89
e276970723 Updates for Unit Controller Script Commands
* Follow up to 2cee5b6.
* Fixes #516 - Base stats (STR, AGI, etc) will now stick after the unit's statuses are recalculated.
* Statuses are directly modifiable now (ATK, DEF, etc)
* Created constant values so it's a lot easier to read.
* Updated script command documentation to reflect changes.
2015-11-14 11:47:38 -05:00
Cydh Ramdh
de40271000 * Follow up 2cee5b6ff1bf53c4ae53bc1278b09ae84b8a0a76: gethominfo, getpetinfo, and getmercinfo for type 0 were correct 'to get ID' from database/their unique ID, not as GID.
* Added type for `gethominfo`, `getpetinfo`, and `getmercinfo` to return GID.
* Added `geteleminfo`, to retrieve Elemental ID and GID. The otherinfo can be gained from `getunitdata`

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-10-14 10:27:31 +07:00
Cydh Ramdh
927d1e2f5c * Fixed #629. Thank @anacondaqq and @theultramage
* Added optional param `char_id` for `instance_enter`.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-10-10 19:04:15 +07:00
Cydh Ramdh
81662aacee Updated doc/script_commands.txt, as follow up 6295c77d393555fe5a366f092a75f4cf0d2de933.
Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-10-07 07:02:14 +07:00
Cydh Ramdh
c9c988abba * Fixed #654, TF_BACKSLIDE failed if player has 'no knock back' bonus.
* Clean up on buildin scripts, to use constant in return value.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-10-03 22:29:46 +07:00
nanakiwurtz
9f126d2d73 Item DB Update
* Added Moving Dark Matter (6940)
* Add 2 spaces to script_commands.txt

Signed-off-by: nanakiwurtz <nanakiwurtz240@gmail.com>
2015-09-27 05:09:02 +07:00
Cydh Ramdh
31505d1423 * Fixed #607:
* Added array variable option in 3rd param of `getguildmember` and `getpartymember`, so the script will returns the result in reserved array instead using temporary global variable.
  * Also, the script returns the member found directly.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-09-04 00:32:38 +07:00
Aleos
6295c77d39 Merge pull request #457 from rathena/feature/script_engine_upgrade
Script Engine Upgrade
* More information here: https://rathena.org/board/topic/102946-script-engine-upgrade/
2015-08-31 14:26:15 -04:00
aleos89
d95f5d2db7 Bug Fixes
* Fixes #447 - Added script command 'unitblockmove' to be used with OnTouch and Unit Commands.
* Fixes #448 - Leech End will no longer get a player stuck in stand/sit modes.
* Fixes #503 - Added script command 'ignoretimeout' which disables the SECURE_NPCTIMEOUT of a specific script.
* Fixes #521 - Pre-renewal Shield Chain should always be Neutral damage.
* Fixes #532 - Fixed an issue with the 'item_check' config not saving the unique ID when enabled.
* Fixes #537 - Arms Cannon is now a single unit target skill.
* Fixes #541 - Cleaned up Ignition Break damage formula.
* Fixes #543 and Fixes #552 - Cleaned up Reverberation to match official. Now splits damage among targets.
* Fixes #546 - Updated Randomize Spell to the latest official skill list and rates.
* Fixes #547 - Escape is now a self skill and can use normal Traps if no Alloy Traps are available.
* Fixes #551 - Great Echo and Sound of Destruction can now blocked by Pneuma.
* Fixes #556 - Adjusted Arrullo, Deep Sleep Lullaby, Netherworld, and Voice of Siren duration formulas to properly account base/job levels.
* Fixes #561 - Pre-renewal Tiger Cannon now properly removes HP when casting skill.
* Fixes #576 - Shield Spell, Exceed Break, Overbrand, Moon Slasher, Piety, Earth Drive, and Hesperuslit no longer have fixed cast time.
* Cleaned up Shadow Formation SP Drain formula to be 11-skill_lv per second.
* Sound of Destruction is now a placement skill type.
* Updated variable cast time for Windmill Rush from 2 seconds to 1 second.
2015-08-17 14:13:22 -04:00
Cydh Ramdh
e1b658e462 * Item GUID Updates:
* Removed `ENABLE_ITEM_GUID` from src/config/core.h, after long time introduction it's worth to be enabled by default. Just remove all items with GUID flag if want to remove it generates GUID .
  * Implemented client interface to merge the items. Packet struct credits: 856b6f1feb
  * Edited `mergeitem` script command to use the interface, moved the 'old' `mergeitem` to `mergeitem2`.
  * Fixed the behavior to add GUID'd item to inventory in Cash Shop.
  * Updated item_flag.txt for listing `IT_CASH` items (item type 18).
  * NOTE: `IT_CASH` items which defined in item_flag.txt with flag `4`, cannot be merged.
  * NOTE: Please check the packets for older clients. Tested work on 2012-04-10, 2013-08-07 and 2014-10-22.
  * NOTE: Please import 'upgrade_20150804.sql' for MySQL Log Database.
* Removed duplicate clif functions:
  * `clif_msgtable()` -> `clif_msg()`
  * `clif_msgtable_num()` -> `clif_msg_value()`
* Item DB Updates:
  * Indonesia_Box2 (17079) should gives 5x Wing_Of_Butterfly (602).
  * Changed some item types to 18.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-08-04 20:57:49 +07:00
nanakiwurtz
05246c1688 Fixed #538
* Thanks to @Artuvazro

Signed-off-by: nanakiwurtz <nanakiwurtz240@gmail.com>
2015-07-30 04:40:46 +07:00
aleos89
35cd68873b Merged with master 2015-06-26 10:36:40 -04:00
cristian gonzalez
bae01b5c42 Waiting room utils:
* waitingroomkick "<NPC object name>" , "<character name>"; Kicks one player, there was just a method for several players
    * getwaitingroomusers "<NPC object name>"; get the mumber of players inside a waitingroom and the rids.
2015-06-23 02:23:03 +02:00
aleos89
3d9c6e7763 2014 Client Support
* Implemented the Roulette Game feature.
* Implemented per-character sex change feature.
* More info: https://rathena.org/board/topic/102247-2014-client-support/
- Special thanks to HerculesWS/Hercules@239d480 for the base.
2015-06-19 14:07:34 -04:00
Cydh Ramdh
6ad4ed13d1 * Added script command showscript "<message>"{,<GID>}; by using clif_showscript.
* Removed hardcoded message that displayed clif_showscript for `transform` script, replaced its usage for item script by using `showscript`.
* Changed unittalk usage on `F_Cat_Hard_Biscuit` and `F_Rice_Weevil_Bug` function in quests_malangdo.txt.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-06-19 00:37:48 +07:00
aleos89
0696125b82 Script Engine Upgrade
* Upgraded the script engine variables to no longer be limited.
* Increased array limit from 127 to 2 billion.
* Improvement in overall speed and storage size.
* All variable types now support arrays.
- Merge from HerculesWS/Hercules@82b583b. Thanks to those who worked on it.
2015-06-11 10:44:13 -04:00
aleos89
730311e009 Script Command Adjustments and Additions
* Fixes #158 - Implemented 'getvar' script command to avoid blindly attaching players and messing up their NPC progress.
* Fixes #449 - Fixed 'unitskilluseid' and 'unitskillusepos' not casting skills that require stat info when the NPC's status wasn't loaded.
* Implemented 'getunittype' script command to return the object type of the given GID.
* Adjusted 'unitwalk' to support an Event Label which is executed when the object reaches the target.
* Added 'unitwalkto' when giving a target GID rather than coordinates. Also supports Event Labels.
- Thanks to @cydh.
2015-06-09 11:10:05 -04:00
Cydh Ramdh
290bd622f3 * Corrected 'rate' value in documentation for autobonuses.
* Follow up 9d389f4de42840b8d05244ad48c214100c7c7d05
  * Reduce the succes rate for 19020 combos and 18934. Because of misread the autobonus doc.
  * Completed bonus for 18934,Fox_Ears_Bell_Ribbon (the critical and long ranged attack bonus)
* Fixed item bonus for 18857,Curupira_Hat, somehow it was using 18856,W_King_Tiger_Doll_Hat effect.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-06-08 12:45:48 +07:00
Cydh Ramdh
177ea6c779 Follow ups & fix
* Follow up df2f850c, correcting `class_idx` usage that should be compared with `enum e_job` in `pc_calc_basesp` and also in `pc_calc_basehp`
* Follow up 308c4779, fixed typo fix
* Makes `instance_id()` doesn't show debug message when it return 0 for instance id

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-04-15 20:03:06 +07:00
Capuche
308c4779c8 Updated ACTIVEPATHSEARCH
- Changed "ACTIVEPATHSEARCH" to only work with real walls and not walls you can shoot through
* Seems the position lag for which I have implemented this no longer occurs on my client (was something changed?)
* Previous implementation prevented monsters from attacking you through shootable walls
* Special thanks to Michi for notifying me about this issue

Credit @Playtester
2015-04-15 13:02:20 +02:00
Cydh Ramdh
27ba6c5002 * Fixed #387
* Replacing 'rand()' leftwover with 'rnd()' of mt19937ar
* Cleaned up script commands related with item group: 'groupranditem', 'getrandgroupitem', 'getgroupitem'
* Corrected item scripts that are using 'getrandgroupitem'
* Updated script command and item group doc

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2015-04-09 20:54:01 +07:00
Capuche
dd3e7e1710 Corrected typo in adven_boards.txt thanks grammatic@aleos89
Update lvl4_weapon_quest.txt, Hercules 169b3faae19e23a303a094fe26e181a8c1b1c6c7
Fix delitem bug in Ep13.1 quest. Hercules 9d1853aebd3ff34ed7869a3b1188943624078b8e
Corrected Tree Roots Location Hercules ca9cd51e683d39c8a7f099a46747ff166d632230

Signed-off-by: Capuche <capucrath@gmail.com>
2015-04-06 23:24:12 +02:00
Cydh Ramdh
ef5fe8e4f1 Added optional param for 'char_id' in some script commands
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
2015-04-03 17:27:15 +07:00
Cydh Ramdh
1ab08b8f10 Another follow up 5f21afb2555d73bba219fd9fdb1d117c0e1950b1 (again)
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
2015-04-02 15:54:51 +07:00
Cydh Ramdh
0f137f3c67 Added command 'getattachedrid()' as discussion result with @aleos89
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
2015-04-01 22:37:14 +07:00
Cydh Ramdh
ee24f5c321 * Follow up 9d247d88c1f8a5d04a386ac6891726724ee226f9
* Typo

Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
2015-03-30 22:59:19 +07:00
Cydh Ramdh
7d929a06a3 NPC Market Shop support
* New shop script definition: `<map name>,<x>,<y>,<facing>%TAB%marketshop%TAB%<NPC Name>%TAB%<sprite id>,<itemid>:<price>:<quantity>{,<itemid>:<price>:<quantity>...}`
* Added script command to update shop NPC: 'npcshopupdate "<name>",<itemid>,<price>{,<stock>}'
* Added NPCMarketDB (DBMap) for market data persistance method.
* Added `market_table` definition for market table in conf/inter_athena.conf.
* Thank to @aleos89, @Lemongrass, @icxbb-xx, merged HerculesWS/Hercules@cf19b26.

NOTES:
* Minimum client needed 2013-12-23 (but this client has bugs there-and-there).
* There's new table, see `upgrade_20150327.sql`.
* Market shop doesn't support discount.
* Added items by script `npcshopitem` or `npchopadditem` will be assumed as persistance items, will be loaded on next script reload or server start even market_shop NPC does't list them (unless NPC is not exists, entries will be removed).

Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
2015-03-27 21:11:07 +07:00
aleos89
2dc38e77ca Follow up to 2cee5b6
* Updated setunitdata to recalculate the object's information and update the client immediately.
* For setunitdata, map name can also be passed in as a valid value instead of map ID.
* Added mapid2name script command.
* Added status_set_maxhp and status_set_maxsp functions.
* Updated documentation to reflect changes.
2015-03-26 11:47:36 -04:00