Maple.Native
0.1.0
dotnet add package Maple.Native --version 0.1.0
NuGet\Install-Package Maple.Native -Version 0.1.0
<PackageReference Include="Maple.Native" Version="0.1.0" />
<PackageVersion Include="Maple.Native" Version="0.1.0" />
<PackageReference Include="Maple.Native" />
paket add Maple.Native --version 0.1.0
#r "nuget: Maple.Native, 0.1.0"
#:package Maple.Native@0.1.0
#addin nuget:?package=Maple.Native&version=0.1.0
#tool nuget:?package=Maple.Native&version=0.1.0
Maple.Native
MapleStory GMS v95 native type layouts and runtime mutation primitives: ZArray, ZXString, ZFatalSection, StringPool lock helpers, and x86 allocator contracts. Foundation layer for maple-memory and maple-client-v95. Cross-platform, trimmable and AOT/NativeAOT compatible.
⭐ Please star this project if you like it. ⭐
Example | Example Catalogue | Public API
Example
// Allocate a synthetic x86 address space for testing native types out-of-process.
using var allocator = new InProcessAllocator();
// Allocate a ZXString (ANSI ref-counted string) and read it back.
var strAddr = ZXString.Create(allocator, "MapleStory");
var alloc = ZXString.Allocate(allocator, "MapleStory");
ZXString.Destroy(allocator, strAddr);
ZXString.Destroy(allocator, alloc.ObjectAddress);
// Allocate a wide (UTF-16) string.
var wideAddr = ZXStringWide.Create(allocator, "메이플스토리");
ZXStringWide.Destroy(allocator, wideAddr);
// Spin-lock round-trip: acquire the StringPool lock, then release.
var pool = NativeStringPool.AllocateEmpty(allocator, slotCount: 4);
using (NativeStringPoolLock.Acquire(allocator, pool.ObjectAddress, maxSpinCount: 100))
{
var locked = NativeStringPoolLock.Read(allocator, pool.ObjectAddress);
_ = locked.TibPointer; // non-zero while held
}
NativeStringPool.Destroy(allocator, pool, destroyNarrowStrings: false, destroyWideStrings: false);
For more examples see Example Catalogue.
Benchmarks
Benchmarks.
Detailed Benchmarks
Comparison Benchmarks
TestBench Benchmark Results
Results will be populated here after running dotnet Build.cs comparison-bench then dotnet test
Example Catalogue
The following examples are available in ReadMeTest.cs.
Example - Empty
// Allocate a synthetic x86 address space for testing native types out-of-process.
using var allocator = new InProcessAllocator();
// Allocate a ZXString (ANSI ref-counted string) and read it back.
var strAddr = ZXString.Create(allocator, "MapleStory");
var alloc = ZXString.Allocate(allocator, "MapleStory");
ZXString.Destroy(allocator, strAddr);
ZXString.Destroy(allocator, alloc.ObjectAddress);
// Allocate a wide (UTF-16) string.
var wideAddr = ZXStringWide.Create(allocator, "메이플스토리");
ZXStringWide.Destroy(allocator, wideAddr);
// Spin-lock round-trip: acquire the StringPool lock, then release.
var pool = NativeStringPool.AllocateEmpty(allocator, slotCount: 4);
using (NativeStringPoolLock.Acquire(allocator, pool.ObjectAddress, maxSpinCount: 100))
{
var locked = NativeStringPoolLock.Read(allocator, pool.ObjectAddress);
_ = locked.TibPointer; // non-zero while held
}
NativeStringPool.Destroy(allocator, pool, destroyNarrowStrings: false, destroyWideStrings: false);
Public API Reference
See docs/PublicApi.md for the complete auto-generated public API reference.
Note:
docs/PublicApi.mdis auto-updated by theReadMeTest_PublicApitest on everydotnet testrun. Do not edit it manually.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- No dependencies.
NuGet packages (3)
Showing the top 3 NuGet packages that depend on Maple.Native:
| Package | Downloads |
|---|---|
|
Maple.Memory
Allocator adapters and higher-level process-memory tooling for Maple client analysis and mutation. |
|
|
Maple.StringPool
Zero-allocation decoder for the MapleStory GMS v95 StringPool singleton. Cross-platform, trimmable and AOT/NativeAOT compatible. |
|
|
Maple.Client.V95.Analysis
Snapshot-backed x86 runtime function disassembly helpers for MapleStory GMS v95 client analysis. Windows-only, trimmable and AOT/NativeAOT compatible. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0 | 223 | 3/26/2026 |