-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Possible to get this working on Unity 5? #1
Comments
Oh, sorry to hear that. I haven't used Unity 5 more so I'm not sure. Please tell me if you figure something out and I can put it into the guide for everyone else! Also, I guess we're all hoping that they will bump the .NET version soon so that we can use a newer version of F# etc. That might take years though, they've just said it's gonna happen at some point in the future... |
Actually I've figured this out now (on both 4.x and 5.x). The key was to stop trying to use F# DLLs installed by the Homebrew "fsharp" package, and exclusively use the libraries included with Unity in the MonoDevelop.app folder. To summarize: For FSharp.Core, System and System.Core: For UnityEngine: For FSharp.Core, you need to set "Local Copy" on the reference, but not for the others. If you target the project directly into Assets, that's all you need to do. If you follow the custom build command approach, you need to make sure to copy both your library dll (MyFSharpLib.dll) and FSharp.Core to Assets (I created 2 separate after build custom commands for this). |
OK, great! |
Using VS Unity Extensions you can compile directly using Unity as target (using maybe only web modules etc.). |
I've attempted to follow these steps for Unity 5.0.2 on Mac with no luck. One issue is the version of FSharp.Core.dll - there does not appear to be one for 2.3.0 as mentioned in the writeup. I've tried used one from 4.0 and 4.5 also with no luck. Even downloaded the DLL from this repo. But in all cases I can't seem to build the project & my .fs files show with errors in MonoDevelop.
The text was updated successfully, but these errors were encountered: