Hey!

With the holidays coming up, I’m sharing a fully functional, complete N2PLAY server package, ready to run and further develop.

Package Optimization
Original compressed leak size: ~17 GB
Final compressed size (after my optimization): ~5–6 GB
Clean, well-organized structure
Ready to work immediately after download

Package Contents

Bin
Recompiled Game Client
No packs – perfect for further modifications

data
Full, unpacked client
FoxFS Archiver
Modified .bat files from original N2
➜ allow full and correct client packing

proto_create
New, rewritten data structure responsible for:
items
mobs
objects
collisions
Main proto files:
cube_proto
– New structure responsible for cube (crafting system in Metin)
item_attr_proto_server
– New structure responsible for item bonuses (1–5)
item_attr_rare_proto_server
– New structure responsible for item bonuses (6–7)
item_proto_server
– New structure responsible for in-game items
mob_proto_server
– New structure responsible for mobs / objects / NPCs
object_proto_server
– New structure responsible for building-type objects, collisions, etc.
refine_proto
– New structure responsible for the upgrade system
skill_proto_server
– New structure responsible for skills and passive skills on the server
Overall, thanks to these structures, client-server communication works smoother and better.
This is clearly noticeable in PvP – no delays when casting skills, etc.

skrypt_questowy_multilanguage
Rewritten quest parser
Automatic quest generation in multilanguage mode

source_SERVER_BIN
Contains:
ready-to-use SQL files
recompiled Windows server

Changes & Fixes
Slightly rebuilt structure compared to the original leak
Client:
slightly modified
fixed known bugs
Package prepared for local work on Windows

64-bit & TOP Optimization
Full 64-bit architecture
Entire ProtoBuff rewritten
One of the best client optimizations available

Practical Results:

Game start: ~1 second (from login to entering the game)
Smooth:
transitions between loading screens
teleportation between maps
texture rendering
font loading
model loading and rendering

No:
FPS drops during long gameplay
lags when loading objects or cities
black screens after long AFK

Very fast client file loading – even from HDD
… and much more

Memory Addressing
32-bit
Max ~4 GB RAM (realistically ~2–3 GB on Windows)
64-bit
Theoretically several TB of RAM (system-limited)

This results in more stable client and server performance with:
larger maps
more players
larger databases

GUIDES

Server Setup – Windows

Required Components Installation
Python
python-2.7.18.amd64.msi
(skip if you already have this version or newer)
MariaDB
mariadb-11.3.2-winx64.msi
Root password:
dev
(if you want to keep the default package configuration)

Database Import and PATH
In the SQL folder you will find:
ready, fixed databases
a .bat script that:
adds MariaDB to PATH
imports .sql files
Script credentials:
host: 127.0.0.1
login: root
password: dev

Server Startup
File:
admin_panel.bat
Location:
source_SERVER_BIN\windows_server

The panel runs in a single CMD window (no millions of processes).
From the panel you can:
start / stop the server
manage MariaDB
check process status
clean logs
compile quests
create symlinks for the new structure

Run as administrator

Client Packing – FoxFS
Folder:
data
Packing the entire client:
pakuj_wszystko.bat
Packing a single pack:
pakuj_po_nazwie.bat
Adding new files:
wygeneruj_nowe_xml.bat
→ then pack

Proto Structure Packing
Folder:
proto_create
After packing:
client proto →
data/source/root/data
server proto →
proto_create/proto_server
Transfer:
Windows
source_SERVER_BIN\windows_server\common\data\proto_server
FreeBSD
/root/server/share/data/proto_server

Quest Parser – Multilanguage
Place quest files into:
skrypt_questowy_multilanguage
Run:
start.bat
Finished quest will be placed into:
multilanguage

For custom functions, add them to:
quest_parser.pl

SRC Compilation

Windows
Installation:
cmake-3.16.0-rc1-win64-x64.msi
Folder:
source_SERVER_BIN\source
Open CMakeLists.txt → cmake.exe
Open:
metin2.sln
mode: RELEASE
86 projects
Build Solution

FreeBSD
cd /root/server
sh panel.sh build

Environment
Client:
Visual Studio 2019
CMake v3.16
Python 2.7.18
Cython
Server:
FreeBSD 13.2-RELEASE amd64
cmake, ninja, llvm11
Source:
CMake
Python API: PyBind
Database:
MariaDB 11.3.2
Windows Server 2022 x64
Game Client:
x64

Login Credentials
FreeBSD:
login: root
password: dev
MariaDB / MySQL:
login: root
password: 123123
Download Files:
Download Virtualbox:
[Hidden content]
[Hidden content]