From fd700a7812ebcc9219d2dd820f2f8981b69e6aae Mon Sep 17 00:00:00 2001 From: Cahyadi Ramadhan Togihon Date: Fri, 22 Nov 2013 13:23:29 +0700 Subject: [PATCH 1/7] Added support for MSVS 2013, thank solid2005 for all files (http://rathena.org/board/tracker/issue-8274-compilevisual-studio-2012-to-2013/) Signed-off-by: Cahyadi Ramadhan Togihon --- .gitignore | 7 + rAthena-13.sln | 40 ++ src/common/atomic.h | 91 +++-- vcproj-13/char-server_sql.vcxproj | 221 ++++++++++ vcproj-13/char-server_sql.vcxproj.filters | 259 ++++++++++++ vcproj-13/login-server_sql.vcxproj | 209 ++++++++++ vcproj-13/login-server_sql.vcxproj.filters | 211 ++++++++++ vcproj-13/map-server_sql.vcxproj | 303 ++++++++++++++ vcproj-13/map-server_sql.vcxproj.filters | 449 +++++++++++++++++++++ vcproj-13/mapcache.vcxproj | 155 +++++++ vcproj-13/mapcache.vcxproj.filters | 70 ++++ 11 files changed, 1972 insertions(+), 43 deletions(-) create mode 100644 rAthena-13.sln create mode 100644 vcproj-13/char-server_sql.vcxproj create mode 100644 vcproj-13/char-server_sql.vcxproj.filters create mode 100644 vcproj-13/login-server_sql.vcxproj create mode 100644 vcproj-13/login-server_sql.vcxproj.filters create mode 100644 vcproj-13/map-server_sql.vcxproj create mode 100644 vcproj-13/map-server_sql.vcxproj.filters create mode 100644 vcproj-13/mapcache.vcxproj create mode 100644 vcproj-13/mapcache.vcxproj.filters diff --git a/.gitignore b/.gitignore index 8c735b6b14..fd8e78785c 100644 --- a/.gitignore +++ b/.gitignore @@ -87,6 +87,13 @@ /tools/*.ilk /tools/*.pdb +# /vcproj-13/ +/vcproj-13/char-server_sql +/vcproj-13/login-server_sql +/vcproj-13/mapcache +/vcproj-13/map-server_sql +/vcproj-13/*.user + # /vcproj-12/ /vcproj-12/char-server_sql /vcproj-12/login-server_sql diff --git a/rAthena-13.sln b/rAthena-13.sln new file mode 100644 index 0000000000..7fe37e4f8c --- /dev/null +++ b/rAthena-13.sln @@ -0,0 +1,40 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 2013 +VisualStudioVersion = 12.0.21005.1 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "char-server_sql", "vcproj-13\char-server_sql.vcxproj", "{D356871D-58E1-450B-967A-E4E9646175AF}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "login-server_sql", "vcproj-13\login-server_sql.vcxproj", "{D356871D-58E1-450B-967A-E5E9646175AF}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "map-server_sql", "vcproj-13\map-server_sql.vcxproj", "{D356871D-58E1-450B-967A-E6E9646175AF}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mapcache", "vcproj-13\mapcache.vcxproj", "{D356871D-58E1-450B-967A-E7E9646175AF}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {D356871D-58E1-450B-967A-E4E9646175AF}.Debug|Win32.ActiveCfg = Debug|Win32 + {D356871D-58E1-450B-967A-E4E9646175AF}.Debug|Win32.Build.0 = Debug|Win32 + {D356871D-58E1-450B-967A-E4E9646175AF}.Release|Win32.ActiveCfg = Release|Win32 + {D356871D-58E1-450B-967A-E4E9646175AF}.Release|Win32.Build.0 = Release|Win32 + {D356871D-58E1-450B-967A-E5E9646175AF}.Debug|Win32.ActiveCfg = Debug|Win32 + {D356871D-58E1-450B-967A-E5E9646175AF}.Debug|Win32.Build.0 = Debug|Win32 + {D356871D-58E1-450B-967A-E5E9646175AF}.Release|Win32.ActiveCfg = Release|Win32 + {D356871D-58E1-450B-967A-E5E9646175AF}.Release|Win32.Build.0 = Release|Win32 + {D356871D-58E1-450B-967A-E6E9646175AF}.Debug|Win32.ActiveCfg = Debug|Win32 + {D356871D-58E1-450B-967A-E6E9646175AF}.Debug|Win32.Build.0 = Debug|Win32 + {D356871D-58E1-450B-967A-E6E9646175AF}.Release|Win32.ActiveCfg = Release|Win32 + {D356871D-58E1-450B-967A-E6E9646175AF}.Release|Win32.Build.0 = Release|Win32 + {D356871D-58E1-450B-967A-E7E9646175AF}.Debug|Win32.ActiveCfg = Debug|Win32 + {D356871D-58E1-450B-967A-E7E9646175AF}.Debug|Win32.Build.0 = Debug|Win32 + {D356871D-58E1-450B-967A-E7E9646175AF}.Release|Win32.ActiveCfg = Release|Win32 + {D356871D-58E1-450B-967A-E7E9646175AF}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/src/common/atomic.h b/src/common/atomic.h index b1a4bda927..89f0b910f9 100644 --- a/src/common/atomic.h +++ b/src/common/atomic.h @@ -8,9 +8,9 @@ // (Interlocked CompareExchange, Add .. and so on ..) // // Implementation varies / depends on: -// - Architecture -// - Compiler -// - Operating System +// - Architecture +// - Compiler +// - Operating System // // our Abstraction is fully API-Compatible to Microsofts implementation @ NT5.0+ // @@ -19,67 +19,72 @@ #if defined(_MSC_VER) #include "../common/winapi.h" +// This checks if C/C++ Compiler Version is 18.00 +#if _MSC_VER < 1800 + #if !defined(_M_X64) // When compiling for windows 32bit, the 8byte interlocked operations are not provided by microsoft // (because they need at least i586 so its not generic enough.. ... ) forceinline int64 InterlockedCompareExchange64(volatile int64 *dest, int64 exch, int64 _cmp){ - _asm{ - lea esi,_cmp; - lea edi,exch; + _asm{ + lea esi,_cmp; + lea edi,exch; - mov eax,[esi]; - mov edx,4[esi]; - mov ebx,[edi]; - mov ecx,4[edi]; - mov esi,dest; - - lock CMPXCHG8B [esi]; - } + mov eax,[esi]; + mov edx,4[esi]; + mov ebx,[edi]; + mov ecx,4[edi]; + mov esi,dest; + + lock CMPXCHG8B [esi]; + } } forceinline volatile int64 InterlockedIncrement64(volatile int64 *addend){ - __int64 old; - do{ - old = *addend; - }while(InterlockedCompareExchange64(addend, (old+1), old) != old); + __int64 old; + do{ + old = *addend; + }while(InterlockedCompareExchange64(addend, (old+1), old) != old); - return (old + 1); + return (old + 1); } forceinline volatile int64 InterlockedDecrement64(volatile int64 *addend){ - __int64 old; + __int64 old; - do{ - old = *addend; - }while(InterlockedCompareExchange64(addend, (old-1), old) != old); + do{ + old = *addend; + }while(InterlockedCompareExchange64(addend, (old-1), old) != old); - return (old - 1); + return (old - 1); } forceinline volatile int64 InterlockedExchangeAdd64(volatile int64 *addend, int64 increment){ - __int64 old; + __int64 old; - do{ - old = *addend; - }while(InterlockedCompareExchange64(addend, (old + increment), old) != old); + do{ + old = *addend; + }while(InterlockedCompareExchange64(addend, (old + increment), old) != old); - return old; + return old; } forceinline volatile int64 InterlockedExchange64(volatile int64 *target, int64 val){ - __int64 old; - do{ - old = *target; - }while(InterlockedCompareExchange64(target, val, old) != old); + __int64 old; + do{ + old = *target; + }while(InterlockedCompareExchange64(target, val, old) != old); - return old; + return old; } #endif //endif 32bit windows +#endif //endif _msc_ver check + #elif defined(__GNUC__) #if !defined(__x86_64__) && !defined(__i386__) @@ -87,17 +92,17 @@ forceinline volatile int64 InterlockedExchange64(volatile int64 *target, int64 v #endif static forceinline int64 InterlockedExchangeAdd64(volatile int64 *addend, int64 increment){ - return __sync_fetch_and_add(addend, increment); + return __sync_fetch_and_add(addend, increment); }//end: InterlockedExchangeAdd64() static forceinline int32 InterlockedExchangeAdd(volatile int32 *addend, int32 increment){ - return __sync_fetch_and_add(addend, increment); + return __sync_fetch_and_add(addend, increment); }//end: InterlockedExchangeAdd() static forceinline int64 InterlockedIncrement64(volatile int64 *addend){ - return __sync_add_and_fetch(addend, 1); + return __sync_add_and_fetch(addend, 1); }//end: InterlockedIncrement64() @@ -107,27 +112,27 @@ static forceinline int32 InterlockedIncrement(volatile int32 *addend){ static forceinline int64 InterlockedDecrement64(volatile int64 *addend){ - return __sync_sub_and_fetch(addend, 1); + return __sync_sub_and_fetch(addend, 1); }//end: InterlockedDecrement64() static forceinline int32 InterlockedDecrement(volatile int32 *addend){ - return __sync_sub_and_fetch(addend, 1); + return __sync_sub_and_fetch(addend, 1); }//end: InterlockedDecrement() static forceinline int64 InterlockedCompareExchange64(volatile int64 *dest, int64 exch, int64 cmp){ - return __sync_val_compare_and_swap(dest, cmp, exch); + return __sync_val_compare_and_swap(dest, cmp, exch); }//end: InterlockedCompareExchange64() static forceinline int32 InterlockedCompareExchange(volatile int32 *dest, int32 exch, int32 cmp){ - return __sync_val_compare_and_swap(dest, cmp, exch); + return __sync_val_compare_and_swap(dest, cmp, exch); }//end: InterlockedCompareExchnage() static forceinline int64 InterlockedExchange64(volatile int64 *target, int64 val){ - return __sync_lock_test_and_set(target, val); + return __sync_lock_test_and_set(target, val); }//end: InterlockedExchange64() @@ -139,4 +144,4 @@ static forceinline int32 InterlockedExchange(volatile int32 *target, int32 val){ #endif //endif compiler decission -#endif +#endif \ No newline at end of file diff --git a/vcproj-13/char-server_sql.vcxproj b/vcproj-13/char-server_sql.vcxproj new file mode 100644 index 0000000000..728e2554a9 --- /dev/null +++ b/vcproj-13/char-server_sql.vcxproj @@ -0,0 +1,221 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {D356871D-58E1-450B-967A-E4E9646175AF} + char-server_sql + Win32Proj + + + + Application + MultiByte + true + v120 + + + Application + MultiByte + v120 + + + + + + + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 + ..\ + $(ProjectName)\$(Configuration)\ + true + ..\ + $(ProjectName)\$(Configuration)\ + false + char-server_sql + char-server_sql + + + + Disabled + ..\3rdparty\libconfig;..\3rdparty\mysql\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FD_SETSIZE=4096;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + false + false + + + EnableFastChecks + MultiThreadedDebug + true + + + + + Level3 + EditAndContinue + CompileAsC + 4800;%(DisableSpecificWarnings) + true + + + libcmtd.lib;oldnames.lib;ws2_32.lib;libmysql.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + false + + + MachineX86 + false + + + + + MaxSpeed + AnySuitable + true + Speed + true + true + true + ..\3rdparty\libconfig;..\3rdparty\mysql\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;NDEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;LIBCONFIG_STATIC;YY_USE_CONST;FD_SETSIZE=4096;%(PreprocessorDefinitions) + true + MultiThreaded + + + + + Level3 + ProgramDatabase + CompileAsC + 4800;%(DisableSpecificWarnings) + true + + + libcmt.lib;oldnames.lib;ws2_32.lib;libmysql.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + true + true + UseLinkTimeCodeGeneration + false + + + MachineX86 + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/vcproj-13/char-server_sql.vcxproj.filters b/vcproj-13/char-server_sql.vcxproj.filters new file mode 100644 index 0000000000..ddb29f4b89 --- /dev/null +++ b/vcproj-13/char-server_sql.vcxproj.filters @@ -0,0 +1,259 @@ + + + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + + + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + char_sql + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + common + + + + + + + {623f21b1-c166-4848-83d8-8b4fe0e2e2df} + + + {83b1ecf5-21d1-4dac-915f-95ff77a90899} + + + {b3f5c857-79c0-4a55-b8c5-7e7f56a8f948} + + + {847768ab-8c4b-431b-8667-00f8ae3b915c} + + + {9e8badd7-548f-4eb4-9e87-613e87e772ff} + + + \ No newline at end of file diff --git a/vcproj-13/login-server_sql.vcxproj b/vcproj-13/login-server_sql.vcxproj new file mode 100644 index 0000000000..17dc5d3e1a --- /dev/null +++ b/vcproj-13/login-server_sql.vcxproj @@ -0,0 +1,209 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {D356871D-58E1-450B-967A-E5E9646175AF} + login-server_sql + Win32Proj + + + + Application + MultiByte + true + v120 + + + Application + MultiByte + v120 + + + + + + + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 + ..\ + $(ProjectName)\$(Configuration)\ + true + ..\ + $(ProjectName)\$(Configuration)\ + false + login-server_sql + login-server_sql + + + + Disabled + ..\3rdparty\libconfig;..\3rdparty\mysql\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FD_SETSIZE=4096;WITH_SQL;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + false + false + + + EnableFastChecks + MultiThreadedDebug + true + + + + + Level3 + EditAndContinue + CompileAsC + 4100;4800;%(DisableSpecificWarnings) + true + + + libcmtd.lib;oldnames.lib;ws2_32.lib;libmysql.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + false + + + MachineX86 + false + + + + + MaxSpeed + AnySuitable + true + Speed + true + true + true + ..\3rdparty\libconfig;..\3rdparty\mysql\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;NDEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FD_SETSIZE=4096;WITH_SQL;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + true + MultiThreaded + + + + + + + + + Level3 + ProgramDatabase + CompileAsC + 4100;4800;%(DisableSpecificWarnings) + true + + + libcmt.lib;oldnames.lib;ws2_32.lib;libmysql.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + true + true + UseLinkTimeCodeGeneration + false + + + MachineX86 + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/vcproj-13/login-server_sql.vcxproj.filters b/vcproj-13/login-server_sql.vcxproj.filters new file mode 100644 index 0000000000..515a0481e3 --- /dev/null +++ b/vcproj-13/login-server_sql.vcxproj.filters @@ -0,0 +1,211 @@ + + + + + login_sql + + + login_sql + + + login_sql + + + login_sql + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + + + + + login_sql + + + login_sql + + + login_sql + + + login_sql + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + common + + + + + + + {b50ee803-e71d-4d41-8f7d-2dad5839df50} + + + {8eea96ed-d379-4694-ae2e-ffb0be95170c} + + + {ab5c90ec-923d-4847-a214-45b40818211e} + + + {68e3bcee-28d9-4b2d-8701-614d50f32999} + + + {779e8145-9bb2-4a88-9149-60586ab0bdd4} + + + \ No newline at end of file diff --git a/vcproj-13/map-server_sql.vcxproj b/vcproj-13/map-server_sql.vcxproj new file mode 100644 index 0000000000..7f342302fe --- /dev/null +++ b/vcproj-13/map-server_sql.vcxproj @@ -0,0 +1,303 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {D356871D-58E1-450B-967A-E6E9646175AF} + map-server_sql + Win32Proj + + + + Application + MultiByte + true + v120 + + + Application + MultiByte + v120 + + + + + + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 + ..\ + $(ProjectName)\$(Configuration)\ + true + ..\ + $(ProjectName)\$(Configuration)\ + false + map-server_sql + map-server_sql + + + + Disabled + ..\3rdparty\mysql\include;..\3rdparty\zlib\include;..\3rdparty\pcre\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;..\3rdparty\libconfig;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;_DEBUG;PCRE_SUPPORT;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FD_SETSIZE=4096;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + false + false + + + EnableFastChecks + MultiThreadedDebug + true + + + + + Level3 + EditAndContinue + CompileAsC + 4018;4100;4800;%(DisableSpecificWarnings) + true + + + libcmtd.lib;oldnames.lib;ws2_32.lib;libmysql.lib;zdll.lib;pcre.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;..\3rdparty\zlib\lib;..\3rdparty\pcre\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + false + + + MachineX86 + false + + + + + MaxSpeed + AnySuitable + true + Speed + true + true + true + ..\3rdparty\mysql\include;..\3rdparty\zlib\include;..\3rdparty\pcre\include;..\3rdparty\msinttypes\include;..\3rdparty\mt19937ar;..\3rdparty\libconfig;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;NDEBUG;PCRE_SUPPORT;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FD_SETSIZE=4096;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + true + MultiThreaded + + + + + Level3 + ProgramDatabase + CompileAsC + 4018;4100;4800;%(DisableSpecificWarnings) + true + + + libcmt.lib;oldnames.lib;ws2_32.lib;libmysql.lib;zdll.lib;pcre.lib;%(AdditionalDependencies) + $(OutDir)$(ProjectName).exe + ..\3rdparty\mysql\lib;..\3rdparty\zlib\lib;..\3rdparty\pcre\lib;%(AdditionalLibraryDirectories) + true + %(IgnoreSpecificDefaultLibraries) + true + $(OutDir)$(ProjectName).pdb + Console + true + true + UseLinkTimeCodeGeneration + false + + + MachineX86 + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/vcproj-13/map-server_sql.vcxproj.filters b/vcproj-13/map-server_sql.vcxproj.filters new file mode 100644 index 0000000000..03be2a77b7 --- /dev/null +++ b/vcproj-13/map-server_sql.vcxproj.filters @@ -0,0 +1,449 @@ + + + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + map_sql + + + common + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + common + + + common + + + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + map_sql + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + + + + + + common + + + map_sql + + + common + + + 3rdparty\mt19937ar + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + 3rdparty\libconfig + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + + + {3a137217-ebf7-44ee-95d9-3d7c51d2a199} + + + {8c01a080-5a78-4fb7-96f2-862c33a02230} + + + {c4845ea8-bcc7-411b-af29-e3842adb6714} + + + {fcf23386-ddba-4a72-9b41-62f8e2d0e6c0} + + + {9caf40b7-c4d1-43b4-bd1f-0376b4f920e7} + + + diff --git a/vcproj-13/mapcache.vcxproj b/vcproj-13/mapcache.vcxproj new file mode 100644 index 0000000000..a5e7b8639d --- /dev/null +++ b/vcproj-13/mapcache.vcxproj @@ -0,0 +1,155 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {D356871D-58E1-450B-967A-E7E9646175AF} + mapcache + Win32Proj + + + + Application + MultiByte + true + v120 + + + Application + MultiByte + v120 + + + + + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 + ..\ + $(ProjectName)\$(Configuration)\ + true + ..\ + $(ProjectName)\$(Configuration)\ + false + mapcache + mapcache + + + + Disabled + ..\3rdparty\libconfig;..\3rdparty\zlib\include;..\3rdparty\msinttypes\include;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;MINICORE;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + false + false + + + EnableFastChecks + MultiThreadedDebug + true + + + + + Level3 + EditAndContinue + CompileAsC + true + + + /FIXED:NO %(AdditionalOptions) + libcmtd.lib;oldnames.lib;zdll.lib;%(AdditionalDependencies) + $(OutDir)mapcache.exe + ..\3rdparty\zlib\lib;%(AdditionalLibraryDirectories) + true + true + $(OutDir)$(ProjectName).pdb + Console + false + + + MachineX86 + false + + + + + MaxSpeed + AnySuitable + true + Speed + true + true + true + ..\3rdparty\libconfig;..\3rdparty\zlib\include;..\3rdparty\msinttypes\include;%(AdditionalIncludeDirectories) + WIN32;_WIN32;__WIN32;NDEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;MINICORE;LIBCONFIG_STATIC;YY_USE_CONST;%(PreprocessorDefinitions) + true + MultiThreaded + false + + + + + Level3 + ProgramDatabase + CompileAsC + true + + + libcmt.lib;oldnames.lib;zdll.lib;%(AdditionalDependencies) + $(OutDir)mapcache.exe + ..\3rdparty\zlib\lib;%(AdditionalLibraryDirectories) + true + true + $(OutDir)$(ProjectName).pdb + Console + true + true + UseLinkTimeCodeGeneration + false + + + MachineX86 + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/vcproj-13/mapcache.vcxproj.filters b/vcproj-13/mapcache.vcxproj.filters new file mode 100644 index 0000000000..9db61046e6 --- /dev/null +++ b/vcproj-13/mapcache.vcxproj.filters @@ -0,0 +1,70 @@ + + + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + mapcache + + + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + common + + + + + + {a9c2444c-ffec-4e89-8412-e530231d79dc} + + + {5ea9d6f7-0a10-4bfb-ad39-478e4b1d8a0d} + + + \ No newline at end of file From 8cc8aa4c880ed0e261af781e62e94b86129d24b9 Mon Sep 17 00:00:00 2001 From: Cahyadi Ramadhan Togihon Date: Sat, 23 Nov 2013 19:16:18 +0700 Subject: [PATCH 2/7] Just a little follow up of f3bb5d4 Signed-off-by: Cahyadi Ramadhan Togihon --- src/map/storage.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/map/storage.c b/src/map/storage.c index cf4b65f758..c177195fd1 100644 --- a/src/map/storage.c +++ b/src/map/storage.c @@ -643,6 +643,7 @@ int storage_guild_storageaddfromcart(struct map_session_data* sd, int index, int *------------------------------------------*/ int storage_guild_storagegettocart(struct map_session_data* sd, int index, int amount) { + short flag; struct guild_storage *stor; nullpo_ret(sd); @@ -660,8 +661,12 @@ int storage_guild_storagegettocart(struct map_session_data* sd, int index, int a if(amount < 1 || amount > stor->items[index].amount) return 0; - if(pc_cart_additem(sd,&stor->items[index],amount,LOG_TYPE_GSTORAGE)==0) + if((flag = pc_cart_additem(sd,&stor->items[index],amount,LOG_TYPE_GSTORAGE)) == 0) guild_storage_delitem(sd,stor,index,amount); + else { + clif_dropitem(sd,index,0); + clif_cart_additem_ack(sd,(flag==1)?ADDITEM_TO_CART_FAIL_WEIGHT:ADDITEM_TO_CART_FAIL_COUNT); + } return 1; } From c4d94f7b1c606e54c4e2a87a2df03f88ce99ff6e Mon Sep 17 00:00:00 2001 From: Euphy Date: Sat, 23 Nov 2013 11:37:49 -0500 Subject: [PATCH 3/7] * Quick fixes. - Fixed Eclage mob drops. (incl. bugreport:8220) http://rathena.org/board/tracker/issue-8220-menblatt-bakonawa/ - Fixed typo in Sura quest. (bugreport:8283, blame d2ee0dd) http://rathena.org/board/tracker/issue-8283-sura-quest-rev-17693/ Signed-off-by: Euphy --- db/re/mob_db.txt | 18 +++++++++--------- npc/re/jobs/3-2/sura.txt | 2 +- sql-files/mob_db_re.sql | 26 +++++++++++++++++--------- 3 files changed, 27 insertions(+), 19 deletions(-) diff --git a/db/re/mob_db.txt b/db/re/mob_db.txt index 25df1a6842..6fb248e68a 100644 --- a/db/re/mob_db.txt +++ b/db/re/mob_db.txt @@ -1510,15 +1510,15 @@ 2362,N_AMON_RA,Nightmare Amon Ra,Nightmare Amon Ra,145,2515784,1,1626487,1302087,3,4106,7307,367,301,86,89,120,131,101,92,14,12,2,7,62,0x1A4,170,854,2016,480,813243,607,5500,608,3500,732,5500,5053,150,2615,50,7211,7000,985,3800,616,400,1552,10,607,3000,0,0,0,0,4236,1 // Eclage (14.2) -2363,MENBLATT,Menblatt,Menblatt,143,82200,1,4150,3421,3,816,1017,79,50,70,68,40,55,108,30,10,12,1,4,44,0x3795,145,472,1056,480,0,0,0,0,0,0,0,6516,2000,6524,50,6499,2000,15051,1000,2169,100,969,2000,6499,10000,0,0,0,0,0,0 -2364,PETAL,Petal,Petal,141,81031,1,4058,3361,1,671,844,73,33,70,82,55,45,108,25,10,12,1,2,24,0x3795,200,1500,768,480,0,0,0,0,0,0,0,6558,2000,12346,1000,1026,1000,6089,250,0,0,0,0,0,0,0,0,0,0,0,0 -2365,CENERE,Cenere,Cenere,146,130131,1,7117,5712,1,1802,2833,87,81,67,39,30,35,95,45,10,12,0,3,24,0x3795,300,1500,720,360,0,0,0,0,0,0,0,6561,2000,7322,500,7001,1500,7320,1000,0,0,0,0,0,0,0,0,0,0,0,0 -2366,ANTIQUE_BOOK,Antique Book,Antique Book,148,134615,1,7225,5870,1,1861,3074,74,42,67,53,32,44,125,5,10,12,0,0,60,0x3795,150,864,960,480,0,0,0,0,0,0,0,6560,2000,7015,1000,1097,1000,0,0,0,0,0,0,0,0,0,0,0,0,0,0 -2367,LICHTERN_B,Blue Lichtern,Blue Lichtern,149,131211,1,7187,5701,1,1513,2923,76,41,124,74,60,55,92,50,10,12,0,0,81,0x3795,150,480,1728,480,0,0,0,0,0,0,0,1000,1000,1001,1000,995,20,12812,5,0,0,0,0,0,0,0,0,0,0,0,0 -2368,LICHTERN_Y,Yellow Lichtern,Yellow Lichtern,147,131513,1,7071,5810,1,1416,2977,84,51,141,94,75,91,144,50,10,12,0,0,88,0x3795,150,0,3456,480,0,0,0,0,0,0,0,1000,1000,1001,1000,997,20,12815,5,0,0,0,0,0,0,0,0,0,0,0,0 -2369,LICHTERN_R,Red Lichtern,Red Lichtern,149,135718,1,7201,6013,1,1647,3096,111,53,147,77,66,65,133,50,10,12,0,0,83,0x3795,150,0,4032,480,0,0,0,0,0,0,0,1000,1000,1001,1000,994,20,12813,5,0,0,0,0,0,0,0,0,0,0,0,0 -2370,LICHTERN_G,Green Lichtern,Green Lichtern,151,133451,1,7214,5710,1,1547,3141,120,57,121,60,58,62,102,50,10,12,0,0,82,0x3795,100,0,2304,480,0,0,0,0,0,0,0,1000,1000,1001,1000,996,20,12814,5,0,0,0,0,0,0,0,0,0,0,0,0 -2371,FAITHFUL_MANAGER,Faithful Manager,Faithful Manager,155,151548,1,8676,6501,3,2091,3698,204,141,80,28,40,25,88,45,10,12,2,0,80,0x3795,200,480,1536,480,0,0,0,0,0,0,0,6559,2000,12353,1000,970,25,971,25,0,0,0,0,0,0,0,0,0,0,0,0 +2363,MENBLATT,Menblatt,Menblatt,143,82200,1,4150,3421,3,816,1017,79,50,70,68,40,55,108,30,10,12,1,4,44,0x3795,145,472,1056,480,0,0,0,0,0,0,0,6557,4000,7168,2000,7163,4608,0,0,0,0,0,0,0,0,0,0,0,0,0,0 +2364,PETAL,Petal,Petal,141,81031,1,4058,3361,1,671,844,73,33,70,82,55,45,108,25,10,12,1,2,24,0x3795,200,1500,768,480,0,0,0,0,0,0,0,6558,4000,12346,2000,1026,2000,6089,500,0,0,0,0,0,0,0,0,0,0,0,0 +2365,CENERE,Cenere,Cenere,146,130131,1,7117,5712,1,1802,2833,87,81,67,39,30,35,95,45,10,12,0,3,24,0x3795,300,1500,720,360,0,0,0,0,0,0,0,6561,4000,7322,1000,7001,3000,7320,2000,0,0,0,0,0,0,0,0,0,0,0,0 +2366,ANTIQUE_BOOK,Antique Book,Antique Book,148,134615,1,7225,5870,1,1861,3074,74,42,67,53,32,44,125,5,10,12,0,0,60,0x3795,150,864,960,480,0,0,0,0,0,0,0,6560,4000,7015,2000,1097,2000,0,0,0,0,0,0,0,0,0,0,0,0,0,0 +2367,LICHTERN_B,Blue Lichtern,Blue Lichtern,149,131211,1,7187,5701,1,1513,2923,76,41,124,74,60,55,92,50,10,12,0,0,81,0x3795,150,480,1728,480,0,0,0,0,0,0,0,1000,2000,1001,2000,995,40,12812,10,0,0,0,0,0,0,0,0,0,0,0,0 +2368,LICHTERN_Y,Yellow Lichtern,Yellow Lichtern,147,131513,1,7071,5810,1,1416,2977,84,51,141,94,75,91,144,50,10,12,0,0,88,0x3795,150,0,3456,480,0,0,0,0,0,0,0,1000,2000,1001,2000,997,40,12815,10,0,0,0,0,0,0,0,0,0,0,0,0 +2369,LICHTERN_R,Red Lichtern,Red Lichtern,149,135718,1,7201,6013,1,1647,3096,111,53,147,77,66,65,133,50,10,12,0,0,83,0x3795,150,0,4032,480,0,0,0,0,0,0,0,1000,2000,1001,2000,994,40,12813,10,0,0,0,0,0,0,0,0,0,0,0,0 +2370,LICHTERN_G,Green Lichtern,Green Lichtern,151,133451,1,7214,5710,1,1547,3141,120,57,121,60,58,62,102,50,10,12,0,0,82,0x3795,100,0,2304,480,0,0,0,0,0,0,0,1000,2000,1001,2000,996,40,12814,10,0,0,0,0,0,0,0,0,0,0,0,0 +2371,FAITHFUL_MANAGER,Faithful Manager,Faithful Manager,155,151548,1,8676,6501,3,2091,3698,204,141,80,28,40,25,88,45,10,12,2,0,80,0x3795,200,480,1536,480,0,0,0,0,0,0,0,6559,4000,12353,2000,970,50,971,50,0,0,0,0,0,0,0,0,0,0,0,0 // Additional Monsters 2372,SOIL,Soil,Soil,1,15,0,0,0,1,1,2,100,99,0,0,0,0,0,0,7,12,0,3,22,0x40,2000,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 diff --git a/npc/re/jobs/3-2/sura.txt b/npc/re/jobs/3-2/sura.txt index 02d65ede05..fe3ce92eba 100644 --- a/npc/re/jobs/3-2/sura.txt +++ b/npc/re/jobs/3-2/sura.txt @@ -36,7 +36,7 @@ ve_in,237,125,0 script King Crab#job_shu 107,{ mes "Those arrogant fellows deserve a bitter lesson."; mes "How dare a little rookie attack you, boss!"; next; - if (.@job_check) { + if (!.@job_check) { mes "[King Crab]"; mes "Khhha ha ha ha ha ha!!!!"; mes "One more cup of beer, here!!!"; diff --git a/sql-files/mob_db_re.sql b/sql-files/mob_db_re.sql index 433d3fdce9..5fc3c6f000 100644 --- a/sql-files/mob_db_re.sql +++ b/sql-files/mob_db_re.sql @@ -1576,15 +1576,15 @@ REPLACE INTO `mob_db` VALUES (2361,'G_N_ANCIENT_MUMMY','Nightmare Ancient Mummy' REPLACE INTO `mob_db` VALUES (2362,'N_AMON_RA','Nightmare Amon Ra','Nightmare Amon Ra',145,2515784,1,1626487,1302087,3,4106,7307,367,301,86,89,120,131,101,92,14,12,2,7,62,0x1A4,170,854,2016,480,813243,607,5500,608,3500,732,5500,5053,150,2615,50,7211,7000,985,3800,616,400,1552,10,607,3000,0,0,0,0,4236,1); # Eclage (14.2) -REPLACE INTO `mob_db` VALUES (2363,'MENBLATT','Menblatt','Menblatt',143,82200,1,4150,3421,3,816,1017,79,50,70,68,40,55,108,30,10,12,1,4,44,0x3795,145,472,1056,480,0,0,0,0,0,0,0,6516,2000,6524,50,6499,2000,15051,1000,2169,100,969,2000,6499,10000,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2364,'PETAL','Petal','Petal',141,81031,1,4058,3361,1,671,844,73,33,70,82,55,45,108,25,10,12,1,2,24,0x3795,200,1500,768,480,0,0,0,0,0,0,0,6558,2000,12346,1000,1026,1000,6089,250,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2365,'CENERE','Cenere','Cenere',146,130131,1,7117,5712,1,1802,2833,87,81,67,39,30,35,95,45,10,12,0,3,24,0x3795,300,1500,720,360,0,0,0,0,0,0,0,6561,2000,7322,500,7001,1500,7320,1000,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2366,'ANTIQUE_BOOK','Antique Book','Antique Book',148,134615,1,7225,5870,1,1861,3074,74,42,67,53,32,44,125,5,10,12,0,0,60,0x3795,150,864,960,480,0,0,0,0,0,0,0,6560,2000,7015,1000,1097,1000,0,0,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2367,'LICHTERN_B','Blue Lichtern','Blue Lichtern',149,131211,1,7187,5701,1,1513,2923,76,41,124,74,60,55,92,50,10,12,0,0,81,0x3795,150,480,1728,480,0,0,0,0,0,0,0,1000,1000,1001,1000,995,20,12812,5,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2368,'LICHTERN_Y','Yellow Lichtern','Yellow Lichtern',147,131513,1,7071,5810,1,1416,2977,84,51,141,94,75,91,144,50,10,12,0,0,88,0x3795,150,0,3456,480,0,0,0,0,0,0,0,1000,1000,1001,1000,997,20,12815,5,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2369,'LICHTERN_R','Red Lichtern','Red Lichtern',149,135718,1,7201,6013,1,1647,3096,111,53,147,77,66,65,133,50,10,12,0,0,83,0x3795,150,0,4032,480,0,0,0,0,0,0,0,1000,1000,1001,1000,994,20,12813,5,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2370,'LICHTERN_G','Green Lichtern','Green Lichtern',151,133451,1,7214,5710,1,1547,3141,120,57,121,60,58,62,102,50,10,12,0,0,82,0x3795,100,0,2304,480,0,0,0,0,0,0,0,1000,1000,1001,1000,996,20,12814,5,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2371,'FAITHFUL_MANAGER','Faithful Manager','Faithful Manager',155,151548,1,8676,6501,3,2091,3698,204,141,80,28,40,25,88,45,10,12,2,0,80,0x3795,200,480,1536,480,0,0,0,0,0,0,0,6559,2000,12353,1000,970,25,971,25,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2363,'MENBLATT','Menblatt','Menblatt',143,82200,1,4150,3421,3,816,1017,79,50,70,68,40,55,108,30,10,12,1,4,44,0x3795,145,472,1056,480,0,0,0,0,0,0,0,6557,4000,7168,2000,7163,4608,0,0,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2364,'PETAL','Petal','Petal',141,81031,1,4058,3361,1,671,844,73,33,70,82,55,45,108,25,10,12,1,2,24,0x3795,200,1500,768,480,0,0,0,0,0,0,0,6558,4000,12346,2000,1026,2000,6089,500,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2365,'CENERE','Cenere','Cenere',146,130131,1,7117,5712,1,1802,2833,87,81,67,39,30,35,95,45,10,12,0,3,24,0x3795,300,1500,720,360,0,0,0,0,0,0,0,6561,4000,7322,1000,7001,3000,7320,2000,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2366,'ANTIQUE_BOOK','Antique Book','Antique Book',148,134615,1,7225,5870,1,1861,3074,74,42,67,53,32,44,125,5,10,12,0,0,60,0x3795,150,864,960,480,0,0,0,0,0,0,0,6560,4000,7015,2000,1097,2000,0,0,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2367,'LICHTERN_B','Blue Lichtern','Blue Lichtern',149,131211,1,7187,5701,1,1513,2923,76,41,124,74,60,55,92,50,10,12,0,0,81,0x3795,150,480,1728,480,0,0,0,0,0,0,0,1000,2000,1001,2000,995,40,12812,10,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2368,'LICHTERN_Y','Yellow Lichtern','Yellow Lichtern',147,131513,1,7071,5810,1,1416,2977,84,51,141,94,75,91,144,50,10,12,0,0,88,0x3795,150,0,3456,480,0,0,0,0,0,0,0,1000,2000,1001,2000,997,40,12815,10,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2369,'LICHTERN_R','Red Lichtern','Red Lichtern',149,135718,1,7201,6013,1,1647,3096,111,53,147,77,66,65,133,50,10,12,0,0,83,0x3795,150,0,4032,480,0,0,0,0,0,0,0,1000,2000,1001,2000,994,40,12813,10,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2370,'LICHTERN_G','Green Lichtern','Green Lichtern',151,133451,1,7214,5710,1,1547,3141,120,57,121,60,58,62,102,50,10,12,0,0,82,0x3795,100,0,2304,480,0,0,0,0,0,0,0,1000,2000,1001,2000,996,40,12814,10,0,0,0,0,0,0,0,0,0,0,0,0); +REPLACE INTO `mob_db` VALUES (2371,'FAITHFUL_MANAGER','Faithful Manager','Faithful Manager',155,151548,1,8676,6501,3,2091,3698,204,141,80,28,40,25,88,45,10,12,2,0,80,0x3795,200,480,1536,480,0,0,0,0,0,0,0,6559,4000,12353,2000,970,50,971,50,0,0,0,0,0,0,0,0,0,0,0,0); # Additional Monsters REPLACE INTO `mob_db` VALUES (2372,'SOIL','Soil','Soil',1,15,0,0,0,1,1,2,100,99,0,0,0,0,0,0,7,12,0,3,22,0x40,2000,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); @@ -2332,4 +2332,12 @@ REPLACE INTO `mob_db` VALUES (2476,'MG_AMDARAIS','Amdarias','Amdarias',143,32839 #3107,E_EASTER_BUNNY #3108,JITTERBUG1 #3109,JITTERBUG2 +# +#3201,JT_LUCKYCASE +#3202,JT_ORGANIC_JAKK +#3203,JT_INORGANIC_JAKK +#3204,JT_PIXY_PINK_PORING +#3205,JT_PIXY_BLUE_PORING +#3206,JT_LITTLE_GOLDPORING +#3207,JT_E_AQUA_ELEMENTAL From 72f704d4c1970cf948117111ef0dc5b5cb063982 Mon Sep 17 00:00:00 2001 From: Euphy Date: Sat, 23 Nov 2013 19:12:34 -0500 Subject: [PATCH 4/7] * Fixed two issues with Nightmare Ancient Mummy. - Corrected a drop. (bugreport:8277) http://rathena.org/board/tracker/issue-8277-nightmare-pyramids-ancient-mummy/ - Fixed a quest target. (bugreport:8278) http://rathena.org/board/tracker/issue-8278-nightmare-pyramids-ancient-mummy-kill-quest/ Signed-off-by: Euphy --- db/quest_db.txt | 2 +- db/re/mob_db.txt | 2 +- sql-files/mob_db_re.sql | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/db/quest_db.txt b/db/quest_db.txt index 365e14f282..d7cfc7ba9f 100644 --- a/db/quest_db.txt +++ b/db/quest_db.txt @@ -295,7 +295,7 @@ 2289,0,2355,20,0,0,0,0,"Verit Hunting (Nightmare)" 2290,82800,0,0,0,0,0,0,"Verit Hunting - Cooldown" 2291,82800,0,0,0,0,0,0,"Mummy Hunting - Cooldown" -2292,0,2354,20,0,0,0,0,"Mummy Hunting (Nightmare)" +2292,0,2360,20,0,0,0,0,"Mummy Hunting (Nightmare)" // New Novice Ground 2299,0,0,0,0,0,0,0,"Training Center: Talk to Lisa" diff --git a/db/re/mob_db.txt b/db/re/mob_db.txt index 6fb248e68a..61544f02d8 100644 --- a/db/re/mob_db.txt +++ b/db/re/mob_db.txt @@ -1505,7 +1505,7 @@ 2357,G_N_MIMIC,Nightmare Mimic,Nightmare Mimic,137,63101,1,0,0,1,1345,1758,210,40,71,180,35,21,61,0,10,12,1,0,60,0x3795,100,972,500,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 2358,N_ARCLOUSE,Nightmare Arclouse,Nightmare Arclouse,134,48013,1,2506,2303,1,1104,1445,101,45,65,85,51,45,251,31,10,12,1,4,42,0x3795,100,960,500,480,0,0,0,0,0,0,0,1096,3500,938,3000,943,800,912,500,716,300,997,20,912,2500,0,0,0,0,4240,1 2359,G_N_ARCLOUSE,Nightmare Arclouse,Nightmare Arclouse,134,48013,1,0,0,1,1104,1445,101,45,65,85,51,45,251,31,10,12,1,4,42,0x3795,100,960,500,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 -2360,N_ANCIENT_MUMMY,Nightmare Ancient Mummy,Nightmare Ancient Mummy,141,90157,1,4712,4001,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,930,4500,934,1800,2624,2,2611,150,13735,10,756,150,757,100,0,0,0,0,4248,1 +2360,N_ANCIENT_MUMMY,Nightmare Ancient Mummy,Nightmare Ancient Mummy,141,90157,1,4712,4001,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,930,4500,934,1800,2624,2,2611,150,12735,10,756,150,757,100,0,0,0,0,4248,1 2361,G_N_ANCIENT_MUMMY,Nightmare Ancient Mummy,Nightmare Ancient Mummy,141,90157,1,0,0,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 2362,N_AMON_RA,Nightmare Amon Ra,Nightmare Amon Ra,145,2515784,1,1626487,1302087,3,4106,7307,367,301,86,89,120,131,101,92,14,12,2,7,62,0x1A4,170,854,2016,480,813243,607,5500,608,3500,732,5500,5053,150,2615,50,7211,7000,985,3800,616,400,1552,10,607,3000,0,0,0,0,4236,1 diff --git a/sql-files/mob_db_re.sql b/sql-files/mob_db_re.sql index 5fc3c6f000..93a651a8fa 100644 --- a/sql-files/mob_db_re.sql +++ b/sql-files/mob_db_re.sql @@ -1571,7 +1571,7 @@ REPLACE INTO `mob_db` VALUES (2356,'N_MIMIC','Nightmare Mimic','Nightmare Mimic' REPLACE INTO `mob_db` VALUES (2357,'G_N_MIMIC','Nightmare Mimic','Nightmare Mimic',137,63101,1,0,0,1,1345,1758,210,40,71,180,35,21,61,0,10,12,1,0,60,0x3795,100,972,500,288,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); REPLACE INTO `mob_db` VALUES (2358,'N_ARCLOUSE','Nightmare Arclouse','Nightmare Arclouse',134,48013,1,2506,2303,1,1104,1445,101,45,65,85,51,45,251,31,10,12,1,4,42,0x3795,100,960,500,480,0,0,0,0,0,0,0,1096,3500,938,3000,943,800,912,500,716,300,997,20,912,2500,0,0,0,0,4240,1); REPLACE INTO `mob_db` VALUES (2359,'G_N_ARCLOUSE','Nightmare Arclouse','Nightmare Arclouse',134,48013,1,0,0,1,1104,1445,101,45,65,85,51,45,251,31,10,12,1,4,42,0x3795,100,960,500,480,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); -REPLACE INTO `mob_db` VALUES (2360,'N_ANCIENT_MUMMY','Nightmare Ancient Mummy','Nightmare Ancient Mummy',141,90157,1,4712,4001,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,930,4500,934,1800,2624,2,2611,150,13735,10,756,150,757,100,0,0,0,0,4248,1); +REPLACE INTO `mob_db` VALUES (2360,'N_ANCIENT_MUMMY','Nightmare Ancient Mummy','Nightmare Ancient Mummy',141,90157,1,4712,4001,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,930,4500,934,1800,2624,2,2611,150,12735,10,756,150,757,100,0,0,0,0,4248,1); REPLACE INTO `mob_db` VALUES (2361,'G_N_ANCIENT_MUMMY','Nightmare Ancient Mummy','Nightmare Ancient Mummy',141,90157,1,0,0,1,1841,2188,142,51,126,75,61,85,187,24,10,12,1,1,49,0x3795,175,1772,120,384,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0); REPLACE INTO `mob_db` VALUES (2362,'N_AMON_RA','Nightmare Amon Ra','Nightmare Amon Ra',145,2515784,1,1626487,1302087,3,4106,7307,367,301,86,89,120,131,101,92,14,12,2,7,62,0x1A4,170,854,2016,480,813243,607,5500,608,3500,732,5500,5053,150,2615,50,7211,7000,985,3800,616,400,1552,10,607,3000,0,0,0,0,4236,1); From fff04377eda173011e6f61d5bde2e5da95a041bd Mon Sep 17 00:00:00 2001 From: Lilith- Date: Sun, 24 Nov 2013 09:28:47 -0800 Subject: [PATCH 5/7] Fixed bug report: http://rathena.org/board/tracker/issue-5958-rg-shield-spell-level-3 Added fix for shadow equipment slots in itemdb_parse_dbrow: if an item isn't shadow gear but have shadow equipment slot map-server will mark it as IT_ETC. --- db/re/skill_db.txt | 2 +- src/map/battle.c | 14 +++- src/map/itemdb.c | 6 ++ src/map/pc.h | 2 +- src/map/skill.c | 180 +++++++++++++++++++++------------------------ src/map/status.c | 4 +- 6 files changed, 106 insertions(+), 102 deletions(-) diff --git a/db/re/skill_db.txt b/db/re/skill_db.txt index 72aaca02d1..efca12fe0c 100644 --- a/db/re/skill_db.txt +++ b/db/re/skill_db.txt @@ -1072,7 +1072,7 @@ 2312,5,6,1,-1,0,0,5,1,no,0,0,0,weapon,0,0x0, LG_PINPOINTATTACK,Pinpoint Attack 2313,0,6,4,0,0x1,0,5,1,yes,0,0,0,none,0,0x0, LG_FORCEOFVANGUARD,Force of Vanguard 2314,1,6,1,-1,0,0,1,1,no,0,0,0,weapon,0,0x0, LG_RAGEBURST,Rage Burst -2315,0,6,4,0,0x2,3,3,1,yes,0,0,0,none,2,0x0, LG_SHIELDSPELL,Shield Spell +2315,0,6,4,0:6:0,0x2,3,3,1,yes,0,0,0,none,2,0x0, LG_SHIELDSPELL,Shield Spell 2316,0,6,4,0,0x1,0,5,1,yes,0,0,0,none,0,0x0, LG_EXEEDBREAK,Exceed Break 2317,0,6,2,-1,0x2,0,5,1,yes,0,0,0,none,3:4:5:6:7,0x0, LG_OVERBRAND,Over Brand 2318,0,6,4,0,0x1,0,5,1,yes,0,0,0,none,0,0x0, LG_PRESTIGE,Prestige diff --git a/src/map/battle.c b/src/map/battle.c index 45a999b45d..6b7cf4b744 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -1206,8 +1206,13 @@ int64 battle_calc_damage(struct block_list *src,struct block_list *bl,struct Dam if (((TBL_MOB*)bl)->class_==mob_splendide[i]) { DAMAGE_ADDRATE(sce->val1) break; - } } + /* Self Buff that destroys the armor of any target hit with melee or ranged physical attacks */ + if( sc->data[SC_SHIELDSPELL_REF] && sc->data[SC_SHIELDSPELL_REF]->val1 == 1 && flag&BF_WEAPON ) { + skill_break_equip(src,bl, EQP_ARMOR, 10000, BCT_ENEMY); // 100% chance (http://irowiki.org/wiki/Shield_Spell#Level_3_spells_.28refine_based.29) + status_change_end(src,SC_SHIELDSPELL_REF,INVALID_TIMER); + } + } if( sc->data[SC_POISONINGWEAPON] && ((flag&BF_WEAPON) && (!skill_id || skill_id == GC_VENOMPRESSURE)) //chk skill type poison_smoke is a unit && (damage > 0 && rnd()%100 < sc->data[SC_POISONINGWEAPON]->val3 )) //did some dammage and chance ok (why no additional effect ?? @@ -3396,7 +3401,7 @@ static int battle_calc_attack_skill_ratio(struct Damage wd, struct block_list *s if( shield_data ) skillratio += shield_data->def * 10; } else - skillratio += 2400; //2500% + skillratio = 0; // Prevent damage since level 2 is MATK. [Aleos] break; case LG_MOONSLASHER: skillratio += -100 + (120 * skill_lv + ((sd) ? pc_checkskill(sd,LG_OVERBRAND) : 5) * 80); @@ -5917,6 +5922,11 @@ int64 battle_calc_return_damage(struct block_list* bl, struct block_list *src, i rdamage += rd1 * 70 / 100; // Target receives 70% of the amplified damage. [Rytech] } } + + if( sc->data[SC_SHIELDSPELL_DEF] && sc->data[SC_SHIELDSPELL_DEF]->val1 == 2 && !(src->type == BL_MOB && is_boss(src)) ){ + rdamage += damage * sc->data[SC_SHIELDSPELL_DEF]->val2 / 100; + if (rdamage < 1) rdamage = 1; + } } } } else { diff --git a/src/map/itemdb.c b/src/map/itemdb.c index 37539747a2..cd16377315 100644 --- a/src/map/itemdb.c +++ b/src/map/itemdb.c @@ -1080,6 +1080,12 @@ static bool itemdb_parse_dbrow(char** str, const char* source, int line, int scr id->type = IT_ETC; } + if( id->type != IT_SHADOWGEAR && id->equip&EQP_SHADOW_GEAR ) + { + ShowWarning("Item %d (%s) have invalid equipment slot! Making it an etc item.\n", nameid, id->jname); + id->type = IT_ETC; + } + id->wlv = cap_value(atoi(str[15]), REFINE_TYPE_ARMOR, REFINE_TYPE_MAX); #ifdef RENEWAL itemdb_re_split_atoi(str[16],&id->elv,&id->elvmax); diff --git a/src/map/pc.h b/src/map/pc.h index 217d644f99..e41c209930 100644 --- a/src/map/pc.h +++ b/src/map/pc.h @@ -665,7 +665,7 @@ struct { #define EQP_HELM (EQP_HEAD_LOW|EQP_HEAD_MID|EQP_HEAD_TOP) #define EQP_ACC (EQP_ACC_L|EQP_ACC_R) #define EQP_COSTUME (EQP_COSTUME_HEAD_TOP|EQP_COSTUME_HEAD_MID|EQP_COSTUME_HEAD_LOW|EQP_COSTUME_GARMENT) -//#define EQP_SHADOW_GEAR (EQP_SHADOW_ARMOR|EQP_SHADOW_WEAPON|EQP_SHADOW_SHIELD|EQP_SHADOW_SHOES|EQP_SHADOW_ACC_R|EQP_SHADOW_ACC_L) +#define EQP_SHADOW_GEAR (EQP_SHADOW_ARMOR|EQP_SHADOW_WEAPON|EQP_SHADOW_SHIELD|EQP_SHADOW_SHOES|EQP_SHADOW_ACC_R|EQP_SHADOW_ACC_L) #define EQP_SHADOW_ACC (EQP_SHADOW_ACC_R|EQP_SHADOW_ACC_L) /// Equip positions that use a visible sprite diff --git a/src/map/skill.c b/src/map/skill.c index fdc7fc303d..742f241be5 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -8798,110 +8798,96 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui break; case LG_SHIELDSPELL: - if( flag&1 ) { - int duration = (sd) ? sd->bonus.shieldmdef * 2000 : 10000; - sc_start(src,bl,SC_SILENCE,100,skill_lv,duration); - } else if( sd ) { - int opt = skill_lv; - int rate = rnd()%100; - int val, brate; + if( flag&1 ) + sc_start(src,bl,SC_SILENCE,100,skill_lv,(sd)?sd->bonus.shieldmdef * 2000 : 10000); + else if( sd ) { + int opt = rnd()%3 + 1; + int val = 0, splash = 0; + struct item_data *shield_data = sd->inventory_data[sd->equip_index[EQI_HAND_L]]; + if( !shield_data || shield_data->type != IT_ARMOR ) { // No shield? + clif_skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0); + break; + } switch( skill_lv ) { - case 1: - { - struct item_data *shield_data = sd->inventory_data[sd->equip_index[EQI_HAND_L]]; - if( !shield_data || shield_data->type != IT_ARMOR ) { // No shield? - clif_skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0); - break; - } - brate = shield_data->def * 10; - if( rate < 50 ) - opt = 1; - else if( rate < 75 ) - opt = 2; - else - opt = 3; - - switch( opt ) { - case 1: - sc_start(src,bl,SC_SHIELDSPELL_DEF,100,opt,-1); - clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); - if( rate < brate ) - map_foreachinrange(skill_area_sub,src,skill_get_splash(skill_id,skill_lv),BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_damage_id); - status_change_end(bl,SC_SHIELDSPELL_DEF,INVALID_TIMER); - break; - case 2: - val = shield_data->def / 10; // % Reflected damage. - sc_start2(src,bl,SC_SHIELDSPELL_DEF,brate,opt,val,shield_data->def * 1000); - break; - case 3: - val = shield_data->def; // Attack increase. - sc_start2(src,bl,SC_SHIELDSPELL_DEF,brate,opt,val,shield_data->def * 3000); - break; - } - } - break; - - case 2: - brate = sd->bonus.shieldmdef * 20; - if( rate < 30 ) - opt = 1; - else if( rate < 60 ) - opt = 2; - else - opt = 3; - switch( opt ) { - case 1: - sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,-1); - clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); - if( rate < brate ) - map_foreachinrange(skill_area_sub,src,skill_get_splash(skill_id,skill_lv),BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|2,skill_castend_damage_id); - status_change_end(bl,SC_SHIELDSPELL_MDEF,INVALID_TIMER); - break; - case 2: - sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,-1); - clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); - if( rate < brate ) - map_foreachinrange(skill_area_sub,src,skill_get_splash(skill_id,skill_lv),BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_nodamage_id); - break; - case 3: - if( sc_start(src,bl,SC_SHIELDSPELL_MDEF,brate,opt,sd->bonus.shieldmdef * 30000) ) - clif_skill_nodamage(src,bl,PR_MAGNIFICAT,skill_lv, - sc_start(src,bl,SC_MAGNIFICAT,100,1,sd->bonus.shieldmdef * 30000)); - break; - } - break; - - case 3: - { - struct item *it = &sd->status.inventory[sd->equip_index[EQI_HAND_L]]; - if( !it ) { // No shield? - clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0); + case 1: // DEF based + val = shield_data->def; + if( !val ) { + clif_skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0); break; } - brate = it->refine * 5; - if( rate < 25 ) - opt = 1; - else if( rate < 50 ) - opt = 2; - else - opt = 3; switch( opt ) { - case 1: - val = 105 * it->refine / 10; - sc_start2(src,bl,SC_SHIELDSPELL_REF,brate,opt,val,skill_get_time(skill_id,skill_lv)); + case 1: // Deals Neutral property damage around Self. Knocks them back 2 cells. + if( val < 41 ) + splash = 1; + else if( val < 81 ) + splash = 2; + else + splash = 3; + clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); + map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_damage_id); break; - case 2: case 3: - if( rate < brate ) - { - val = sstatus->max_hp * (11 + it->refine) / 100; - status_heal(bl, val, 0, 3); - } + case 2: // Reflects melee attacks. (Does not work against Bosses). + val = shield_data->def / 10; + sc_start2(src,bl,SC_SHIELDSPELL_DEF,100,opt,val,shield_data->def * 1000); + break; + case 3: // Increases ATK for the spell duration. + val = shield_data->def; + sc_start2(src,bl,SC_SHIELDSPELL_DEF,100,opt,val,shield_data->def * 3000); break; - /*case 3: - // Full protection. I need confirm what effect should be here. Moved to case 2 to until we got it. - break;*/ } - } + break; + + case 2: // MDEF based + val = sd->bonus.shieldmdef; + if( !val ) { + clif_skill_fail(sd, skill_id, USESKILL_FAIL_LEVEL, 0); + break; + } + if( val < 4 ) + splash = 1; + else if( val < 6 ) + splash = 2; + else + splash = 3; + + switch( opt ) { + case 1: // Deals Holy property magic damage around Self. + clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); + map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|2,skill_castend_damage_id); + break; + case 2: // Casts Lex Divina around Self. + //sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,INVALID_TIMER); + clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); + map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_nodamage_id); + break; + case 3: // Casts Magnificat. + clif_skill_nodamage(src,bl,PR_MAGNIFICAT,skill_lv,sc_start(src,bl,SC_MAGNIFICAT,100,1,sd->bonus.shieldmdef * 30000)); + break; + } + break; + + case 3: // refine based + { + struct item *shield = &sd->status.inventory[sd->equip_index[EQI_HAND_L]]; + if( !shield || !shield->refine ) { + clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0); + break; + } + switch( opt ) { + case 1: // Allows you to break armor at a 100% rate when you do damage. + sc_start(src,bl,SC_SHIELDSPELL_REF,100,opt,min(shield->refine * 1500,30000)); // 30 sec duration on +20 shield. + break; + case 2: // Increases DEF and Status Effect resistance depending on Shield refine rate. + val = (10 * shield->refine) + (status_get_lv(src) / 100); + splash = (2 * shield->refine) + (status_get_luk(src) / 10); + sc_start4(src,bl,SC_SHIELDSPELL_REF,100,opt,val,splash,0,shield->refine * 20000); + break; + case 3: // Recovers HP depending on Shield refine rate. + val = sstatus->max_hp * (status_get_lv(src) / 10 + shield->refine) / 100; + status_heal(bl,val,0,2); + break; + } + } break; } clif_skill_nodamage(src,bl,skill_id,skill_lv,1); diff --git a/src/map/status.c b/src/map/status.c index a6e948543d..438e73e8ad 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -5356,7 +5356,7 @@ static signed short status_calc_def2(struct block_list *bl, struct status_change return 0; if(sc->data[SC_SUN_COMFORT]) def2 += sc->data[SC_SUN_COMFORT]->val2; - if( sc->data[SC_SHIELDSPELL_REF] && sc->data[SC_SHIELDSPELL_REF]->val1 == 1 ) + if( sc->data[SC_SHIELDSPELL_REF] && sc->data[SC_SHIELDSPELL_REF]->val1 == 2 ) def2 += sc->data[SC_SHIELDSPELL_REF]->val2; if( sc->data[SC_BANDING] && sc->data[SC_BANDING]->val2 > 0 ) def2 += (5 + sc->data[SC_BANDING]->val1) * (sc->data[SC_BANDING]->val2); @@ -6987,6 +6987,8 @@ int status_get_sc_def(struct block_list *src, struct block_list *bl, enum sc_typ sc_def += sc->data[SC_SCRESIST]->val1*100; // Status resist else if (sc->data[SC_SIEGFRIED]) sc_def += sc->data[SC_SIEGFRIED]->val3*100; // Status resistance. + else if (sc->data[SC_SHIELDSPELL_REF] && sc->data[SC_SHIELDSPELL_REF]->val1 == 2) + sc_def += sc->data[SC_SIEGFRIED]->val3*100; } // When tick def not set, reduction is the same for both. From 823c5ae5aea14611cb367c31f9d36e0e3032b20c Mon Sep 17 00:00:00 2001 From: Lilith- Date: Mon, 25 Nov 2013 05:10:34 -0800 Subject: [PATCH 6/7] * Follow up fff0437 Added missing 'sc_start' and 'status_change_end' --- src/map/skill.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/map/skill.c b/src/map/skill.c index 742f241be5..117c0a7a24 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -8823,6 +8823,8 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui splash = 2; else splash = 3; + if( sc_start(src,bl,SC_SHIELDSPELL_DEF,100,opt,INVALID_TIMER) ) + status_change_end(bl,SC_SHIELDSPELL_DEF,INVALID_TIMER); clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_damage_id); break; @@ -8852,15 +8854,19 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui switch( opt ) { case 1: // Deals Holy property magic damage around Self. + if( sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,INVALID_TIMER) ) + status_change_end(bl,SC_SHIELDSPELL_MDEF,INVALID_TIMER); clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); - map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|2,skill_castend_damage_id); + map_foreachinrange(skill_area_sub, src, splash, BL_CHAR, src, skill_id, skill_lv, tick, flag|BCT_ENEMY|2, skill_castend_damage_id); break; case 2: // Casts Lex Divina around Self. - //sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,INVALID_TIMER); - clif_skill_damage(src,bl,tick, status_get_amotion(src), 0, -30000, 1, skill_id, skill_lv, 6); + if( sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,INVALID_TIMER) ) + status_change_end(bl,SC_SHIELDSPELL_MDEF,INVALID_TIMER); map_foreachinrange(skill_area_sub,src,splash,BL_CHAR,src,skill_id,skill_lv,tick,flag|BCT_ENEMY|1,skill_castend_nodamage_id); break; case 3: // Casts Magnificat. + if( sc_start(src,bl,SC_SHIELDSPELL_MDEF,100,opt,INVALID_TIMER) ) + status_change_end(bl,SC_SHIELDSPELL_MDEF,INVALID_TIMER); clif_skill_nodamage(src,bl,PR_MAGNIFICAT,skill_lv,sc_start(src,bl,SC_MAGNIFICAT,100,1,sd->bonus.shieldmdef * 30000)); break; } @@ -8883,6 +8889,8 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui sc_start4(src,bl,SC_SHIELDSPELL_REF,100,opt,val,splash,0,shield->refine * 20000); break; case 3: // Recovers HP depending on Shield refine rate. + if( sc_start(src,bl,SC_SHIELDSPELL_REF,100,opt,INVALID_TIMER) ) + status_change_end(bl,SC_SHIELDSPELL_REF,INVALID_TIMER); val = sstatus->max_hp * (status_get_lv(src) / 10 + shield->refine) / 100; status_heal(bl,val,0,2); break; From 1d87e46509a140943edf033cad135c5b5de73c80 Mon Sep 17 00:00:00 2001 From: Lilith- Date: Mon, 25 Nov 2013 05:14:51 -0800 Subject: [PATCH 7/7] * Fixed bugreport:8282 Added message info for GM --- conf/msg_conf/map_msg.conf | 3 ++- src/map/atcommand.c | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/conf/msg_conf/map_msg.conf b/conf/msg_conf/map_msg.conf index d8de459fd4..5a82bf7be2 100644 --- a/conf/msg_conf/map_msg.conf +++ b/conf/msg_conf/map_msg.conf @@ -707,7 +707,8 @@ 705: %s is VIP for %d years, %d months, %d days, %d hours and %d minutes. 706: This player is now VIP for %d years, %d months, %d days, %d hours and %d minutes. 707: You are VIP until -//708-899 free +708: Player '%s' is now VIP until : +//709-899 free //------------------------------------ // More atcommands message diff --git a/src/map/atcommand.c b/src/map/atcommand.c index 3fb84089cf..3e28b91637 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -9197,13 +9197,15 @@ ACMD_FUNC(vip) { char timestr[21]; time_t now=time(NULL); split_time(pl_sd->vip.time*60,&year,&month,&day,&hour,&minute,&second); - sprintf(atcmd_output,msg_txt(sd,705),pl_sd->status.name,year,month,day,hour,minute); //%s is VIP for %d years, %d months, %d days, %d hours and %d minutes. + sprintf(atcmd_output,msg_txt(sd,705),pl_sd->status.name,year,month,day,hour,minute); // %s is VIP for %d years, %d months, %d days, %d hours and %d minutes. clif_displaymessage(pl_sd->fd, atcmd_output); - sprintf(atcmd_output,msg_txt(sd,706),year,month,day,hour,minute); //This player is now VIP for %d years, %d months, %d days, %d hours and %d minutes. + sprintf(atcmd_output,msg_txt(sd,706),year,month,day,hour,minute); // This player is now VIP for %d years, %d months, %d days, %d hours and %d minutes. clif_displaymessage(fd, atcmd_output); timestamp2string(timestr,20,now+pl_sd->vip.time*60,"%Y-%m-%d %H:%M"); - sprintf(atcmd_output,"%s : %s",msg_txt(sd,707),timestr); //You are VIP until : + sprintf(atcmd_output,"%s : %s",msg_txt(sd,707),timestr); // You are VIP until : %s clif_displaymessage(pl_sd->fd, atcmd_output); + sprintf(atcmd_output, msg_txt(sd,708), pl_sd->status.name); // Player '%s' is now VIP until : %s + strcat(atcmd_output, timestr); clif_displaymessage(fd, atcmd_output); } chrif_req_vipActive(pl_sd, viptime, 3);