Skip to content
This repository has been archived by the owner on Mar 5, 2021. It is now read-only.

[WIP] .NET Core migration #15

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
115 changes: 12 additions & 103 deletions Common/Common.csproj
Original file line number Diff line number Diff line change
@@ -1,114 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{63268176-7FF9-4B3E-AAAD-CC7C329F924A}</ProjectGuid>
<TargetFramework>netcoreapp3.1</TargetFramework>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Common</RootNamespace>
<AssemblyName>Common</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="ICSharpCode.SharpZipLib, Version=1.2.0.246, Culture=neutral, PublicKeyToken=1b03e6acf1164f73, processorArchitecture=MSIL">
<HintPath>..\packages\SharpZipLib.1.2.0\lib\net45\ICSharpCode.SharpZipLib.dll</HintPath>
</Reference>
<Reference Include="MySql.Data, Version=7.0.2.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL">
<HintPath>..\packages\MySql.Data.7.0.2-DMR\lib\net45\MySql.Data.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.configuration" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<PackageReference Include="Portable.BouncyCastle" Version="1.8.5.2" />
<PackageReference Include="Google.Protobuf" Version="3.11.2" />
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
<PackageReference Include="MySql.Data" Version="8.0.18" />
<PackageReference Include="SharpZipLib" Version="1.2.0" />
<PackageReference Include="SSH.NET" Version="2016.1.0" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="4.6.0-preview4.19164.7" />
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
</ItemGroup>
<ItemGroup>
<Compile Include="Constants\AuthCodes.cs" />
<Compile Include="Constants\Enums.cs" />
<Compile Include="Constants\Structs.cs" />
<Compile Include="Constants\UpdateFields.cs" />
<Compile Include="Constants\Opcodes.cs" />
<Compile Include="Cryptography\Srp6.cs" />
<Compile Include="Database\BaseContext.cs" />
<Compile Include="Database\DBC\CustomTypes\Unused.cs" />
<Compile Include="Database\DBC\DBC.cs" />
<Compile Include="Database\DBC\Reader\BinaryReaderExtensions.cs" />
<Compile Include="Database\DBC\Reader\DBHeader.cs" />
<Compile Include="Database\DBC\Reader\DBReader.cs" />
<Compile Include="Database\DBC\Reader\DBReaderExtensions.cs" />
<Compile Include="Database\DBC\Structures\AreaTable.cs" />
<Compile Include="Database\DBC\Structures\BankBagSlotPrices.cs" />
<Compile Include="Database\DBC\Structures\CharBaseInfo.cs" />
<Compile Include="Database\DBC\Structures\CharStartOutfit.cs" />
<Compile Include="Database\DBC\Structures\ChrProficiency.cs" />
<Compile Include="Database\DBC\Structures\ChrRaces.cs" />
<Compile Include="Database\DBC\Structures\EmotesText.cs" />
<Compile Include="Database\DBC\Structures\FactionTemplate.cs" />
<Compile Include="Database\DBC\Structures\Lock.cs" />
<Compile Include="Database\DBC\Structures\LockType.cs" />
<Compile Include="Database\DBC\Structures\SkillLine.cs" />
<Compile Include="Database\DBC\Structures\SkillLineAbility.cs" />
<Compile Include="Database\DBC\Structures\Spell.cs" />
<Compile Include="Database\DBC\Structures\SpellCastTimes.cs" />
<Compile Include="Database\DBC\Structures\SpellDuration.cs" />
<Compile Include="Database\DBC\Structures\SpellRadius.cs" />
<Compile Include="Database\DBC\Structures\SpellRange.cs" />
<Compile Include="Database\DBC\Structures\WorldSafeLocs.cs" />
<Compile Include="Database\TableAttributes.cs" />
<Compile Include="Helpers\Flag.cs" />
<Compile Include="Helpers\Quaternion.cs" />
<Compile Include="Helpers\Vector.cs" />
<Compile Include="Logging\Log.cs" />
<Compile Include="Logging\LogTypes.cs" />
<Compile Include="Network\ByteConverter.cs" />
<Compile Include="Network\Packets\PacketReader.cs" />
<Compile Include="Network\Packets\PacketWriter.cs" />
<Compile Include="Network\Packets\UpdateClass.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Singleton\Singleton.cs" />
<Compile Include="Singleton\SingletonBase.cs" />
<Compile Include="Helpers\Extensions.cs" />
<Compile Include="Constants\FormulaData.cs" />
</ItemGroup>
<ItemGroup>
<None Include="app.config">
<SubType>Designer</SubType>
</None>
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
</Project>
8 changes: 0 additions & 8 deletions Common/packages.config

