Search Unity

Unity's version control component has been upgraded to Plastic SCM.

Scene Merging

Discussion in 'Unity Collaborate' started by JohnRossitter, Jan 31, 2017.

  1. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Why does this not work?

    I work on a scene and a team member works on a scene.
    Its silly that we have to take turns, why does scene merging not work in Collaborate?
    Accept mine? Useless, I dont get their changes
    Accept Theirs? Useless, I lose my changes.
    Launch external tool? Useless as there are no merging markers in the file
    Manually launch the UnityYamlTool? Seriously, has anyone ever used this?

    Collaborate is great for handling script changes, but come on, Unity is about Scenes and assets.
    Can you all please do something about this massive plot hole in Collaborate?
     
    Last edited: Jan 31, 2017
    ricarious and ModLunar like this.
  2. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Don't everyone jump on this at once now...
     
  3. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi John!

    We know that merging scenes is still a hassle, especially for those really large, complicated scenes. That's why we are looking into merge tools that can help alleviate that stress point. We hope to have more info on this in the coming months.
     
  4. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Slow Clap.....
     
  5. Genesis4545

    Genesis4545

    Joined:
    Jan 31, 2017
    Posts:
    7
    What exactly do you mean by "Scene Merging"? Is your point that collab doesn't have an internal merging tool or is there some problem with merging scenes specifically? I'm confused since in their tutorial they say that you have to solve merging conflicts with an external tool, which I'm fine with, but that would imply that there's no issue with merging if you're willing to use an external tool, right?

    I'm just trying to clarify things about collab since I really would rather not use github =P
     
  6. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    Specifically I mean that I have a many scenes that are upwards of 30 megs in size, not tiny but not really that big.
    If someone one else on my team want to work on the scene and moves somethings around, the next time I get the code, there is a merge conflict.

    1) problem is that there is no head data in the files, so doing a merge is just about impossible even with merging tools
    2) who is their right mind has the time to manually manage a 30 meg file merge, every time there is a change?

    Collaborate does not merge (automatically) Scenes or prefabs because for whatever reason it can't deal with YAML files.
    Granted it can merge binary files just fine.

    Using a git client is sometimes easier, but I have a bunch of artist an my team and I just wont subject them to that.

    My point is, that this should have been issue number one for Collaborate.
    I dont see how it has gone so for so long with not being addressed.
    If they could fix this, it would completely make using Collaborate 100% worth the effort.
     
    ricarious likes this.
  7. Genesis4545

    Genesis4545

    Joined:
    Jan 31, 2017
    Posts:
    7
    I see. Thank you very much for clarifying ^^ I agree that this should've been adressed much sooner, from the get-go would've been nice =P
     
  8. DevinW

    DevinW

    Joined:
    Jun 19, 2014
    Posts:
    37
    This isn't a Collaborate issue - this is a problem across all types of version control.

    And Unity has already publicly stated that it's in their roadmap for collab. You're welcome to read over https://docs.unity3d.com/Manual/SmartMerge.html

    Not being able to merge scene has been apart of Unity development for a long time and studios have found many work arounds. When my studio was working with Unity Asset Server we used Trello for scene checkouts so the team knew who was working on what scenes.

    At first this seems really inefficient but in reality once you start working with it you realize you hardly ever actually need to commit a scene. Most of us on the team work with prefabs exclusively and only the need scene for a few seconds at a time to maybe add those prefabs if they are not already there. We use prefab spawners as a solution around nested prefabs as well.

    Hope this helps, but here's a slow clap for you're inability to do research /slow clap...

    Edit: It also makes me laugh when I see people post their problems and state that their issue needs to be priority #1 before doing their homework, it's like you're rubbing someone's nose in a problem while seeking to be the center of the world instead of simply leaving a humble request.
     
    Last edited: Feb 9, 2017
  9. JohnRossitter

    JohnRossitter

    Joined:
    Dec 18, 2013
    Posts:
    1,027
    I did plenty of research.
    It's a huge pain in the butt...always has been.
    But it's a massive hole in collaborate, a source control system by unity for unity, for a company that quote solves the hard problems, it's a massive black eye that they can't figure out a way to merge the scene structure they created.

    Still slow clapping
     
  10. DevinW

    DevinW

    Joined:
    Jun 19, 2014
    Posts:
    37
    Also in related new the latest build preview has offered a elegant solution to the ugly trello card scene checkout system I mentioned before.

    " "In Progress" Soft Locks
    Last but not least on the list, you can now see when teammates are making changes locally to a scene or a prefab. In the Assets window, you'll be able to see an indicator when changes are in progress by someone else, helping to avoid conflicts. "

    https://forum.unity3d.com/threads/c...d-available-now-exciting-new-features.443913/
     
    Ryan-Unity likes this.
  11. mowax74

    mowax74

    Joined:
    Mar 3, 2015
    Posts:
    97
    @John Rossitter: I'm with you: still slow clapping.
    And a slow clap as well for DevinWs explanation.

    We talking about merging scenes, not locking scenes. That's a cheap attempt to get around the lacking feature of proper scene merging.
    Unity claims to be the number one game engine. What, if you have a team of at least 50, with different sub teams, that work on different branches on different features - parallel - not sequentially. Testing stuff, and later, everything needs to come back to the main development branch. In that situations its completely normal, that you have different versions of your scene(s). As normal, as having different versions of your code files, with the difference, that you can easyly merge the script files.
    but it's a pain, if not impossible, to get everything together in the unity scenes.
    Locking works, if you develop one feature after an other, with a maximum count of 5 developers.

    There was a nice little asset called uni merge for unity. It did kind of a good job merging the scenes. but its not working anymore in unity 2017.1.
    Because unity would not be unity, if they wouldn't change things under the hood undocumented all the time, that brings everything to not work anymore, and leaves developer back, testing around why everything is not working anymore, instead of having a documented list of changes.
     
    fwenner, sp-LeventeLajtai and Tieco like this.
  12. Rich_A

    Rich_A

    Joined:
    Nov 22, 2016
    Posts:
    338
    So, its been a year now, do we have it?
     
    ModLunar likes this.
  13. Bzarka

    Bzarka

    Joined:
    Apr 9, 2018
    Posts:
    1
    Sorry to be a buzzkill but we're in the same boat so probably no unity still don't have it. Right now we're just trying our best to merge scene and fix our scripts and etc
     
    ModLunar likes this.
  14. Stankiem

    Stankiem

    Joined:
    Dec 4, 2013
    Posts:
    115
    Unfortunately our team is gonna ditch collab, we were hoping this would fix our scene merge issues but still having the same problems as other more powerful version control solutions. This really needs to be fixed for all types of version control. It's been our biggest headache since we started using Unity.
     
    sp-LeventeLajtai and ModLunar like this.
  15. acr1378

    acr1378

    Joined:
    Dec 4, 2014
    Posts:
    76
    @ryanc-unity It's been almost two years now. What is the status on scene merges with collaborate? We have been having a ton of problems with collaborate, and they seem to stem mostly from the scenes not merging properly. It's been bad enough that we may switch to GitHub.
     
    ModLunar and Marc-Saubion like this.
  16. Marc-Saubion

    Marc-Saubion

    Joined:
    Jul 6, 2011
    Posts:
    655
    @acr1378 , switch to github.

    None of the collaborate features anounced in the last two years have been released and new bugs preventing us to use that service won't be fixed for months.
     
    sp-LeventeLajtai, jrumps and Rich_A like this.
  17. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @acr1378! Apologies for the delayed response. Every QA in Unity just came back from a Quality Week where we could share our knowledge, talk to customers and get a better perspective on the current quality of Unity and how to start improving it. (FYI we know there are a lot of issues and we're all working hard to deal with them as quickly as possible). Thank you for your patience.

    We know that scene merging is a hotly requested feature, one that all source control options struggle with. We have been looking into drastically overhauling how merging is handled on the backend so that it'll be easier to use, more consistent with its results and easier to debug when something goes wrong. We can't give an exact ETA on this feature yet but it is something that we want to bring to everyone using Collab.

    An established workaround for many teams using Unity has been to specify a master version of scenes, making copies of them to work in (either as separate scene files or as branches in whichever VCS they're using) and ensuring that changes are only merged in by one user at a time, using task trackers to specify who your merge master will be at any given time. This helps to reduce the bottleneck that can come up from merge conflicts and helps to minimize non-reviewed changes from getting into master. It's one that I've used in previous projects to great effect.
     
  18. Omzy

    Omzy

    Joined:
    Jun 28, 2013
    Posts:
    31
    I think in the interim that soft locks or even hard locks (which could be dismissed by the team admin) would be a good temporary solution. This doesn't fix the productivity losses from not being able to work on scenes at the same time, but would at least ensure that conflicts don't happen in the first place.
     
    Ryan-Unity likes this.
  19. StaceyH

    StaceyH

    Administrator

    Joined:
    Apr 11, 2018
    Posts:
    44
    @Omzy: Collaborate supports soft locks today, though it is referred to as In-Progress edit notifications within the manual. You can read more here.

    As @ryanc-unity mentions, the concept of merging scenes is not something that is Collaborate specific - this is a problem seen by all version control solutions. While on the surface, merging asset files might sound like a simple problem, it is actually incredibly complex to do correctly. We (Unity) are aware that it needs to be solved to help teams of all sizes work better together, and we have begun looking at ways to do so. Due to the complexities of it, we do not have an ETA or anything to share just yet
     
    Last edited: Feb 27, 2019
  20. Omzy

    Omzy

    Joined:
    Jun 28, 2013
    Posts:
    31
    I would think that if you ever intend to allow scene merging, you might as well go all the way and turn it into its own full feature for concurrent scene editing, like what you can do in HeroEngine. Multiple artists can join a scene session and edit it together, immediately seeing changes from the other person in real-time.
     
  21. JoshuaWhittaker

    JoshuaWhittaker

    Joined:
    Apr 9, 2018
    Posts:
    1
  22. Doronn

    Doronn

    Joined:
    Sep 17, 2018
    Posts:
    8
    Although sounds nice, it's actually a really bad idea in most cases.
    It may be fine between artists, but for development, the consistency of a scene is crucial.
    But a clean way to merge scene would surely be great.
     
  23. DanVioletSagmiller

    DanVioletSagmiller

    Joined:
    Aug 26, 2010
    Posts:
    204
    To share some of the complexities Unity faces with scene merging, Think of this scenario.
    A scene has 1 object(A), with a child object(B). (B) has a script. There is also a second root object(C).
    with a structure like this:
    ObjA
    - Parent null
    ObjB
    - Parent ObjA
    - Script:something.cs
    - - Value1 = "1"
    ObjC
    - Parent null

    Editor1 -> renames B to D, and moves it to C
    Editor2 -> changes settings on B

    Files look something like this:
    Editor1 FILE:
    ObjA
    - parent null
    ObjC
    - parent null
    ObjD // <-- note the change here
    - Parent ObjC
    - Script:something.cs
    - - Value1 = "1"

    Editor2 FILE:
    ObjA
    - Parent null
    ObjB
    - Parent ObjA
    - Script:something.cs
    - - Value1 = "2"
    ObjC
    - Parent null

    The merge tools only have the end files to look at, and none of the logic that placed them. For us, looking at the knowledge of how these moved, it is easy to understand, but imagine dozens of these changes. How is the merge tool supposed to know if ObjB and D are the same? If it is supposed to delete ObjB and put in ObjD?

    The argument is that each of these have ID's, Guids associated with them, so moving should be easy to determine, but that is not straight forward, as the structure is duplicated in the file. I have concepts that could simplify this, and have considered writing it before, such as Sort the save file by GUID, so that that object ID order is maintained, and most merge files will work with it, then save each one with a path to where it reloads. Merge tools would handle that structure much better. But, my guess is that Unity will attempt to come up with a serious improvement at the same time, and I'm curious as to what that might be.

    When they resolved many of the asset bundle frustrations with addressables, it had a profound improvement in build time for artists vs devs, as well as a great separation of concerns. In addition to auto script execution after bundle pull in, and auto streaming setup. I look forward to what they come up with, as it will likely include things I didn't think of, but save a great deal of work and/or provide new creative opportunities.
     
    sp-LeventeLajtai and Brumrum like this.
  24. mgh7654321

    mgh7654321

    Joined:
    Dec 29, 2019
    Posts:
    2
    Still a major issue in 2020...-Does Unity even work on collab anymore?
     
  25. Rich_A

    Rich_A

    Joined:
    Nov 22, 2016
    Posts:
    338
    Its up to developers to setup scenes correctly, reducing monolithism as much as possible. This is just good practice independent of what version control can and can't do.

    For example: where possible have all of these in individual scenes:

    - Backgrounds
    - UI
    - Game Logic (in standalone asset files)
    - Levels
    - Intros
    - Outros

    So far the best merging functionality I've seen is from Plastic SCM.
     
    glenneroo and sp-LeventeLajtai like this.
  26. barisalhan

    barisalhan

    Joined:
    Mar 29, 2020
    Posts:
    3
    Still the same. Painful merge processes...

    It causes lots of productivity and energy loss.
     
  27. superjayman

    superjayman

    Joined:
    May 31, 2013
    Posts:
    185
    WHY IS COLLABORATE SOOO FREAKIN ANNOYING AND BUGGY???... IT MESSED UP 2 of my projects. WARNING: COLLAB IS DANGEROUS TO USE.... Whats going on Unity, why haven't you guys sorted out the mess from almost 3 years ago..
     
    Marc-Saubion likes this.
  28. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @barisalhan, Unity is actively looking into ways of making the merge process for scenes and prefabs easier. We know it's a painful process right now and we want to make it easier and more reliable for everyone.

    Hi @superjayman, I'm sorry you're having issues with Collab. Could you open a new thread with details on what issues you ran into? It would be very helpful for us in figuring out what went wrong.
     
  29. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    774
    I don't have a team, but I have several project files containing scenes that I'd like to merge into one master project. The problem is that they share many of the same assets - scripts, textures, materials, prefabs - often having different GUIDs for the same items. This results in either my existing or merged assets getting nuked after a merge, losing textures, scripts, or other critical references. The existing import tool tells you when there are GUID mismatches, but offers few remedies: either overwrite the existing GUIDs, preserving the merged assets, but killing the existing ones, or keep the existing ones, at the expense of the merged ones. If there was a third option - pick either the existing or merged asset as the new "standard" version, and reconcile the GUIDs so that both the existing and merged references to that asset use the chosen version, while keeping all components intact - that would be awesome.

    I know I've just described a very basic version control system, but it seems like it should not only be achievable, but should have been a feature a long time ago. There's no complex rules required - the user chooses whether to use the new or existing asset, or not import it at all in each case. Once the choice is made, all Unity needs to do is let any scene elements that reference that asset know where to find it.

    None of this would matter if Unity provided more information about missing assets. When all it tells you is that a script or texture or material is missing, without telling you what it was called, it's often difficult to track down the missing item. Why can't there be a master lookup table somewhere that says this GUID refers to an item with this user friendly name, just to give you a starting point when 5 scripts are suddenly missing from a prefab, and you can't remember what they all were?

    Another ugly situation I noticed recently: After merging a scene containing several existing SpeedTrees, several prefabs that included them listed them as missing, and included placeholder dummy objects that identified them by name. Cool, it should be easy then to just replace them with the newly merged versions. Wrong. While the names were preserved, the transforms were all set to zero - so the placement of the trees within the parent prefabs were all lost. GUIDs are great for providing quick look-ups of assets at runtime, but there should really be a slower, but more complete accounting of asset relationships kept somewhere, that can be used to re-link things when the GUIDs fail.
     
    Last edited: Sep 2, 2020
  30. Ryan-Unity

    Ryan-Unity

    Joined:
    Mar 23, 2016
    Posts:
    1,993
    Hi @FargleBargle, this is fantastic feedback and I'm sorry that you have to deal with situations like this on the regular. I will pass this along to the Co-Create team, which is working on improving Unity's scene merging capabilities, so that they will be considerate of issues like these. If you have any other feedback around merging, or would like to discuss those issues further with the product manager for the team, then feel free to DM me so that I can connect you with them.
     
  31. sebastianq04

    sebastianq04

    Joined:
    Jul 4, 2019
    Posts:
    1
    It's been years, please someone fix I want to merge scenes. Is there really no external program or package that can be used with Unity to merge 2 scenes?
     
  32. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    647
    Any update about Merging scene tool? When it will be available?
     
  33. eon-yogiwp

    eon-yogiwp

    Joined:
    Oct 25, 2018
    Posts:
    2
    Any update on this?
     
  34. drcrck

    drcrck

    Joined:
    May 23, 2017
    Posts:
    328
    No updates but I'm sure they are still "actively looking into ways of making the merge process for scenes and prefabs easier." We probably should just wait another 3 years
     
  35. InteractivaStudios

    InteractivaStudios

    Joined:
    Apr 28, 2013
    Posts:
    19
    Haha, I was reading that this thread was in 2017 and Unity was looking into adding a merge tool... yeah right... 2021 and still square zero
     
  36. Gamedel

    Gamedel

    Joined:
    May 7, 2017
    Posts:
    6
  37. ADmr0

    ADmr0

    Joined:
    Jul 28, 2020
    Posts:
    3
    still this tool is not working properly...
     
  38. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    774
    With the Unity 2022.1 tech release, and Unity 2021 going to LTS, I was hoping there had been some movement on this issue. No sign in either release, or the roadmap that anyone is even working on it though. What has this "Co-Create team" you speak of been doing all this time? After a year and a half, my separate scenes still sit in separate projects, and that looks like where they'll stay, until I find time to break them down and import each asset piecemeal so they can be manually recreated in my main project. There really needs to be a better way.
     
  39. Marc-Saubion

    Marc-Saubion

    Joined:
    Jul 6, 2011
    Posts:
    655
    I'm not sure what you guys are talking about.

    Plastic scm manage scenes merging. It's been around for a long time now. This might be why you don't see anything on the road map.
     
  40. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    774
    Plastic SCM is a third party solution that you need to pay a subscription for if your project is more than 5GB in size. This is to cover the cost of cloud storage, as well as a lot of other "pro" features I don't really want or need. What I do want is something native, that can be deployed locally on my own hardware, that provides basic merge capabilities. As stated earlier, when the existing importer encounters duplicate assets with different GUIDs, it will either break the one being imported, or the one already in the project. There is no third option, other than to cancel the import and manually reconcile the two assets. @Ryan-Unity said they had a team working on improving this behavior, but after a year and a half, all I see is fingers pointing to paid, third party solutions. I'd love to get a job where I could pass the buck like that. :rolleyes:
     
  41. Marc-Saubion

    Marc-Saubion

    Joined:
    Jul 6, 2011
    Posts:
    655
    Plastic was already bought by unity almost two years ago when you sent your first message. You should have switched from collaborate forever ago.

    And you can use local storage for free with Plastic (I strongly recommend against it as you'd lose your project if your hard drive fails).
     
  42. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    774
    1. I don't use Collaborate.
    2. Hard drive failure isn't a concern since I do regular backups to another computer.
    3. If local storage is an option, they sure don't promote it: https://www.plasticscm.com/pricing - maybe because they don't make any money from it? In any case, I can't find any information about it on their site.

    Plastic SCM, GIT, Perforce, and most other version control software are designed more for studios than individuals. They all have way more features than I'll ever need, and are unnecessarily complicated to set up and use. I don't have an "asset pipeline", or different departments I need to share assets with. It's just me doing everything. I don't need a full version control package. All I need is a way to import assets from one project into another without breaking them. This seems like a pretty reasonable thing to ask for. And since someone from Unity said they had a team working on it, is a year and a half later too soon to ask for an update on their progress?

    All I see on the Plastic SCM site are cloud editions, which cost from $0/mo to $23/mo + additional storage. For a project like mine, which has over 50GB of assets, that would amount to an additional $15/mo or more, even if I were using the "free" edition. That's why I prefer local storage. For less than I'd pay for the first year's subscription, I can buy 3 1TB hard drives, giving me all the storage my project will ever need, plus 2 backups. But since I already have lots of drives, I don't even need to do that. If they offer a free solution that can be used with local storage, show me where and how, and I'll try it.
     
    Last edited: May 19, 2022
  43. Marc-Saubion

    Marc-Saubion

    Joined:
    Jul 6, 2011
    Posts:
    655
    They're designed for professionals, including solo devs.

    And these are not comparable to storing backups on a hard drive.

    The reason you don't find what you need is because you expect a pro feature for free and there is no market for that.
     
  44. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    774
    You're right, I'm not a "professional". I'm just a hobbyist who's been using Unity since version 2.0, and using computers since the 1970s. But even I know that version control software is exactly about "storing backups on a hard drive". They just add a way to reconcile different versions of those backups, so that you always have a working asset after you restore it, even if it's a slightly different version than the one you had before. This shouldn't be hard to do, and people have been asking Unity for this for as long as I've been using it. Sounds like a market to me. There is zero functional difference between storing these backups locally or on some magical "cloud", other than that they can charge rent on cloud storage, so stop trying to gaslight me with that argument.

    The topic of this thread is "Scene Merging", not "Plastic SCM". Unity already has a built-in feature that lets you export and import assets. This should cover scene merging as well, but it doesn't work in all cases. I, like others posting in this thread, am looking for a solution to this problem. I noticed you didn't answer my question about where I could find a free version of Plastic that lets me store files locally. It seems you just want to sell me on this extra cost side hustle Unity has come up with, instead of fixing their core product. If you don't actually have an answer, then why are you putting so much effort into this thread? What dog do you have in this fight? Are you a Unity or Plastic SCM shareholder?

    My question wasn't directed at you. It was for someone at Unity. But it seems they all vanished from this thread years ago.
     
    Last edited: May 19, 2022
  45. Marc-Saubion

    Marc-Saubion

    Joined:
    Jul 6, 2011
    Posts:
    655
    That's the only option when creating a repo, cloud or local. Something you'd know if you tried it.