MeikelLP / quantum-core-x

Metin2 open source server implementation
https://meikellp.github.io/quantum-core-x/
Mozilla Public License 2.0
35 stars 9 forks source link

Some general questions #155

Closed PoLaKoSz closed 2 months ago

PoLaKoSz commented 2 months ago

Hi!

The past few days i have been reading the source code to get a high level overview and i would like to ask a few questions if You don't mind:

Thank You!

MeikelLP commented 2 months ago
* Auth and the Game implemented as background tasks in two ASP.NET Core web servers. Can i ask why? Already available dependency injection, appSettings.json and other configuration possibilities?

ASP.NET Core is only used in the Auth executable to provide an endpoint for the game app to retrieve information about accounts (security tbd)

* Is there any benchmark about the speed difference between the original C++ implementation and Quantum Core X?

No. Sadly no.

However there is a Simulator (load tester) for the original quantum core C++ app. You may be able to check that out if you are interested. However keep in mind that both implementations are in early stages.

There are no benchmarks that compare the original official metin2 implementation and this C# implementation. It's also not the goal of this app to be "faster" as a competitive feature. The goal is to make this app as performant as possible without losing any convenience.

* Can i ask why are there 22 projects instead of 2-3? Possible faster compilation on code changes?

Mostly for code structuring and possible extensions via plugins in the future. The c# compiler is pretty smart and fast and can compile incrementally (no code changes = no compile). There is no real reason we need 22 projects but it doesn't really hurt either. Quite common in c# projects I would say. Also 22 projects != 22 executables

* Shouldn't the Redis cache implementation be better hidden in the repository layer?

Yes. Well the redis/db part is a thing that needs heavy refactoring. Right now some of the state is stored in redis and some in the db. That needs some cleanup!

* Couldn't compile the master ([3443f04](https://github.com/MeikelLP/quantum-core-x/commit/3443f0405f86061c380f60ac0e1086c640d5890e)) branch. Could someone take a look at it, plase?
/quantum-core-x/src/Executables/Game/MonsterManager.cs(50,50): error CS0246: The type or namespace name 'MobProto' could not be found (are you missing a using directive or an assembly reference?) [/quantum-core-x/src/Executables/Game/Game.csproj]
/quantum-core-x/src/Executables/Game/MonsterManager.cs(14,17): error CS0246: The type or namespace name 'MobProto' could not be found (are you missing a using directive or an assembly reference?) [/quantum-core-x/src/Executables/Game/Game.csproj]
   3 Warning(s)
   2 Error(s)

Thank You!

You missed a step in the Getting started

Generate required files

This issue happens quite often for new people. I don't know why but I also don't really know how to fix it.

PoLaKoSz commented 2 months ago

Thank You for the answers!

I was so exited for the C# implementation i just jumped to compile it without reading the readme ... sorry :smiley:

MeikelLP commented 2 months ago

Thank You for the answers!

I was so exited for the C# implementation i just jumped to compile it without reading the readme ... sorry 😃

Yes that's a big bummer. I wanna remove that dependency (or at least automate it)