Iam1337 / CrabNet

CrabNet is a cross platform, open source, C++ networking engine for game programmers.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CrabNet - networking engine for game programmers

⚙ Build And Release semantic-release: angular

Table of Contents

Introduction

Fork based on CrabNet. Made to work with StolenNetwork framework, the main difference is the presence of a simplified wrapper.

This fork is not compatible with the original RakNet.

Notes:

  • The Help directory contains index.html, which provides full documentation and help
  • The Source directory contain all files required for the core of CrabNet and is used if you want to use the source in your program or create your own dll
  • The Samples directory contains code samples and one game using an older version of RakNet. The code samples each demonstrate one feature of CrabNet. The game samples cover several features.

Build

The instructions are based on the personal experience of the developer and may not be accurate. It would be really cool if someone could improve the assembly instructions.

Windows

This example shows how to build release x64 libraries for Windows.

Required:

PowerShell:

# Create build directory
mkdir build-win
cd build-win

# Setup project
# You can build 32-bit library using instead of x64 - Win32
cmake -G "Visual Studio 16 2019" -A x64 ..

# Build library
cmake --build . --config Release --clean-first

Android (on Windows)

This example shows how to build release arm64-v8a libraries for Android on Windows platform. Best for building libs for Oculus Quest and Oculus Quest 2.

Required:

PowerShell:

# Create build directory
mkdir build-android
cd build-android

# Download and unpack Android NDK
# You can skip these steps if you already have Android NDK
Invoke-WebRequest "https://dl.google.com/android/repository/android-ndk-r23-windows.zip" -OutFile "android-ndk.zip"
Expand-Archive -Path "android-ndk.zip" -DestinationPath .

# Setup project
# If you skipped the steps to download the Android NDK, then you need to replace the path in CMAKE_TOOLCHAIN_FILE with your own. 
cmake -G Ninja -DCMAKE_TOOLCHAIN_FILE="android-ndk-r23/build/cmake/android.toolchain.cmake" -DANDROID_ABI=arm64-v8a -DANDROID_PLATFORM=23 ..

# Build library
cmake --build . --config Release --clean-first

Android (on Linux)

This example shows how to build release arm64-v8a libraries for Android on Linux platform.

Required:

Terminal:

# Create build directory
mkdir build-android
cd build-android

# Download and unpack Android NDK
# You can skip these steps if you already have Android NDK
wget https://dl.google.com/android/repository/android-ndk-r23-linux.zip
unzip android-ndk-r23-linux.zip

# Setup project
# If you skipped the steps to download the Android NDK, then you need to replace the path in CMAKE_TOOLCHAIN_FILE with your own. 
cmake -DCMAKE_TOOLCHAIN_FILE="android-ndk-r23/build/cmake/android.toolchain.cmake" -DANDROID_ABI=arm64-v8a -DANDROID_PLATFORM=23 ..

# Build library
cmake --build . --config Release --clean-first

Linux

The developer tested this method on Arch Linux under WSL2.

Required:

Terminal:

# Create build directory
mkdir build-linux
cd build-linux

# Setup project
cmake ..

# Build project
cmake --build . -config Release --clean-first

License

This project is under the BSD License.

Copyright (c) 2014, Oculus VR, Inc. (original RakNet)
Copyright (c) 2016-2018, TES3MP Team
Copyright (c) 2021, Sigalkin Vladimir

About

CrabNet is a cross platform, open source, C++ networking engine for game programmers.

License:Other


Languages

Language:C 43.4%Language:C++ 36.8%Language:HTML 5.2%Language:C# 4.7%Language:Shell 4.7%Language:Makefile 2.1%Language:CMake 0.8%Language:SWIG 0.7%Language:Roff 0.4%Language:Assembly 0.3%Language:M4 0.1%Language:CSS 0.1%Language:Python 0.1%Language:Batchfile 0.1%Language:SAS 0.1%Language:WebAssembly 0.1%Language:Module Management System 0.1%Language:XSLT 0.1%Language:Objective-C 0.1%Language:Java 0.0%Language:Smalltalk 0.0%Language:StringTemplate 0.0%Language:Inno Setup 0.0%Language:JavaScript 0.0%Language:Perl 0.0%