# jacksondunstan/UnityNativeScripting

Unity Scripting in C++

Repository: https://github.com/jacksondunstan/UnityNativeScripting
Canonical: https://ross.abutalabs.com/products/unitynativescripting
Homepage: https://jacksondunstan.com/articles/3938
Language: C#
License: MIT
License Family: permissive
Topics: unity3d, unity3d-script, unity3d-development, cpp, csharp, pinvoke, il2cpp, unity, unity-editor, unity-scripts
Last push: 2021-03-06T18:42:34+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3315, "days_push": 2006, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1375, forks 134 (observed 2026-08-28T04:04:33.083884+00:00)

## What it is
A library that lets Unity developers write game scripts in native C++ (or C/assembly) instead of C#, communicating via P/Invoke bindings. It provides bindings and code generation so C++ code can act like MonoBehaviour scripts while avoiding Unity's garbage collector and IL2CPP build overhead.

## Use cases
- write unity game scripts in c++
- avoid unity garbage collector frame hitches
- speed up unity build and compile times
- use simd intrinsics in unity game code
- replace c# game logic with native plugin
- hot reload c++ code in unity editor

## When to choose
- you need deterministic performance without Unity's garbage collector
- slow IL2CPP build times are hurting iteration speed
- you want direct control over machine code, SIMD, or assembly in a Unity game

## When to avoid
- your team is C#-only and not comfortable with C++
- you rely heavily on .NET APIs, generics, or C# ecosystem tooling
- you need long-term support or frequent updates - the project has not seen releases since 2021

## Facets
- artifact type: library
- maturity: maintenance
- function: game-engine, plugin-system, sdk
- domain: developer-tools, performance
- platform: cpp, c, cross-platform, game-engine
- tags: unity, il2cpp, pinvoke, native-plugins, cpp-scripting, garbage-collector-avoidance, game-development

## Member repositories
- jacksondunstan/UnityNativeScripting (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:33.083884+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:40:34.234601+00:00, confidence not recorded.
  - readme: https://github.com/jacksondunstan/UnityNativeScripting (fetched 2026-08-28T04:04:33.083884+00:00, sha 7b1f57f7566e)
  - homepage: https://jacksondunstan.com/articles/3938 (fetched 2026-08-29T11:56:55.625694+00:00, sha b5978d3ef2fb)
  - site_page: https://www.jacksondunstan.com/about (fetched 2026-08-29T11:56:55.635801+00:00, sha fc07314b16a1)
- Data as of 2026-08-30T08:39:29.467469+00:00.
