Conversation
A second UPM package variant for projects that run stock ClojureCLR in the editor and ship MAGIC only in player builds. It is identical to sg.flybot.magic.unity except the 46 runtime *.clj.dll plugins carry a !UNITY_EDITOR define constraint, so Unity excludes them from the editor by construction. That removes the "Assembly is incompatible with the editor" narration the default variant prints on every domain reload in a coexistence project, while keeping the stock-ClojureCLR probe guard (#25) satisfied: the fork runtime stays out of the editor, so stock RT's clojure.core.clj probe cannot resolve it. Player builds are unaffected; the constraint holds in the player context, so IL2CPP still discovers and ships the runtime. Clojure.dll and Magic.Runtime.dll keep editor loading so the Runtime asmdef still compiles in the editor. Generated from magic-unity by bb gen-unity-dual (added in the tooling commit); the DLLs are byte-identical copies, only the 46 metas and package.json differ. Closes #30
…ce repro bb gen-unity-dual generates magic-unity-dual from magic-unity; bb check-drift keeps it in sync. magic-unity-coexist + bb coexist-noise reproduce the coexistence noise in-repo without the private consumer project. Logic in bb/magic/unity.clj.
Relocate magic-unity-smoke and magic-unity-coexist into unity-examples/; the magic-unity and magic-unity-dual packages stay top-level. Update the smoke manifest/lock pin, coexist-proj in bb/magic/unity.clj, the .gitignore exception, and the doc links; regenerate magic-unity-dual. Rename the comp:magic-unity-smoke label to comp:unity-examples (CONTRIBUTING.md).
docs/unity-integration.md is the consumer-side Unity guide (install, variant choice, coexistence, IL2CPP, examples), cross-linking magic-unity. The root README gains a magic-unity-dual Components row and points its Unity section at the new guide.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
v0.7.0 - 2026-06-09
A second Unity package variant for projects that keep stock ClojureCLR as the editor runtime.
Magic.Unity
sg.flybot.magic.unity.dualvariant: the runtime*.clj.dllcarry a!UNITY_EDITORdefine constraint, so Unity excludes them from the editor and a coexistence project no longer logs theAssembly is incompatible with the editorlines on every domain reload. The defaultsg.flybot.magic.unityis unchanged and still runs MAGIC in editor Play mode - #30.docs/unity-integration.mdcovers the consumer workflow and how to choose a variant.Tooling
bb gen-unity-dualgenerates the dual variant frommagic-unity(drift-checked bybb check-drift);bb coexist-noisereproduces the console noise in-repo viaunity-examples/magic-unity-coexist. Example Unity projects moved underunity-examples/.