Merge from sourcemod-1.2 branch.
This commit is contained in:
@@ -55,6 +55,13 @@ bool SmUpdater::SDK_OnLoad(char *error, size_t maxlength, bool late)
|
||||
sharesys->AddDependency(myself, "webternet.ext", true, true);
|
||||
|
||||
SM_GET_IFACE(WEBTERNET, webternet);
|
||||
|
||||
const char *url = smutils->GetCoreConfigValue("AutoUpdateURL");
|
||||
if (url == NULL)
|
||||
{
|
||||
url = DEFAULT_UPDATE_URL;
|
||||
}
|
||||
update_url.assign(url);
|
||||
|
||||
ThreadParams params;
|
||||
params.flags = Thread_Default;
|
||||
@@ -67,13 +74,6 @@ bool SmUpdater::SDK_OnLoad(char *error, size_t maxlength, bool late)
|
||||
return false;
|
||||
}
|
||||
|
||||
const char *url = smutils->GetCoreConfigValue("AutoUpdateURL");
|
||||
if (url == NULL)
|
||||
{
|
||||
url = DEFAULT_UPDATE_URL;
|
||||
}
|
||||
update_url.assign(url);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -139,7 +139,7 @@ static void PumpUpdate(void *data)
|
||||
smutils->BuildPath(Path_SM, path, sizeof(path), "gamedata/%s", part->file);
|
||||
if (libsys->IsPathDirectory(path))
|
||||
{
|
||||
continue;
|
||||
goto skip_create;
|
||||
}
|
||||
if (!libsys->CreateFolder(path))
|
||||
{
|
||||
@@ -157,7 +157,7 @@ static void PumpUpdate(void *data)
|
||||
if (fp == NULL)
|
||||
{
|
||||
AddUpdateError("Could not open %s for writing", path);
|
||||
return;
|
||||
goto skip_create;
|
||||
}
|
||||
if (fwrite(part->data, 1, part->length, fp) != part->length)
|
||||
{
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -124,7 +124,7 @@
|
||||
AdditionalIncludeDirectories="..;..\sdk;..\..\..\public;..\..\..\public\sourcepawn;..\..\..\public\extensions;"$(MMSOURCE17)\core\sourcehook""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;SDK_EXPORTS;_CRT_SECURE_NO_DEPRECATE;SOURCEMOD_BUILD;ORANGEBOX_BUILD;_CRT_NONSTDC_NO_DEPRECATE"
|
||||
RuntimeLibrary="0"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -206,7 +206,7 @@
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -286,7 +286,7 @@
|
||||
AdditionalIncludeDirectories="..;..\sdk;..\..;..\..\sourcepawn;"$(HL2SDK)\public";"$(HL2SDK)\public\dlls";"$(HL2SDK)\public\engine";"$(HL2SDK)\public\tier0";"$(HL2SDK)\public\tier1";"$(MMSOURCE17)\core-legacy";"$(MMSOURCE17)\core-legacy\sourcehook""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;SDK_EXPORTS;_CRT_SECURE_NO_DEPRECATE;SOURCEMOD_BUILD;SOURCE_ENGINE=2"
|
||||
RuntimeLibrary="0"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -369,7 +369,7 @@
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -449,7 +449,7 @@
|
||||
AdditionalIncludeDirectories="..;..\sdk;..\..;..\..\sourcepawn;"$(HL2SDKOB)\public";"$(HL2SDKOB)\public\engine";"$(HL2SDKOB)\public\game\server";"$(HL2SDKOB)\public\tier0";"$(HL2SDKOB)\public\tier1";"$(MMSOURCE17)\core";"$(MMSOURCE17)\core\sourcehook""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;SDK_EXPORTS;_CRT_SECURE_NO_DEPRECATE;SOURCEMOD_BUILD;SOURCE_ENGINE=3"
|
||||
RuntimeLibrary="0"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -532,7 +532,7 @@
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -612,7 +612,7 @@
|
||||
AdditionalIncludeDirectories="..;..\sdk;..\..;..\..\sourcepawn;"$(HL2SDKL4D)\public";"$(HL2SDKL4D)\public\engine";"$(HL2SDKL4D)\public\game\server";"$(HL2SDKL4D)\public\tier0";"$(HL2SDKL4D)\public\tier1";"$(MMSOURCE17)\core";"$(MMSOURCE17)\core\sourcehook""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;SDK_EXPORTS;_CRT_SECURE_NO_DEPRECATE;SOURCEMOD_BUILD;SOURCE_ENGINE=4"
|
||||
RuntimeLibrary="0"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -695,7 +695,7 @@
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
@@ -775,7 +775,7 @@
|
||||
AdditionalIncludeDirectories="..;..\sdk;..\..;..\..\sourcepawn;"$(HL2SDK)\public";"$(HL2SDK)\public\dlls";"$(HL2SDK)\public\engine";"$(HL2SDK)\public\tier0";"$(HL2SDK)\public\tier1";"$(MMSOURCE17)\core";"$(MMSOURCE17)\core\sourcehook""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;SDK_EXPORTS;_CRT_SECURE_NO_DEPRECATE;SOURCEMOD_BUILD;SOURCE_ENGINE=2"
|
||||
RuntimeLibrary="0"
|
||||
EnableEnhancedInstructionSet="1"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
|
||||
Reference in New Issue
Block a user