78 Commits

Author SHA1 Message Date
Lemongrass3110
4944491228
Added support for viewpointvalue command (#3754)
Additionally added a script command to update the player's camera.
Added a new atcommand camerainfo for this, which is limited to admins.

Credits to @4144 for finding /setcamera
2018-12-20 19:26:02 +01:00
Lemongrass3110
016d15b79a
Unified infinite tick usage (#3755)
Introducing a new constant INFINITE_TICK
Changed current usages in items, npcs and source to use the new and correct constant.
Replaced some invalid usages of INVALID_TIMER and replaced them with the new constant.
2018-12-18 17:46:56 +01:00
Aleos
c71ef92fb0
Refactored item bonuses to utilize C++ features (#3235)
* Fixes #996 and fixes #3152.
* Refactored MAX_PC_BONUS item bonuses from static arrays to vectors.
* Increased MAX_PC_BONUS to 50.
* Frees up memory from players that may not ever utilize all their static MAX_PC_BONUS item bonuses.
* Expanded bonus ResEff to not be restricted to SC_COMMON* statuses.
* Removed old ERS usages.
* Removed code redundancy and general cleanups.
Thanks to @Angelic234, @Atemo, @Lemongrass3110, and @Everade!
2018-11-28 21:50:43 -05:00
Aleos
24dca1117e
Corrected Reins of Mount interaction with hiding (#3621)
* Fixes #3614.
* Reins of Mount should not be applied to players who are in some sort of hidden state.
* Item delay is still applied.
Thanks to @admkakaroto and @cydh!
2018-11-16 09:17:42 -05:00
Aleos
404973f621
Corrected script command setunitdata HP/Max HP (#3669)
* Fixes #3668.
* Resolves an issue with adjusting HP/Max HP not properly applying it to the proper unit status.
Thanks to @Joao1905!
2018-11-13 09:33:58 -05:00
Aleos
7045d585e4
Added constants for Castle Data manipulation (#3531)
* Fixes #3530.
* Added constants for script commands getcastledata and setcastledata.
* Adjusted the guardian constants to adjust based on MAX_GUARDIANS define value.
* Updated scripts to reflect changes.
Thanks to @keitenai, @Atemo, and @Lemongrass3110!
2018-11-08 16:27:03 -05:00
Atemo
78edf851a0
Suggestion of implementation of is_party_leader and is_guild_leader script commands. (#3617)
* Implemented is_party_leader and is_guild_leader script commands.

Thanks to @cydh !
2018-11-06 16:28:09 +01:00
Lemongrass3110
c0793a8072
Adding LGTM to CI tools (#3636)
Thanks to @aleos89 for his help.
2018-10-29 21:25:36 +01:00
Jittapan Pluemsumran
84b4f09874 Added skill_duration mapflag. (#2171)
* Added skill_duration mapflag.
* This mapflag sets a skill unit time limit to n% of original duration.
* Implemented mapflags for Hunter's Traps in GVG, BG, and Novice Guild maps.

Signed-off-by: Cydh Ramdh <cydh@pservero.com>
2018-10-26 08:52:49 -04:00
Lemongrass3110
55acdb9863
Initial release of the guild storage log (#3365)
Thanks to @aleos89 and @Everade
2018-10-10 17:51:49 +02:00
Sader Fawall
10e7035beb Added script command getunits (#3389)
* Closes #3159.
* Adds script commands getunits, getmapunits, and getareaunits.
* Replacement for script commands getusers, getmapusers, getareausers. (In a future commit)
Thanks to @sader1992, @Atemo, and @anacondaqq!
2018-10-10 10:33:01 -04:00
Aleos
048de6c90a
Cleaned up map property functions (#3460)
* Follow up to da83e61.
* Stop players from attacking when disabling PvP/GvG from script commands.
* Removes redundancy.
2018-08-31 18:42:18 -04:00
Atemo
fd4f7ccd5c Suggestion: identifyall script command (#3419)
* Implemented script command identifyall.
Thanks to @secretdataz for suggestions!
2018-08-30 10:03:03 -04:00
Lemongrass3110
f42696bfd7 Added new quest info icons
Fixes #3374

Thanks to @Balferian
2018-08-18 00:08:20 +02:00
Atemo
3d8104d7fb
Suggestion: checkwall script command (#3393)
* Added checkwall script command
- Included the checkwall in npc folder
2018-08-14 20:58:49 +02:00
Sader Fawall
9cba66c22e Fix string case in inarray command script (#3401)
* Fixes #3400.
Thanks to @anacondaqq and @sader1992!
2018-08-14 12:26:29 -04:00
Aleos
4befcf747f
Corrected SECURE_NPCTIMEOUT behavior (#3394)
* Fixes #3381 and fixes #3391.
* Properly end NPC sessions when a player times out.
Thanks to @mazvi, @anacondaqq, and @gustavobrigo!
2018-08-11 16:13:24 -04:00
Aleos
48ae1a1e05
Cleaned up map storage type (#3384)
* Fixes #3369, fixes #3370, and fixes #3382.
* Converted maps storage container back to static array.
* Converted mapflag storage containers to unordered_map.
* Removed a lot of redundancy and recursive lookups.
* Fixed a couple short-circuit checks to help with performance.
* Fixed multiple instance creation/destruction issues.
* Fixed PK Mode attempting to set PvP on flags that are already active.
* Getting MF_RESTRICTED will return the map's zone value instead of the state.
* Converted mapflag macros to inline functions.
Thanks to @teededung, @lelouch22, @mazvi, @Lemongrass3110, and @cydh!
2018-08-10 13:52:07 -04:00
Aleos
584fcac43a Cleaned up map data storage (#3347)
Follow up to a942853.
Fixes #3336.
Moved map_data storage to std::map container.
Created map_getmapdata to obtain pointer to map_data.
Got rid of MAX_MAP_PER_SERVER define.
Resolved deletion of instances causing other instances to lose their intended map ID.
Refactored warp suggestions

Thanks to @teededung, @anacondaqq, @cydh and @Lemongrass3110!
2018-07-26 01:06:59 +02:00
Lemongrass3110
6b3f0717c7
Hotfix for issue 3277 (#3279)
Fixes #3277 

Thanks to @cydh and @aleos89
2018-07-24 22:55:17 +02:00
Aleos
9313922656
Further cleanup to mapflags (#3332)
* Follow up to a942853.
* Removed ADJUST_SKILL_DAMAGE define so that the mapflag is always enabled.
* Cleaned up atcommand mapinfo and skill_damage mapflag interaction.
* Cleaned up atcommand mapflag to not allow setting of special mapflags that require extra arguments (Please use script command setmapflag).
* Using script command setmapflag for MF_NOSAVE will default to SavePoint.
* Using script command setmapflag for MF_PVP_NIGHTMAREDROP will default to normal official drop values.
* Exported constants for skill_damage mapflag types.
Thanks to @ecdarreola, @cydh, and @Lemongrass3110!
2018-07-23 13:40:35 -04:00
Aleos
a942853d55
Cleaned up the mapflag system (#2943)
* Created setter and getter functions.
* Adjusted all calls to use these functions.
* Converted mapflags to C++ map container.
* Converted drop_list to vector.
* Converted skill_damage ERS into vector and increased limit from UINT8 to UINT16.
* Cleaned up several functions to be more dynamic to reduce redundancy that was all over the place.
* Renamed nosumstarmiracle to nosunmoonstarmiracle.
* Adjusted skill_damage mapflag to use proper defined constants.
* Refactored map index into a vector.
Thanks to @Lemongrass3110 for a lot of help and @secretdataz!
2018-07-18 20:00:33 -04:00
Lemongrass3110
c4d7dc76d3
Hid timer function parameters in a macro (#3311) 2018-07-15 23:17:15 +02:00
Sader Fawall
500cfdc41f Missing returns for inarray and countinarray (#3295)
Added some return cases if empty arrays are given to these two commands.

Thanks to @sader1992
2018-07-07 13:46:14 +02:00
Lemongrass3110
fe7c0a78ec
Refactored roulette system (#3271)
Fixes #2887 - thanks to @Everade
Fixes #3292 - thanks to @admkakaroto

Added a script command to open the roulette window from server side.
Added support for clients >= 2018-05-16
Fixed losing behavior for roulette
Enabled roulette system by default
Added a server side delay
Added missing sql log enum value 'Y'

Thanks to @Everade, @admkakaroto, @V0rr, @ecdarreola, @Haikenz and everyone else who contributed to this.
2018-07-06 22:39:58 +02:00
Lemongrass3110
3faf700443
Added possibility to log without attached player (#3260)
Fixes #2268

Thanks to @Akkarinage
2018-07-02 11:45:55 +02:00
Lemongrass3110
b3643bfe45
Added a 'force' option to attachrid (#3261)
Fixes #1763
2018-07-01 22:28:56 +02:00
Lemongrass3110
23f7b945ec
Fixed a map-server crash from getitem3 (#3122)
Fixes #3121

Wrong usage by supplying a non-array variable.
Using a non-server variable without having a player attached.

Thanks to @Everade
2018-06-23 18:49:38 +02:00
Aleos
11b42569fc
Synchronized source file headers (#3212)
* Alphabetically sorted includes.
* Updated copyright and license text to match across all files.
* Removed pragma once define in header files in lieu of ifdef guards.
2018-06-20 18:08:30 -04:00
Lemongrass3110
801d3ed942
Moved common, config and mapcache to C++ (#3200)
Dropped BETA_THREAD_TEST and everything around it
Dropped mt19937
Replaced msinttypes with cinttypes
Removed IRC link and updated README name
2018-06-14 21:51:58 +02:00
Lemongrass3110
dd60f4c47e
Added 2 new parameters for getpetinfo (#3164)
Fixed inter-server handling for creation of pets that are not incubated.

Thanks to @Everade for his idea.
2018-05-27 22:52:08 +02:00
Sader Fawall
151c8476af inarray script commands (#3071)
Thanks to @anacondaqq, @Lemongrass3110, @Jeybla, @secretdataz, @aleos89, @Atemo and @hurtsky for reviewing and testing.
2018-05-27 22:51:37 +02:00
Aleos
87e7e8891b
Added missing Imperial Set Combos (#3151)
* Fixes #3031.
* Added missing Royal Guard Necklace and Imperial Glove.
* Added bSkillDelay bonus which increases delay of skill sk by t milliseconds.
Thanks to @iubantot and @Secret!
2018-05-26 12:50:39 -04:00
Lemongrass3110
55bf142ab8 Follow up to d13d6a6
Thanks to @RadianFord
2018-04-20 22:53:09 +02:00
Lemongrass3110
d13d6a6e19
Changed SI_ enum to the official EFST_ enum (#2995) 2018-04-20 18:24:20 +02:00
Lemongrass3110
5b13dc7009
Added script command mail (#3043) 2018-04-12 00:46:01 +02:00
Lemongrass3110
cc63bb594f Follow up to 07e2bf0
Fixed a missing switch case.

Thanks to @teededung and @RadianFord.
2018-04-11 14:50:35 +02:00
Jittapan Pluemsumran
e2b9e42b7d Cleaned up custom battleground scripts (#3025)
Added a warning to script command delwall
2018-04-11 11:22:29 +02:00
Jittapan Pluemsumran
07e2bf09af Made the second parameter for bonus script command optional (#2902)
* Made the second parameter for bonus script command optional

* Updated item scripts to reflect the bonus command change
2018-04-10 19:38:56 +02:00
Lemongrass3110
25f2626cf8 Removed a stack push from getvar (#2912)
Fixes #2891.
Thanks to @sader1992!
2018-04-10 12:27:48 -04:00
Atemo
cdae404e6a Updated getunitdata / setunitdata (#3029)
Added the possibility to retrieve / change the current target id of a Mob, Homunculus, Mercenary and Elemental through getunitdata / setunitdata
2018-04-10 00:23:22 +02:00
Sader Fawall
1390930ca5 HotFix getinventorylist (#3033)
* Follow up to f07a1c4.
* Expanded the char array.
Thanks to @RadianFord and @sader1992!
2018-04-03 22:47:46 -04:00
Aleos
f07a1c4b4d
Added Random Option item data to getinventorylist (#3030)
* Closes #3021.
* Added Random Option item data to script command getinventorylist return values.
Thanks to @Yuchinin!
2018-04-03 10:40:29 -04:00
Jittapan Pluemsumran
41ea1531bc
Prevent unloadnpc script command to unload the invoking NPC. (#3000)
* Prevent unloadnpc script command to unload the invoking NPC.
Addressed #2999
2018-03-20 21:56:11 +07:00
s8nozieb
39ba3d600b Fixed typo in BUILDIN_FUNC(sleep) (#2949)
[ci skip]
2018-03-04 13:02:26 +07:00
Sader Fawall
ead017b396 Clear script command(#2840) 2018-02-18 17:47:41 +01:00
Lemongrass3110
132feeb621
Made mercenary db dynamic (#2883)
Removed hard limit of the mercenary database
Cleaned up the hard coded duplicated logic
Turned hard coded mercenary ids into constants
2018-02-18 17:15:09 +01:00
Jittapan Pluemsumran
bfb6972c59 Implemented getequiptradability script command (#2750)
Thanks to @aleos89 @anacondaqq @Lemongrass3110
2018-01-03 21:51:38 +01:00
Cydh Ramdh
32950ecead
Updated Item Group features (#2692)
* Added config to hide last chars of player's name `broadcast_hide_name` and its default value is 2.
* Fixed `getgroupitem` that should give unidentified item for equipment types.
* Added optional param for `getgroupitem` and `getrandgroupitem` to always give player identified item, ignores the `itemdb_isidentified`'s check.
* Thanks to @aleos89 @Lemongrass3110
2018-01-02 12:55:52 +07:00
Lemongrass3110
fb966a12e0
Turned pet db into a dynamic map (#2727)
Thanks to @Jeybla, @lighta and @aleos89
2018-01-01 22:57:47 +01:00