Skip to content
This repository was archived by the owner on Nov 27, 2025. It is now read-only.

MrVenumX/AURA

Repository files navigation

AURA

GitHub GitHub Platform

A C++ library focused on the Il2Cpp runtime wrapper.

AURA is a C++ library that provides a simple wrapper for the Il2Cpp runtime, specifically designed for Unity games on Android Platform.

Getting Started ⚙️

Usage in Existing Projects

To add AURA to existing projects, run this command below.

git submodule add https://github.com/MrVenumX/AURA.git

Installation 📦

Prerequisites

  • Android NDK (latest)
  • C++17 or later

To get started, include AURA sources in your project's build configurations. You can build manually or download the prebuilt static library from the releases page.

Basic Usage 🛠️

We provide basic examples of how to use AURA in the example/ directory.

Initialization

To initialize AURA, call AURA::API::InitializeAPIs() and attach to the Il2Cpp thread.

auto handle = dlopen("libil2cpp.so", RTLD_LAZY);
AURA::API::InitializeAPIs(handle);

AURA::Thread::Attach();
/* your code here... */
AURA::Thread::Detach();

⚠️ Warning: Thread must be attached to Il2Cpp thread before access other AURA functionality to avoid a crash.

Getting An Image

To get an Image, use AURA::Image(). It provides easy and simple access to all classes inside the Assembly.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");

if(AssemblyCSharp.IsValid()) {
  /* Do something if valid... */
}

⚠️ Warning: Ensure the name of Image don't include .dll extension.

Getting A Class

To get a Class, use AURA::Class(). It provides easy and simple access to all fields and methods.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");

if(Player.IsValid()) {
  /* Do something if valid... */
}

Getting A Field

To get a Field, use AURA::Field<T>(). It provides easy and simple access to the field.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto Money = AURA::Field<int>(Player, "Money");

if(Money.IsValid()) {
  /* Do something if valid... */
}

Modify and Access A Non-Static Field

To modify or access a non-static Field, use this code below.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto Money = AURA::Field<int>(Player, "Money");

if(Money.IsValid()) {
  Money.GetValue(playerInstance);
  Money.SetValue(playerInstance, 999999);
}

Modify and Access A Static Field

To modify or access a static Field, use this code below.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto Money = AURA::Field<int>(Player, "Money");

if(Money.IsValid()) {
  Money.GetStaticValue()
  Money.SetStaticValue(999999);
}

⚠️ Warning: Method Field.SetStaticValue() often cause a crash, we recommended you careful at using it to avoid crash.

Getting A Method

To get a Method, use AURA::Method<Ret, Parameters>(). It provides easy and simple access to the method.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto getHealth = AURA::Method<int>(Player, "get_health");

if(getHealth.IsValid()) {
  /* Do something if valid... */
}

Invoking A Non-Static Method

To invoking a non-static Method, use this code below.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto getHealth = AURA::Method<int>(Player, "get_health");

if(getHealth.IsValid()) {
  auto health = getHealth.Invoke(playerInstance);
}

Invoking A Static Method

To invoking a static Method, use this code below.

const auto AssemblyCSharp = AURA::Image("Assembly-CSharp");
const auto Player = AURA::Class(AssemblyCSharp, "Player");
const auto getHealth = AURA::Method<int>(Player, "get_health");

if(getHealth.IsValid()) {
  auto health = getHealth.InvokeStatic();
}

License

This project is licensed under the MIT license; see LICENSE for more information.