Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Python For Unity?

Discussion in 'General Discussion' started by sxa, Jun 12, 2019.

  1. sxa

    sxa

    Joined:
    Aug 8, 2014
    Posts:
    741
    (Note : this isnt about the old Boo scripting, or embedding Python in Unity)

    Would anyone know where I can find more information about the relatively new 'Python For Unity' that's being mooted in the context of using Unity in 3D pipelines for film and animation (ie as per https://unity.com/solutions/film-animation-cinematics)

    I have had a dig through the forums and Googled etc, but everything gets bogged down in either ancient stuff on Boo or embedding some flavour of Python, rather than this new Editor API,

    For those who dont know what Im talking about, UT's description is this:


    Cheers.
     
  2. Schubkraft

    Schubkraft

    Unity Technologies

    Joined:
    Dec 3, 2012
    Posts:
    1,070
    Python for the editor is currently in a private/closed alpha state and being worked on. It will follow the usual flow of beta/experimental/preview releases as it moves along. Once it is publicly available there'll be further communication about it and feedback will be appreciated at https://forum.unity.com/categories/betas-experimental-features.86/

    Sorry if that isn't what you are hoping for, but we're actively working on it.
     
    Ryiah, Amon and Mauri like this.
  3. sxa

    sxa

    Joined:
    Aug 8, 2014
    Posts:
    741
    No its absolute fine, and thanks for responding... I clearly hadnt picked up that it was a closed alpha.
     
  4. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    1,158
    The link has been missing. Is it was moved somewhere?
     
  5. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
  6. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    Dang it.... Prepare for a future on the forums where people ask you for help, you give help, then they ask you to please rewrite your help for them in python. Over and over.
     
    RecursiveFrog likes this.
  7. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
    "This release is built primarily as a tool for pipeline TDs at studios. There is currently no intention to make Python a scripting language for Gameplay."
     
    Joe-Censored likes this.
  8. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    1,158
    Well, I have seen somewhere that this was mention ironpython. What I am going to say might not be related but somehow I felt like we could grab any python, build dll with ironpython, then it should be possible to use it in unity with IL2CPP (or even mono) anyway?
     
  9. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    20,966
    Yes. Any language that compiles down into .NET's CIL (Common Intermediate Language) can be used with Unity. That said to my knowledge the only example of how to do it is the tutorial made for using F#.

    https://jacksondunstan.com/articles/5058

    Before I end the post I feel it's important to disclaimer the above with a statement to anyone wanting to use it that unofficial languages will almost assuredly receive no support from Unity. If anything breaks with regards to code it will be solely up to you to fix it. Furthermore next to no one in this community will be able to assist you with it.

    Thus in my opinion there are very few reasons why you should ever waste your time trying to use a language other than C#.
     
    Last edited: May 18, 2020
    Thaina likes this.
  10. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
    Sure. IronPython targets Python 2, though, so you'll have to live with that.
     
  11. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    1,158
    For now there is ML agents, and also some other interesting library that has no support in C# but exist in python. I have struggle implement it in C# but if I could compile it to ironpython then that might be more comfortable
     
  12. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
    aer0ace likes this.