This file was deleted.

1 change: 1 addition & 0 deletions WorldServer/Game/Structs/GameObjectStructs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System.Text;
using System.Threading.Tasks;

#pragma warning disable CS0169
namespace WorldServer.Game.Structs
{
// 0 GAMEOBJECT_TYPE_DOOR
Expand Down
1 change: 1 addition & 0 deletions WorldServer/Game/Structs/PlayerStructs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
using System.Linq;
using System.Text;

#pragma warning disable CS0169
namespace WorldServer.Game.Structs
{
[Table("playercreateinfo")]
Expand Down
1 change: 1 addition & 0 deletions WorldServer/Game/Structs/UnitStructs.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using Common.Constants;

#pragma warning disable CS0169
namespace WorldServer.Game.Structs
{
public class UnitStructs
Expand Down
142 changes: 12 additions & 130 deletions WorldServer/WorldServer.csproj
Original file line number Diff line number Diff line change
@@ -1,149 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}</ProjectGuid>
<TargetFramework>netcoreapp3.1</TargetFramework>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>WorldServer</RootNamespace>
<AssemblyName>WorldServer</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>x86</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="MySql.Data, Version=7.0.2.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL">
<HintPath>..\packages\MySql.Data.7.0.2-DMR\lib\net45\MySql.Data.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="ICSharpCode.SharpZipLib">
<HintPath>..\packages\SharpZipLib.1.2.0\lib\net45\ICSharpCode.SharpZipLib.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Game\Commands\CommandParser.cs" />
<Compile Include="Game\Commands\ConsoleManager.cs" />
<Compile Include="Game\Commands\GameMasterCommands.cs" />
<Compile Include="Game\Globals.cs" />
<Compile Include="Game\Managers\ChatManager.cs" />
<Compile Include="Game\Objects\Account.cs" />
<Compile Include="Game\Objects\Container.cs" />
<Compile Include="Game\Objects\GameObject.cs" />
<Compile Include="Game\Objects\Group.cs" />
<Compile Include="Game\Managers\InventoryManager.cs" />
<Compile Include="Game\Objects\Player.cs" />
<Compile Include="Game\Objects\Creature.cs" />
<Compile Include="Game\Objects\Item.cs" />
<Compile Include="Game\Objects\PlayerExtensions\FriendExtension.cs" />
<Compile Include="Game\Objects\PlayerExtensions\LootExtension.cs" />
<Compile Include="Game\Objects\PlayerExtensions\QuestExtension.cs" />
<Compile Include="Game\Objects\PlayerExtensions\SkillExtension.cs" />
<Compile Include="Game\Objects\PlayerExtensions\TradeExtension.cs" />
<Compile Include="Game\Objects\SpellEffect.cs" />
<Compile Include="Game\Objects\UnitExtensions\FactionExtension.cs" />
<Compile Include="Game\Objects\UnitExtensions\SpellExtension.cs" />
<Compile Include="Game\Objects\UnitExtensions\TalentExtension.cs" />
<Compile Include="Game\Objects\Quest.cs" />
<Compile Include="Game\Objects\Unit.cs" />
<Compile Include="Game\Structs\AreaTrigger.cs" />
<Compile Include="Game\Structs\CreatureStructs.cs" />
<Compile Include="Game\Structs\CreatureTemplate.cs" />
<Compile Include="Game\Structs\GameObjectStructs.cs" />
<Compile Include="Game\Structs\GameObjectTemplate.cs" />
<Compile Include="Game\Structs\ItemStructs.cs" />
<Compile Include="Game\Structs\ItemTemplate.cs" />
<Compile Include="Game\Structs\QuestTemplate.cs" />
<Compile Include="Game\Managers\GridManager.cs" />
<Compile Include="Game\Managers\StatManager.cs" />
<Compile Include="Game\Objects\WorldObject.cs" />
<Compile Include="Game\Structs\PlayerStructs.cs" />
<Compile Include="Game\Structs\SpellStructs.cs" />
<Compile Include="Game\Structs\UnitStructs.cs" />
<Compile Include="Network\RealmManager.cs" />
<Compile Include="Network\RealmSocket.cs" />
<Compile Include="Network\WorldManager.cs" />
<Compile Include="Packets\HandlerDefinitions.cs" />
<Compile Include="Packets\Handlers\AuthHandler.cs" />
<Compile Include="Packets\Handlers\CharHandler.cs" />
<Compile Include="Packets\Handlers\ChatHandler.cs" />
<Compile Include="Packets\Handlers\CreatureHandler.cs" />
<Compile Include="Packets\Handlers\FriendHandler.cs" />
<Compile Include="Packets\Handlers\GameObjectHandler.cs" />
<Compile Include="Packets\Handlers\GroupHandler.cs" />
<Compile Include="Packets\Handlers\ItemHandler.cs" />
<Compile Include="Packets\Handlers\LootHandler.cs" />
<Compile Include="Packets\Handlers\MiscHandler.cs" />
<Compile Include="Packets\Handlers\MovementHandler.cs" />
<Compile Include="Packets\Handlers\NetHandler.cs" />
<Compile Include="Packets\Handlers\NPCHandler.cs" />
<Compile Include="Packets\Handlers\QuestHandler.cs" />
<Compile Include="Packets\Handlers\SpellHandler.cs" />
<Compile Include="Packets\Handlers\TradeHandler.cs" />
<Compile Include="Packets\Handlers\WorldHandler.cs" />
<Compile Include="Packets\PacketManager.cs" />
<Compile Include="Storage\DatabaseExtension.cs" />
<Compile Include="Storage\DbSet.cs" />
<Compile Include="Storage\GroupedDbSet.cs" />
<Compile Include="Storage\Database.cs" />
<Compile Include="WorldServer.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Game\Structs\Worldports.cs" />
<Compile Include="Game\Structs\Ticket.cs" />
<ProjectReference Include="..\Common\Common.csproj" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Common\Common.csproj">
<Project>{63268176-7ff9-4b3e-aaad-cc7c329f924a}</Project>
<Name>Common</Name>
</ProjectReference>
<Compile Remove="Game\Objects\PlayerExtensions\TalentExtension.cs" />
</ItemGroup>
<ItemGroup>
<Compile Include="Network\WorldSocket.cs" />
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
<PackageReference Include="MySql.Data" Version="8.0.18" />
<PackageReference Include="Newtonsoft.Json" Version="9.0.1" />
<PackageReference Include="SharpZipLib" Version="1.2.0" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="4.6.0-preview4.19164.7" />
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
</Project>
48 changes: 35 additions & 13 deletions alpha-legends.sln
Original file line number Diff line number Diff line change
@@ -1,26 +1,48 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 11
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorldServer", "WorldServer\WorldServer.csproj", "{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}"
# Visual Studio 15
VisualStudioVersion = 15.0.26124.0
MinimumVisualStudioVersion = 15.0.26124.0
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorldServer", "WorldServer\WorldServer.csproj", "{2DA91CA0-C422-4D6B-B332-0A951D794B5B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Common", "Common\Common.csproj", "{63268176-7FF9-4B3E-AAAD-CC7C329F924A}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Common", "Common\Common.csproj", "{D28848AD-884A-48AE-A152-6DEF4CA82427}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{63268176-7FF9-4B3E-AAAD-CC7C329F924A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{63268176-7FF9-4B3E-AAAD-CC7C329F924A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{63268176-7FF9-4B3E-AAAD-CC7C329F924A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{63268176-7FF9-4B3E-AAAD-CC7C329F924A}.Release|Any CPU.Build.0 = Release|Any CPU
{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B736A574-F0AD-43D2-BF24-A54EDC0BCD6B}.Release|Any CPU.Build.0 = Release|Any CPU
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|x64.ActiveCfg = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|x64.Build.0 = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|x86.ActiveCfg = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Debug|x86.Build.0 = Debug|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|Any CPU.Build.0 = Release|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|x64.ActiveCfg = Release|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|x64.Build.0 = Release|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|x86.ActiveCfg = Release|Any CPU
{2DA91CA0-C422-4D6B-B332-0A951D794B5B}.Release|x86.Build.0 = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|x64.ActiveCfg = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|x64.Build.0 = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|x86.ActiveCfg = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Debug|x86.Build.0 = Debug|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|Any CPU.Build.0 = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|x64.ActiveCfg = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|x64.Build.0 = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|x86.ActiveCfg = Release|Any CPU
{D28848AD-884A-48AE-A152-6DEF4CA82427}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
EndGlobal