Commit graph

6804 commits

Author SHA1 Message Date
Piotr Hałaczkiewicz
4a4751563c Add console command to update database to bcrypt
Add doc about user passwords.
Update config settings related to passwords.
2013-08-02 10:44:28 +02:00
Haru
4b887afab3 Improved timer_cputimer_* crossfplatform support
It will now use the first available of:
- QueryPerformanceCounter (WIN32)
- clock_gettime (glibc)
- mach_absolute_time (Mac OS X)
- clock (fallback)

Modified configure script to detect which function is available

Signed-off-by: Haru <haru@dotalux.com>
2013-07-31 11:39:03 +02:00
Piotr Hałaczkiewicz
7b1e0a234f Updated bcrypt benchmark console command
Added portable functions for measuring CPU time (`clock()` in Windows returns wall-clock time)
Changed bcrypt benchmarking to exclude random salt generation from measurement.
2013-07-30 07:17:16 +02:00
Haru
a1ff5b3225 Fixed bcrypt x86 build
Signed-off-by: Haru <haru@dotalux.com>
2013-07-28 17:28:08 +02:00
Haru
1cecc15dd2 Updated GNU Make build scripts for bcrypt support
Also updated .gitignore with the related changes

Signed-off-by: Haru <haru@dotalux.com>
2013-07-28 16:26:58 +02:00
Piotr Hałaczkiewicz
7e01c23c5c Added define for MD5_HASHSIZE 2013-07-28 16:04:18 +02:00
Piotr Hałaczkiewicz
3286c2f971 Initial bcrypt support.
Uses Openwall's bcrypt implementation (http://www.openwall.com/crypt/).
Added bcrypt wrapper based on http://github.com/rg3/bcrypt/
Modified configuration setting related to passwords.
Updated VC10 build.
2013-07-28 13:58:13 +02:00
Piotr Hałaczkiewicz
e9e8914ebf Fixed typo in SC__STRIPACCESSARY.
Fixed `SC__STRIPACCESSARY` checking for equip index instead of equip
position. Fixes #72
2013-07-25 22:29:07 +02:00
Haru
078bbbada6 Fixed SA_DISPELL failing outside PvP against party
- Follow-up to a4802eae
- Fixes bugreport #7572
  http://hercules.ws/board/tracker/issue-7572-dispell-2
- SA_DISPELL would fail outside PvP if caster and target are in the same
  party AND in the same guild at the same time.
- Special thanks for kyeme (bugreport), Xgear (review.)

Signed-off-by: Haru <haru@dotalux.com>
2013-07-24 04:15:17 +02:00
Haruna
356a3ab31d Merge pull request #65 from piotrhalaczkiewicz/pathfinding
Pathfinding code cleanup.
2013-07-23 09:26:01 -07:00
Piotr Hałaczkiewicz
78028c8b65 Pathfinding code cleanup.
Now uses binary heap defined in `db.h`.
Walk requests now use A* (hard) pathfinding only to match game client
behavior.
Added defines for movement cost.
Added some documentation & comments.
2013-07-23 18:04:17 +02:00
Piotr Hałaczkiewicz
86f70d9f4f Refactored map_foreach* functions.
Removed a lot of duplicated code.
Added some documentation & comments.
2013-07-23 16:44:24 +02:00
Flipp
056c181e1c Merge pull request #64 from piotrhalaczkiewicz/master
Binary heap fix & improvement.
2013-07-22 14:20:58 -07:00
Piotr Hałaczkiewicz
c0c254f14d Binary heap fix & improvement.
Fixed a bug when removing last element of binary heap (its parent would
be removed instead if it had the same value).
Binary heap now allows custom swapper function/macro. Added `swap_ptr`
macro to swap two pointers in place (`swap` is not suitable for
pointers). This allows to store pointers in binary heap.
2013-07-22 22:50:45 +02:00
shennetsind
0090e0303d Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-22 11:41:31 -03:00
shennetsind
00dd6a4973 Fixed Bug #7564
Trickdead will now go away upon job changing to a non-novice class, pre-existing non-novice characters with the trickdead skill granted will automatically be fixed on login (unless the skill was granted via flag 3)
Special Thanks to bgamez23
http://hercules.ws/board/tracker/issue-7564-platinum-skill-is-not-remove-right-after-i-change-job/

