{"id":27083726,"url":"https://github.com/eppnet-networking/eppnet","last_synced_at":"2025-04-06T03:18:30.331Z","repository":{"id":193865249,"uuid":"689627322","full_name":"EppNet-Networking/EppNet","owner":"EppNet-Networking","description":"The innovative easy-to-use high performance multiplayer solution","archived":false,"fork":false,"pushed_at":"2025-03-29T05:55:32.000Z","size":24221,"stargazers_count":15,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-29T06:21:37.085Z","etag":null,"topics":["dotnet","enet","enet-csharp","game-development","gamedev","godot","godot-engine","multiplayer","networking","serialization","sockets","unity","unity3d"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/EppNet-Networking.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-09-10T12:19:09.000Z","updated_at":"2025-03-29T05:55:36.000Z","dependencies_parsed_at":"2023-09-22T02:11:40.900Z","dependency_job_id":"92bbb83d-adca-4a9d-a6a3-a4aae40811e6","html_url":"https://github.com/EppNet-Networking/EppNet","commit_stats":null,"previous_names":["xmakerx/eppnet","eppnet-networking/eppnet"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EppNet-Networking%2FEppNet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EppNet-Networking%2FEppNet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EppNet-Networking%2FEppNet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EppNet-Networking%2FEppNet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/EppNet-Networking","download_url":"https://codeload.github.com/EppNet-Networking/EppNet/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247427103,"owners_count":20937231,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dotnet","enet","enet-csharp","game-development","gamedev","godot","godot-engine","multiplayer","networking","serialization","sockets","unity","unity3d"],"created_at":"2025-04-06T03:18:29.809Z","updated_at":"2025-04-06T03:18:30.323Z","avatar_url":"https://github.com/EppNet-Networking.png","language":"C#","readme":"# E++Net (**IN DEV**)\n![Test Status](https://github.com/xMakerx/EppNet/actions/workflows/dotnet.yml/badge.svg)\n\nNot to be confused as an implementation of ENet in C++, E++Net is a C# networking library built on top\nof [ENet-CSharp](https://github.com/nxrighthere/ENet-CSharp/), a C# port of ENet with additional features\nsuch as IPv6 support. \n\n## Features\n- [x] _**No manual data serialization required!**_ Register a custom object, write your methods and properties, and add attributes to let E++Net know how to interact with them.\n\n      **Custom method parameter types unknown to E++Net can be registered. Game engines that don't support `new()`\n      to construct a game object can specify a custom generator to make one properly.**\n- [X] _**Subscription based interest system!**_ Clients only receive updates about objects (and their children) they have interest in. No wasted bandwidth on unnecessary data!\n- [X] _**Tree hierarchy for objects!**_ Objects can have as many children objects as you would like. You can reparent objects on the fly and clients automatically subscribe to new children objects.\n      \n      **Network methods and properties are inherited from base types that declare them!**\n- [X] _**Snapshotting!**_ E++Net keeps track of the last N \"ticks\" of the simulation for interpolation, extrapolation, and to offer a smooth and responsive experience for even the most high latency clients.\n- [X] _**Security!**_ E++Net allows you to implement your own authentication method for newly connected clients, limit what kinds of datagrams they can send, and automatically timeout clients that fail to identify themselves.\n\n      E++Net, by default, is server authoritative and clients only know about the remote server connection.\n      Commands can only be sent by clients if the server explicitly allows it.\n- [X] _**Concurrency!**_ E++Net leverages modern .NET features for high throughput message serialization and deserialization automatically.\n- [X] _**Modular!**_ E++Net is designed to be extendable, easy to maintain, and easy to turn features on and off via a JSON configuration or through code.\n- [X] _**Flexible!**_ Don't like a particular abstraction or service? The API is forgiving and allows changes from your assemblies. Extend an existing type and override existing methods to make it your own!\n\n## Why E++Net?\nE++Net is a high performance, portable, and general-purpose UDP solution designed to abstract away the most frustrating aspects of multiplayer application development -- especially for games. As a multiplayer game\ndeveloper myself, I was absolutely tired of constantly writing different serializables, unique packet or datagram types, and spending a ton of time designing a bunch of data plumbing -- it gets even worse when concurrency\nis involved! Sometimes writing helper classes or extensions methods would save me some work of course, but, in other libraries you might accumulate a bunch of garbage or wasted CPU cycles because you did something the library or framework\ndeveloper didn't expect. The last thing I wanted to do was spend my precious free time doing data plumbing. E++Net is designed to do all the heavy lifting but leave enough flexibility for developers who need to do some fine-tuning.\n\nTake the following pseudo code featuring a client-side implementation of a Player for example.\n```csharp\n// The \"Dist\" flag dictates which distribution should use this implementation. The following\n// attribute setup specifies that this class \"PlayerClient\" should only be used on clients.\n[NetworkObject(Dist = Distribution.Client)]\nclass PlayerClient : ISimUnit {\n\n    // Players will have an integer health property which can be sent by the owner\n    // of the player object.\n    [NetworkProperty(NetworkFlags.Persistant | NetworkFlags.OwnerSend)]\n    public int Health { get; set; }\n\n    // Players will also require a position to be generated. The snapshot\n    // network flag tells E++Net to enable interpolation and extrapolation, and\n    // store the value of the getter along with the current snapshot time. Synchronization\n    // is done automatically and the snapshot flag implies persistance. \n    [NetworkMethod(NetworkFlags.Required | NetworkFlags.Snapshot)]\n    public void SetPosition(Vector3 position) {}\n\n    // Where's the attribute you ask? E++Net is smart enough to locate getter methods\n    // if they have an identical name to the setter except with \"get\" instead of \"set\".\n    public Vector3 GetPosition() {}\n}\n```\nE++Net will take care of the rest!\n\n### FAQ\n\n\u003e ## Is E++Net intended to be used with a particular game engine such as Godot or Unity?\n\u003e **No!** E++Net is a general purpose networking library with portability in mind. In the future, I intend on making demos or optional extension packages for specific game engines.\n\u003e\n\u003e ## Does E++Net support multi-threading?\n\u003e **Yes!** E++Net internally utilizes [System.Threading.Channels](https://learn.microsoft.com/en-us/dotnet/core/extensions/channels) for high throughput messaging.\n\u003e\n\u003e ## Is E++Net memory or bandwidth intensive?\n\u003e E++Net leverages [Microsoft's RecyclableMemoryStreams](https://github.com/microsoft/Microsoft.IO.RecyclableMemoryStream) (memory stream pooling) and stack allocated byte arrays for datagram reading and writing.\n\u003e This means that E++Net does not create garbage when reading or writing from a datagram. E++Net only updates remote clients about objects and events they've subscribed to.\n\u003e\n\u003e ## How does E++Net handle seemingly unknown object types at runtime? Isn't reflection slow?\n\u003e E++Net uses compiled expression trees to manipulate objects which is several orders of magnitude faster than standard reflection or an `Activator#CreateInstance()` approach when generating objects. However,\n\u003e this comes as a tradeoff for slower startup times as time is needed to compile the necessary expressions for object generation and manipulation.\n\n\n### Inspiration\n\nThis project has been inspired by:\n- [Online Theme Park System (Panda3D's Distributed Networking System)](https://docs.panda3d.org/1.10/python/programming/networking/distributed/index)\n- [Valve's Game Networking Sockets](https://github.com/ValveSoftware/GameNetworkingSockets)\n\n### Special Thanks\n- [Tanner Gooding](https://github.com/tannergooding) Microsoft .NET Team - Architecture advice\n- [Stuart Turner](https://github.com/viceroypenguin) - Architecture advice\n- [Brian Lach](https://github.com/lachbr) - For listening to my ramblings, rants, and giving advice\n- [Stanislav Denisov](https://github.com/nxrighthere/) - Creator and Maintainer of C# port of ENet\n- [Lee Salzman](https://github.com/lsalzman) - Creator of ENet (to my knowledge)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feppnet-networking%2Feppnet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feppnet-networking%2Feppnet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feppnet-networking%2Feppnet/lists"}