Fix bugreport:8418 (possible mapcrash from custom instance script)
Fix bugreport:8439 (pc_bonus_item_drop typos) thx to Baalberith
Fix some errors detected by cppcheck
upd install.sh (leftover of svn and wrong simlink)
* Fixed an operator check for WE_MALE and WE_FEMALE. Thanks Baalberith.
Optimizations
* Fixed a possible null pointer dereference in Spirit Ball check, Change Cart check, WE_BABY, MH_PYROCLASTIC, and MH_LIGHT_OF_REGENE.
* Fixed a reassigned value being reset before being checked.
* Fixed a homunculus expression always being false because of prior check.
* Fixed sprintf specifier output trying to display int value when return value is unsigned int.
* Fixed a redundant check for when monster's HP is less than 0 when HP is declared as an unsigned int.
* Fixed a redundant check for when uAccLen or uTokenLen are less then 0 when both are declared as unsigned int.
* Various other clean ups.
"F_GetPlural" now works for most item/mob cases, but still does not detect inputs that are already pluralized.
- For formats "... of|in|on ..." (ex. Piece of Cake), preceding word will be pluralized (ex. Pieces).
- Added some additional checks to prevent common errors.
Signed-off-by: Euphy <euphy.raliel@rathena.org>
* Added format string to "F_InsertPlural" for added flexibility.
* Added more checks to "F_GetPlural" for better handling of multi-word arguments (e.g. items).
* Updated some more scripts with new functions.
Some misc. cleanup of constants in scripts.
Signed-off-by: Euphy <euphy.raliel@rathena.org>
Also dropped folder db/import, which should be user-created.
[Follow-up to ff29c23, credits @Lemongrass3110.]
Signed-off-by: Euphy <euphy.raliel@rathena.org>
* Added the following functions:
- "F_GetPlural" (returns plural of noun) / "F_InsertPlural" (returns plural if arg != 1) [credits: EnglishClub for formation rules]
- "F_InsertArticle" (returns 'a' or 'an' preceding word)
- "F_InsertComma" (formats number with commas)
- "F_GetNumSuffix" (formats number with '-st', '-nd', '-rd', or '-th' suffix)
* Added and removed new functions where necessary. (incomplete)
* Added new types to "F_GetArmorType" function, and weapons will now pass to "F_GetWeaponType".
* Reformatted comments.
Other changes:
* Removed some garbage text from scripts.
* Slight edits to custom warper script.
Signed-off-by: Euphy <euphy.raliel@rathena.org>
Add db/import-tmpl/ and add all file that could currently be
overwritten, (please add note if a db is missing)
db/import folder is created by "make import" just like conf/import and
msg_conff/import, (didn't found the visual equivalent)
* Follow up 96443cd, seems like for final MaxSP use round() instead floor(). Removed unecessary floor() (Isn't by default, rounding from double to int will be rounded down like floor()?)
* A little clean up on skill_co_copy()
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
Add folder import/ into db/ to load all customs
This folder is meant to hold all the customs file you wish override rA
one.
(In short it work like conf import)
related to tid:90199
Follow up dae81222 (AEGIS class system) fix out of bound issue for
array.
(didn't check the x_ALL option system yet)
Follow up 7a9aa7fb Fix possible mapcrash due to offline player
Follow up 12007fef Fix some invalide string check and remove the
reverted sqlfiles
* Follow up 7a9aa7f, enum errors
* Follow up 12007fe, function return type error
* Follow up dae8122, 'skill' to 'skill_learnlv'?
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
* Fixed WE_MALE and WE_FEMALE up to You to not consume HP/SP when it's below 10%. (bugreport:3546)
* Fixed WE_CALLPARTNER, WE_CALLPARENT, and WE_CALLBABY to not recall target if they are autotrading. (bugreport:2479)
* Fixed WE_BABY not checking for parents if they are in the same party and in the area. (bugreport:2518)
* Fixed Dragon Breath - Water not requiring a dragon. (bugreport:8237)
* Added a new config 'char_del_option' to set whether email or birthdate should be used for deleting characters. (bugreport:8240)
* Follow up to 9a5a6b9. Fixed a missing define check for 2013 clients when deleting a character. (bugreport:8399)
* Fixed Weapon Refining to use clif_upgrademessage. (bugreport:2135)
* Fixed script command 'prompt' not ending script state when player selects Cancel from menu. (bugreport:7932)
* Fixed nomineeffect display on GvG enabled maps. (bugreport:7754)
Others
* All items, except for Cash items, can no longer be used when storage is open.
* Defined constants for a lot of item and monster IDs used throughout the source.
* Follow up to 0f2dd7f. Corrected a change to the wrong hostname array.
Fix many typo and optimisation found by :
http://rathena.org/cppreport/index.html
Fix multiple unsafe scanf of string
Fix multiple battle wrong check (elemental bonus)
Fix camouflage defense reduction and cap expiato def reduction
Fix geoip leak
Upd few documentation in doxygen style
Fix path working directory issue to start servers
(now you won't need to be in maindir to launch server)
* Renamed job_maxhpsp_db to job_basehpsp_db.txt and add new values according to the base HP/SP calculation. Ref: http://irowiki.org/wiki/Max_HP, http://irowiki.org/wiki/Max_SP
* Updated the Max HP/SP calculation. Ref: http://irowiki.org/wiki/Max_HP, http://irowiki.org/wiki/Max_SP
* Changed Max Level for 3rd classes become 175/60. Ref: http://forums.irowiki.org/showpost.php?p=1344057&postcount=217
* Changed Max Parameters for 3rd classes from 125 to 130. Ref: http://forums.irowiki.org/showpost.php?p=1344057&postcount=217
* Changed Max Parameters for Baby 3rd Classes from 107 to 118: Ref: http://forums.irowiki.org/showpost.php?p=1344057&postcount=217
* Oboro/Kagerou and Rebellion, are 160/50 and max param is still 125
* Added and separated configs on conf/player.conf, becomes:
-- max_parameter,
-- max_trans_parameter,
-- max_third_parameter,
-- max_third_trans_parameter,
-- max_baby_parameter,
-- max_baby_third_parameter,
-- max_extended_parameter,
* Added new db file job_param_db.txt for RE and PRE-RE, which allow you to modify the max param for each job
* HP_SP_TABLES on core.h is disable by default
NOTE:
* Still need official value to add bonus status for 3rd classes from Job Level 50 to 60
* Still need official value for total status point from Base Level up to 175 also the EXP values
* I hope the calculations results are closer with Max HP/SP values with official servers
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
Fix pneuma display for pre-re mode
Add char_maintenance mode to check trought gm_allow_group as a minimum
groupid to enter. (thx to SuperHulk)
Fix UB warning on bonus_script check by type
Properly initialize combo_idx check
* Added missing config on inter_athena.conf for MySQL database (use_sql_db: yes)
* Please upgrade your MySQL database with upgrade_20131229.sql
Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
Follow up hash:0f2dd7f (adding support to map<=>client to allow longer
storagelist)
Fix most of : [Error]: WFIFOSET: Maximum write buffer size for client
connection 7 exceeded, most likely caused by packet 0x0996 (len=11932,
ip=127.0.140733193388032.1). Still remain some if you openup the list
like 5time/s, see tid:90541