Skip to content

Technical Questions

Does Hot Patch require an internet connection?

No. Hot Patch runs entirely inside the Unity Editor. All compilation is done locally with the bundled Roslyn compiler. An internet connection is only needed for optional update checks.

Does it work with code in Unity packages?

Scripts under Assets/ in your project are supported, including code in embedded packages under Assets/.

Scripts in Library/PackageCache/ (registry packages) are not patched. Copy package code into Assets/ if you need to hot-patch it.

Does it work with Editor scripts?

No. Scripts in Editor/ folders and Editor-only assemblies (Assembly-CSharp-Editor, *.Editor asmdefs) are excluded. Hot Patch targets runtime code used by GameObjects during Play Mode.

Move runtime MonoBehaviour scripts to a non-Editor folder such as Assets/Scripts/.

Does it work outside Play Mode?

No. Hot Patch only applies patches while the Editor is in Play Mode with Hot Patch started. Outside Play Mode, use normal Unity compilation.

How does Hot Patch resolve method overloads?

By method name only. If a type has multiple overloads of the same method, Hot Patch cannot distinguish them by signature. Avoid relying on overload-specific patching — rename overloaded methods or use distinct names.

Does it work with assembly definitions (.asmdef)?

Yes, scripts inside asmdef assemblies under Assets/ are patchable, as long as the assembly is a runtime assembly (not Editor-only) and not in the exclusion list. Changing the .asmdef file itself (adding references, changing platforms) requires a full Unity recompile.

Does it work with Roslyn source generators?

Hot Patch compiles from saved source text on disk. It does not re-run source generators. If your code depends on generated code, the generated output must already be present and compilable from the on-disk source.

Does it work with libraries that rewrite IL (Mirror, FishNet, Photon, etc.)?

Hot Patch patches methods in the loaded AppDomain. Methods that third-party frameworks rewrite at compile time via IL weaving may not patch reliably. Ordinary gameplay code, Update, Start, your own methods, is unaffected.

Does it preserve static variables?

Yes. Hot Patch avoids domain reload during Play Mode, so static fields retain their values across patches.

What happens to patches when I exit Play Mode?

All runtime patches are cleared. Harmony hooks are removed. If you changed scripts during Play Mode and Recompile when exiting Play Mode is enabled, Unity recompiles to sync the Editor with disk.

Can I run Hot Patch alongside other hot-reload tools?

Not recommended. Multiple tools competing to block auto-refresh or patch the same methods can cause conflicts. Use one solution at a time.

Does it work on Linux and macOS?

Yes. Hot Patch is a pure Unity Editor extension with bundled cross-platform dependencies. No platform-specific server binary is required.

What Unity versions are supported?

Hot Patch targets modern Unity Editor versions with the Mono scripting backend. It is tested against current LTS and recent Unity 6 releases. Functionality that depends on FindObjectsByType requires Unity 2023.1+; older versions use FindObjectsOfType automatically.

Is Hot Patch safe for production builds?

Hot Patch is an Editor-only debugging tool. The HotPatch.Editor assembly is not included in player builds through normal Unity build filtering. Do not depend on Hot Patch runtime behavior in shipped games.

What third-party libraries does Hot Patch use?
Library Purpose License
Lib.Harmony 2.3.7 Runtime method redirection MIT
Roslyn 4.14 C# compilation MIT

Full notices are in ThirdPartyNotices.txt.