2N Lightning Reload | Edit C# In Play Mode Without Compiling
2NGAMES
$38.49
$54.99
30%OFF
(no ratings)
Jump AssetStore
Edit your C# while the game is running and see it instantly, in the Editor and on Android or standalone builds. No domain reload, no lost scene state, no cloud server, no login.2N Lightning Reload is render-pipeline agnostic: it contains no shaders, materials or renderers, so it works with Built-in, URP, HDRP and any custom SRP without configuration.What does matter for compatibility: Unity 2021.3-6.5, the Mono scripting backend (IL2CPP is not supported), and a Windows editor.Stop losing your game state to a recompile.A normal C# recompile wipes out the runtime state you were working with: the player's position, the scene setup, the exact bug you spent ten minutes reproducing. 2N Lightning Reload patches the running methods instead. You save the file and the game keeps playing with your new code.It works on the device too. The same edit goes straight into a running Android build or a standalone player over your local network. No rebuild, no reinstall.Nothing to sign up for. No account, no license server, no compiler service to download. It compiles with the Roslyn that already ships inside your Unity install, so it works offline and behind a corporate firewall. Import the package, press Play, done.WHAT YOU CAN CHANGE WHILE PLAYINGBrand-new classes, structs, enums and interfaces, even in a new .cs file you write mid-session.Coroutines that are already running, and new Unity messages (Update, OnTriggerEnter and the rest) on types that did not have them before.New MonoBehaviours, added to live objects with AddComponent.Unity Entities systems, SystemBase and ISystem alike, and Burst-compiled jobs.Method bodies: logic, values, loops, LINQ, lambdas, local functions, constructors, properties, generics.async/await, iterators, and exception filters (catch ... when).New methods, new fields, changed signatures, removed members.Code around a network RPC reloads too, and the call still goes over the network. With Netcode for GameObjects, the optional IL post-processor weave can reload the RPC body itself.YOUR DEBUGGER STAYS ATTACHEDKeep Visual Studio attached while you reload. Breakpoints you set after a reload hit, in the method you edited and in the ones around it.BUILT FOR REAL SESSIONSUndo / redo across reloads. Step your code back and forth without retyping anything.A status window that shows what was patched, how long it took, and why something was refused.[OnLightningReload] callbacks and a small public API, so you can hook it into your own tools.Settings live in ProjectSettings, so updating the package never resets them.A typical reload lands well under a second. Reload time scales with the assembly you edited, not with the size of the whole project.TRY IT IN 30 SECONDSOpen Tools > 2N Lightning Reload > Status Window. Drop Samples/LightningReloadDemo.cs on any GameObject and press Play. Change a number in that script and save. The running scene updates without leaving Play mode.REQUIREMENTSWindows editor. Unity 2021.3 to 6.5. Mono scripting backend. On-device: Android (ARMv7 development builds) and standalone players on your local network. IL2CPP and iOS are not supported; live patching needs the Mono scripting backend.A few changes still need a Play restart. When that happens the Console tells you which one and why. The full list is in the README.SUPPORTED OPERATING SYSTEMSWindowsmacOS and Linux support is planned.SUPPORTED UNITY VERSIONS2021.3 LTS, 2022.3 LTS, Unity 6.0, 6.3 and 6.5, with or without domain reload on Play. Verified end to end on all five.SUPPORTED CODE CHANGESNew classes, structs, enums, interfaces and new .cs files mid-sessionCoroutines that are already running, and new Unity messages on types that did not have themNew MonoBehaviours attached to live objectsUnity Entities systems, SystemBase and ISystem (Entities 1.0 to 1.4)Breakpoints set after a reload (Visual Studio 2022)Undo / redo across reloads (Ctrl+Alt+Z / Ctrl+Alt+Y)Method bodies in MonoBehaviours, plain, static and generic classesAdding, renaming or removing methods; changing signatures, return types and accessibilityAdding, editing or removing fields (static values survive the reload)Constructors, properties, events and indexersGeneric methods and generic classes, reference and value typesLambdas, local functions, async/await, iteratorsException filters (catch ... when)Burst-compiled jobs (IJob, IJobFor, IJobParallelFor)Operators, and methods that take or return your own structs and enums (including T? and out), in the Editor and in standalone playersMethods that call a network RPC; RPC bodies with the optional IL post-processor weave (Netcode for GameObjects)Reload on-device (Android and standalone, Mono backend)LIMITATIONSIL2CPP and iOS: not supported. Live patching needs the Mono scripting backend.A few structural edits need a Play restart, for example a changed base type, a new field on a struct or a changed Entities query. The Console names each one, with the reason.Everything else, with the reasoning behind it, is in the README and in the Help tab of the Status Window.AI assistance was used during the development process. AI was also used to write the documentation and to create the visuals.