Signed-off-by: shennetsind <ind@henn.et>
2013-07-22 11:40:48 -03:00
Haru
a71a77303f Fixed the homun_skill_tree parser.
- Follow-up to efbd5d0 (related: issue #4337)
- Now all the fields are read as intended.

Signed-off-by: Haru <haru@dotalux.com>
2013-07-22 03:56:59 +02:00
shennetsind
68fb17f516 Fixed Bug #7526
Skill from items with instantaneous casting are no longer affected by magic power
http://hercules.ws/board/tracker/issue-7526-item-skill-error/

Signed-off-by: shennetsind <ind@henn.et>
2013-07-21 16:24:57 -03:00
shennetsind
dede3fb8bd Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-21 15:58:01 -03:00
shennetsind
b2e12fbc71 For Bug #7542
Attempting to open boxes or packages while 90% overweight will fail and result in a error message.
http://hercules.ws/board/tracker/issue-7542-bug-when-weight-90/

Signed-off-by: shennetsind <ind@henn.et>
2013-07-21 15:57:33 -03:00
Haru
d627f8f3cd Changed CC to a Makefile variable
- This allows the user to override the compiler at each make invocation
  (i.e. to run scripts to generate .clang_complete for
  https://github.com/Rip-Rip/clang_complete )
- Updated .gitignore with a few platform-dependent entries

Signed-off-by: Haru <haru@dotalux.com>
2013-07-21 20:26:46 +02:00
shennetsind
2548a8cee4 Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-21 14:34:35 -03:00
shennetsind
d680d0ccd5 Fixed Bug #7520
Added code to ensure 1st/2nd tabs are meeting the conditions; Special Thanks to Haruna, ToiletMaster
http://hercules.ws/board/tracker/issue-7520-skill-point-error/
Also - Follow up 9bcb142396
extending it to cached item packages.

Signed-off-by: shennetsind <ind@henn.et>
2013-07-21 14:34:08 -03:00
Haru
5f7320cda3 Fixed various unit* script commands to work with NPCs (issue #7548)
http://hercules.ws/board/tracker/issue-7548-unitwalk-do-not-work/
Follow-up to 20bdc01.
Thanks to Ind for his support and suggestions.

Signed-off-by: Haru <haru@dotalux.com>
2013-07-21 18:45:31 +02:00
shennetsind
9bcb142396 HCache & SQL Update Checker minor change
Files loaded by HCache now display a green C to distinguish whether it was loaded from cache or not
Fixed a typo in the SQL Update Checker.

Signed-off-by: shennetsind <ind@henn.et>
2013-07-21 11:46:32 -03:00
shennetsind
e3fd7cc888 Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-21 11:34:35 -03:00
shennetsind
a76709480b Fixed Bug #7547
str_data[].val was uninitialised and thus using garbage memory on compilers that don't automatically initialize
http://hercules.ws/board/tracker/issue-7547-notice-conflicting-itemscript-var/
Also updated guild aura sc_config options (special thanks to kyeme!)

Signed-off-by: shennetsind <ind@henn.et>
2013-07-21 11:33:43 -03:00
malufett
760faf6437 Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-21 21:07:49 +08:00
malufett
8b00d9bd07 Fixed Bug#7558
-Where 'bLongAtkDef' is not working properly with physical attack.

Fixed Bug#7530
-Where Masquerades affect boss monsters.

Signed-off-by: malufett <malufett.eat.my.binaries@gmail.com>
2013-07-21 21:06:43 +08:00
Kisuka
fabedc8b22 Changed npcdb_checkid to use MAX_NPC_CLASS2_START and END. 2013-07-18 17:41:55 -07:00
shennetsind
e26c9504e8 Fixed Bug #7525
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 586c0f7983 sc_config.txt update

Signed-off-by: shennetsind <ind@henn.et>
2013-07-18 05:34:34 -03:00
shennetsind
586c0f7983 Fixed guild aura not going away on guild-break/expell
Also modified sd->state.gmaster_flag from struct to a 'unsigned int : 1;' flag as sd->guild already stores the pointer and was thus a duplicate.
Special Thanks to Haru, Xgear

Signed-off-by: shennetsind <ind@henn.et>
2013-07-18 00:02:34 -03:00
Haru
857e4fb58b Added missing initialization of some functions in the homunculus interface
- Fixes issue #7536 (thanks to jTynne for the report)
http://hercules.ws/board/tracker/issue-7536-map-crash-july-15th/
- Minor corrections to the other interfaces as well (reordered
  initialization to follow the definitions, removed duplicate entry in
  the skill interface initialization, commented out some unused entries)

Signed-off-by: Haru <haru@dotalux.com>
2013-07-17 05:29:19 +02:00
Haru
f530cfe173 Packets and packet keys update with the info provided by Shakto
- Added packets for 2013-06-12Ragexe, 2013-06-18Ragexe,
  2013-06-26Ragexe, 2013-07-03Ragexe
- Added packetKeys for 2013-06-26Ragexe, 2013-07-03Ragexe
- Thanks to Shakto for always providing us with the data, OnNplay for
  the the update reminder.

Signed-off-by: Haru <haru@dotalux.com>
2013-07-16 20:53:24 +02:00
Haru
e92b006b51 Allow higher level GMs to bypass a player's /exall when whispering
- Follow-up to 3d0fba0
- Fixes the remaining part of bug #7463:
http://hercules.ws/board/tracker/issue-7463-gm-cant-whsiper-wheb-player-do-exall

Signed-off-by: Haru <haru@dotalux.com>
2013-07-15 15:07:03 +02:00
Haru
0b63deefd2 Removed the now unused optional 3rd parameter from removemapflag
- The parameter was only used in combination with MF_RESTRICTED, now
  superseded by MF_ZONE
- Follow-up b08910e8, 90f117f6

Signed-off-by: Haru <haru@dotalux.com>
2013-07-14 18:22:31 +02:00
Haru
75359a9cd5 Makefile error corrections and minor tweaks
- Fixed some variable names incorrectly entered as literals in target
  names
- This fixes a build failure when trying to build any specific
  sub-project directly from src/*/
- Removed an old svn-related command from the 'import' recipe
- This fixes the build failures when trying to run 'make tools' right
  after 'make clean'
- Removed duplicate entries in the 'clean' recipe for map and login
  servers

Signed-off-by: Haru <haru@dotalux.com>
2013-07-14 17:26:28 +02:00
Haruna
a3becdfb5d Merge pull request #58 from piotrhalaczkiewicz/master
Fixed crash when unloading NPC (bug #7517)
2013-07-13 08:22:01 -07:00
Piotr Hałaczkiewicz
efbc04ac76 Fixed crash when unloading NPC (bug #7517)
Follow-up to 6e0da18920
Bug report:
http://hercules.ws/board/tracker/issue-7517-yet-another-map-server-cr/

Duplicate events are now skipped instead of overwriting existing ones.
2013-07-13 13:01:47 +02:00
Haru
8efd165686 Fixed an issue with long hostnames/nicknames in the IRC Bridge
This prevents nickname truncation and other possibly ill side-effects in
case the source string for a message is in the form:
aNickname!~ident@an.irc.user.with.a.very.long.hostname_________

Signed-off-by: Haru <haru@dotalux.com>
2013-07-11 19:54:58 +02:00
shennetsind
0a1c06b267 Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-11 14:32:05 -03:00
shennetsind
e3761a81ba Fix to Bug #7434
Fixing a ancient bug where placing a item from inventory to cart when cart is full would render such item un-clickable, same for when doing so from storage to cart.
Special Thanks to Yommy for all the data, jTynne for bringing this up.
http://hercules.ws/board/tracker/issue-7434-weightinability-to-click-item-issue/

Signed-off-by: shennetsind <ind@henn.et>
2013-07-11 14:30:58 -03:00
shennetsind
8b797c5b00 Merge pull request #56 from piotrhalaczkiewicz/master
Improved NPC event processing.
2013-07-11 09:50:13 -07:00
Matheus Macabu
8cd740d2c7 Fixed a little type (follow up to 94d75f8), also defaulted to 0 mute system. 2013-07-11 13:20:44 -03:00
malufett
94d75f867a Updated some aegis(item, monster, resetstate & resetskill) command to work properly in Hercules. 2013-07-11 23:21:51 +08:00
Piotr Hałaczkiewicz
6e0da18920 Improved NPC event processing.
Executing unique events (NPC::Label) no longer loops through all events.
Executing global event labels (::Label) also no longer loops through all
events. Global event labels are now mapped to list of only relevant NPC
events.
Cleaned up code related to clearing npc path db.
2013-07-11 17:01:47 +02:00
malufett
5de6aabb0a Partial Fixed Bug#7462
-Burning(Eff_Burning) is now supported with 'bonus2 bAddEff' script command.
2013-07-11 21:19:35 +08:00
malufett
444835e777 Fixed Bug#7498
-Where RE equip atk doesn't properly update status window and negative equip atk should now affect atk.

Signed-off-by: malufett <malufett.eat.my.binaries@gmail.com>
2013-07-11 20:56:11 +08:00
shennetsind
1708b62c12 Merge branch 'master' of https://github.com/HerculesWS/Hercules 2013-07-10 23:20:26 -03:00
shennetsind
ba16e1a787 Fix to skill_blockpc_end
Duplicate indexes would not be cleared, causing array to gradually increase in size.
Thanks to ToiletMaster for providing extra information.

Signed-off-by: shennetsind <ind@henn.et>
2013-07-10 23:01:07 -03:00