Upgrade to VS 2017

* Fix a few compile errors too.
This commit is contained in:
Nabil M 2018-11-03 13:59:25 -02:30
parent 1c2859a59d
commit 2ccf3531f2
6 changed files with 535 additions and 533 deletions

View file

@ -1,6 +1,6 @@
EF2GameSource
=============
The original EF2GameSource updated so it compiles under Visual Studio 2012 and Linux
The original EF2GameSource updated so it compiles under Visual Studio 2017 and Linux
Also see original readme.txt

View file

@ -1196,7 +1196,7 @@ class Actor : public Sentient {
bool IsFinishable();
str getName() const override
{
return name;
return name;
}
void SendEventToGroup(Event* ev);

View file

@ -14,6 +14,7 @@
*
*****************************************************************************/
#include <cmath>
#include "g_local.h"
#include "q_shared.h"
@ -512,7 +513,7 @@ void BotSetInfoConfigString(bot_state_t *bs) {
break;
}
}
gi.setConfigstring (CS_BOTINFO + bs->client, va("l\\%s\\c\\%s\\a\\%s",
gi.setConfigstring (CS_BOTINFO + bs->client, va("l\\%s\\c\\%s\\a\\%s",
leader,
carrying,
action));
@ -767,7 +768,7 @@ void BotChangeViewAngles(bot_state_t *bs, float thinktime) {
//
if (bot_challenge.integer) {
//smooth slowdown view model
diff = abs(AngleDifference(bs->viewangles[i], bs->ideal_viewangles[i]));
diff = std::fabs(AngleDifference(bs->viewangles[i], bs->ideal_viewangles[i]));
anglespeed = diff * factor;
if (anglespeed > maxchange) anglespeed = maxchange;
bs->viewangles[i] = BotChangeViewAngle(bs->viewangles[i],
@ -871,7 +872,7 @@ void BotInputToUserCommand(bot_input_t *bi, usercmd_t *ucmd, int delta_angles[3]
//set the view independent movement
ucmd->forwardmove = (signed char) (DotProduct(forward, bi->dir) * bi->speed);
ucmd->rightmove = (signed char) (0 - DotProduct(right, bi->dir) * bi->speed);
ucmd->upmove = (signed char) (abs(forward[2]) * bi->dir[2] * bi->speed);
ucmd->upmove = (signed char) (std::fabs(forward[2]) * bi->dir[2] * bi->speed);
//normal keyboard movement
if (bi->actionflags & ACTION_MOVEFORWARD) ucmd->forwardmove += 127;
if (bi->actionflags & ACTION_MOVEBACK) ucmd->forwardmove -= 127;

View file

@ -246,7 +246,7 @@ void BotSayTeamOrderAlways(bot_state_t *bs, int toclient) {
//don't show the message just put it in the console message queue
gi.BotGetChatMessage(bs->cs, buf, sizeof(buf));
ClientName(bs->client, name, sizeof(name));
Com_sprintf(teamchat, sizeof(teamchat), EC"(%s"EC")"EC": %s", name, buf);
Com_sprintf(teamchat, sizeof(teamchat), EC"(%s" EC ")" EC ": %s", name, buf);
gi.BotQueueConsoleMessage(bs->cs, CMS_CHAT, teamchat);
}
else {

File diff suppressed because it is too large Load diff

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
@ -30,41 +30,42 @@
<SccProjectName>"$/EF2/game", FYHAAAAA</SccProjectName>
<SccLocalPath>.</SccLocalPath>
<ProjectGuid>{AD2B91AF-BE5E-4D64-952C-5F061241380D}</ProjectGuid>
<WindowsTargetPlatformVersion>10.0.17134.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Demo Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release CDROM|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Intel Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='VTune|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v120</PlatformToolset>
<PlatformToolset>v141</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>