Maxora v1.0.0 🚀
We are incredibly excited to announce the first official release of Maxora!
Maxora is a highly optimized, production-ready open.mp component for querying MaxMind DB (.mmdb) databases directly from Pawn scripts. It brings instant IP geolocation lookups (such as Country, City, ASN, and ISP) to high-concurrency servers without introducing latency or garbage collection overhead.
🔥 Key Features
- Zero Heap Allocations: Executes all hot paths (reading from AMX, preparing paths, and querying the database) entirely on the C++ stack using fixed-size buffers and
thread_localmemory arrays. It performs 0 dynamic heap allocations per query. - Extreme Performance: Leverages Memory-Mapped I/O (
MMDB_MODE_MMAP) for instantO(depth)lookups directly from disk cache. - Atomic Hot-Swaps: Safely reload the
.mmdbdatabase on the fly. If a corrupted file is provided, Maxora gracefully rejects it while keeping the existing database alive, preventing live server crashes. - Native
StringViewIntegration: Implements strict bounds checking and utilizes open.mp's nativeStringViewfor 100% memory-safe AMX string operations. - Localized Stock Helpers: Includes built-in Pawn macros (
MMDB_LANG_SPANISH,MMDB_LANG_ENGLISH, etc.) to easily extract names in multiple languages.
📦 Installation
- Download
maxora.dll(Windows) orlibmaxora.so(Linux) from the assets below. - Place the component in your open.mp
componentsfolder. - Add
maxorato thecomponentssection of yourconfig.json. - Include
maxora.incin your Pawn script. - Download a GeoLite2 Free Database (e.g.
GeoLite2-City.mmdb) and place it in your server root.
💻 Quick Example
#include <open.mp>
#include <maxora>
main()
{
if (MMDB_Load("GeoLite2-City.mmdb"))
{
new country[64];
new const ip[] = "8.8.8.8";
// Extract localized country name instantly!
if (MMDB_GetCountryName(ip, country, sizeof(country), MMDB_LANG_SPANISH))
{
printf("Country (Spanish): %s", country);
}
}
}Full Changelog: https://github.com/itskoleban/Maxora/commits/v1.0.0