Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

How to collaborate...dropbox just broke everything.

Discussion in 'General Discussion' started by Kensei, Aug 15, 2014.

  1. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Can anyone tell me how to effectively work on the same project without breaking it? Dropbox destroyed my project (even though it wasn't shared with anyone) just now, and I'm supper angry. I reaaally want to know if there is a safer way to share projects. I heard people talking about GitHub, but then there are those that say it's got problems with some files, and I don't want to share only the scripts. For example if I work on 1 scene and another guy works on another scene, but we use the same scripts, that's pretty much GG if dropbox is involved. Not to mention that it has massive problems with sync, creates a ton of copies due to supposed conflicts and just turns my project into garbage.

    How do you guys do it?
     
  2. carking1996

    carking1996

    Joined:
    Jun 15, 2010
    Posts:
    2,605
    Github.
     
    Meltdown likes this.
  3. CarterG81

    CarterG81

    Joined:
    Jul 25, 2013
    Posts:
    1,773
    For those of us who use DropBox, it would be nice if you shared how it "destroyed your project".

    I use dropbox, and I rarely get conflicting file versions. Is it because you two worked on it at the same time, constantly?

    With DropBox, the only thing I get is constant "Can't access file" and occassional "Script Compile Error!" because of not being able to access the file. Clicking "Try Again" for the former and editing/saving the script with any changes solves that for me. So worth it IMO, but I work alone programming.
     
    Last edited: Aug 15, 2014
  4. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    I was porting my game to Android. I was the only one working on it. I finished my project and I decided to sync everything, you know, as a backup. Next day I open the project and I find that I have lost all my project settings, layers, collisions and all that. My particle systems were all over the place, materials were missing, script references were gone and my build queue didn't exist.

    I opened up the project folder to see what the hell was going on, and I saw every file there has a corresponding conflicting copy. I checked my event log in dropbox and I was the only one who did any changes, figures of course since no one else had access to it. I really don't know what exactly dropbox did, and I'm too angry right now to start reassigning scripts and tweeking objects. Also all my object values were reverted to an older version settings, and I don't remember every friggin float that I have set. I have about 60 errors on a play attempt, and even when I fixed them on my smallest scene, the values were all scrambled. As an example I had 670 jump power, which defined the force applied to the player on jump, it was set to 400 when I opened it. My scripts are naked and are missing a ton of lines, and god knows what else is screwed up.
     
  5. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    20,071
    Try checking if Windows, assuming that's your OS, has backed up the folder in the past (right-click -> Properties -> Previous Versions).
     
  6. CarterG81

    CarterG81

    Joined:
    Jul 25, 2013
    Posts:
    1,773
    Scary. I try to backup my dropbox Unity project by zipping it every so often and then backing up the zip. You know, in case dropbox goes down.

    I really need to switch to another method though. That way I can have like, 10 different backup methods. Just in case 9 go down at the same time.

    Scariest thought in the world to have hundreds or thousands of hours of work just *poof*.

    Also from now on, since I use dropbox and that sounds awful, I'll zip it more often and then paste it to the root folder of all 4 of my hdd's, lol.
     
  7. lmbarns

    lmbarns

    Joined:
    Jul 14, 2011
    Posts:
    1,628
    SVN...
     
    AndrewGrayGames likes this.
  8. Kinos141

    Kinos141

    Joined:
    Jun 22, 2011
    Posts:
    969
    bitbucket is nice.
     
    Bladesfist, Graph and ForgottenCheese like this.
  9. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    I managed to recover most of my work by deleting the base files and renaming the "xxx (conflicted file on (date))" to just "xxx". I still have a bunch of junk that's not supposed to be there, but at least the game is functional. I'll go with Git. Seems like BitBucket is a pretty good choice.

    @Carter, dude if I were you I'd dump dropbox, its too erratic.
     
  10. Zeblote

    Zeblote

    Joined:
    Feb 8, 2013
    Posts:
    1,102
    Did you maybe shut down your computer before dropbox finished syncing the files?
     
  11. AndrewGrayGames

    AndrewGrayGames

    Joined:
    Nov 19, 2009
    Posts:
    3,822
    Your story is why I wrote this some months ago.

    Dropbox is not a version control system, it's a sharing space. If it goes down, your backup of the project is borked. Using it as version control...well, it's not, so it's not a good practice.

    The reason you use version control is A) so that you have control of what you're working on at any given point, because version control systems have a sort of 'rewind' function, and B) you use something like Git or Plastic because those are distributed systems that ensure your whole database isn't stuck in one place, and thus resistant to catastrophic failure.

    You really should take the warning and use a version control system. They're not hard, many have modern user interfaces that are easy to use, and your assets can be commented on and refined whenever it is necessary.
     
    goldbug and calmcarrots like this.
  12. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Judging by what you wrote, I should use TortoiseGit?
     
  13. judah4

    judah4

    Joined:
    Feb 6, 2011
    Posts:
    256
    Ive been using bitbucket. They have a nice interface
     
  14. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    I see, I've dug around and i settled on bitbucket, now I just have to understand how the hell it works and I'll be g2g. Thanks for your time guys.
     
  15. ForgottenCheese

    ForgottenCheese

    Joined:
    Dec 1, 2013
    Posts:
    40
    I'd also recommend getting Source Tree w/ bitcucket. I advise you to do some reading on what everything is. When I first learned about all this stuff people kept throwing around terms like Git, SVN, Mercurial. I had no idea what they were talking about.

    Basically all of this stuff is a type of Version Control: http://en.wikipedia.org/wiki/Revision_control
    Here is a good read on DVCS: https://quickstart.atlassian.com/download/stash/what-is-dvcs

    From there I suggest you research Git and Mercurial. And remember Git and Github are not the same thing.
     
  16. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Yeah I already have sourcetree and i signed up on bitbucked. I read how version control works. I'm just trying to figure out SHH keys or whatever it is that I need to actually make this work :p Tx for the links tho.
     
  17. AndrewGrayGames

    AndrewGrayGames

    Joined:
    Nov 19, 2009
    Posts:
    3,822
    TortoiseGit or TortoiseSVN are great. I highly recommend using BitBucket as the remote server you commit to (since, it's off-site and generally reliable.) I personally favor Git, since each person on the project has their own copy of the database, so you get a little better fail-protection.
     
  18. Pelajesh

    Pelajesh

    Joined:
    Dec 7, 2009
    Posts:
    363
    I use TortoiseGit (and SourceTree on osx) + Dropbox combo. I have working repos on my machines and a bare repo on dropbox. This way I always have 3 backups of my work, all including previous versions because of git.
     
    Ryiah likes this.
  19. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    I use TFS :) I have a couple of personal things that I keep out in a Visual Studio Online subscription, and I have a personal TFS server that also has redundant backups for my professional work.
     
  20. calmcarrots

    calmcarrots

    Joined:
    Mar 7, 2014
    Posts:
    654
    I have my game on dropbox, google drive, git, and my onecloud. I have a years worth of work on there so I cannot lose anything! I always hear these stories about how someone lost their project due to not properly use version control or simply not even having a backup. I think these lessons should be made available to everyone and it is almost mandatory for new users to have a training in version control. It takes like 15 min to learn how to do and will save you 1 years worth of minutes.
     
  21. Tanel

    Tanel

    Joined:
    Aug 31, 2011
    Posts:
    508
    You don't really need to use SSH if you don't want to, that part is optional.
     
  22. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,782
    We use dropbox for project sharing and we never have any problem all this time. And we able to working on the same project even though multiple people opening it at the same time.
    Maybe this can help. We use selective sync and disable syncing for these folder
    -Library
    -Temp
    -Obj(if exist)
    But of course we also have another backup for our project :)
     
  23. Imre

    Imre

    Joined:
    Sep 27, 2012
    Posts:
    73
    we are using, mercurial, for source / asset version control, it's fast and can handle binary files well.
     
  24. JamesLeeNZ

    JamesLeeNZ

    Joined:
    Nov 15, 2011
    Posts:
    5,616
    TFS. wtf is wrong with you ;)
     
  25. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    I used to use Bitbucket too, but for what it's worth their terms of use make it pretty clear that the intended use is to store source code only. Large amounts of binary data are frowned upon and may result in repositories being deleted... which needless to say would suck.
     
  26. im

    im

    Joined:
    Jan 17, 2013
    Posts:
    1,396
    DropBox is not really for what you are doing.

    Github is the way to go.
     
  27. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,613
    Yes, this happened to me. First they locked the repository so I couldn't push anything new to it, and then we had a chat - they agreed to let me stay if I took out one of their $15/mo subscription plans, which I did for a while.

    In the past couple of weeks I've moved the project over to Unfuddle, who provide 50GB for $3/user/mo (with extra space at $1/mo).
     
  28. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,613
    BTW, if you must use Dropbox, follow rea's advice, and also make sure you turn on .META files in your project (via Edit -> Project Settings -> Editor).
     
  29. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Aw man are u kidding me? I was just done setting the damn thing up. Ballz. Now what? Use GitHub?
     
  30. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    As a professional .NET consultant with 90% of my work being not Unity based I use TFS at my clients on a daily basis. Since I'm rather intimately familiar with the tools and have the license for it, it just seems to make the most sense. :)

    That being said, You can download the Visual Studio Tools for Git from the Visual Studio Gallery (and I think 2013, at least in one of the patch releases, already has this included) so you can use Git from within Visual Studio as well. Pretty handy if you're mix / matching your development by creating scripts and code directly in VS and other things within Unity.
     
  31. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,797
    Github rocks. We've got loads of Unity projects > 5GB, with assets, videos textures etc and never had any issues.

    I use SmartGit for my Git client which I think rocks too.
     
  32. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    Unfuddle is also where I happen to be at the moment. Not so much for the pricing - purely for the large-data thing. It's not a complaint at all, I just figure that it's a better fit since Bitbucket is clearly targeting different types of projects to the one I'm doing and Unfuddle seem to be aimed directly at people like me.

    Before that I was using CodeProject Workspaces a go. That was pretty nice, but I guess it wasn't working out for them 'cause they closed it down after only a few weeks.

    Before that I was on Bitbucket, which I think was the nicest out of the three with regard to the other tools it was bundled with. (All of these things come with pretty similar stuff, I just found the Atlassian ones to be most like what I'm used to from elsewhere.) If they don't mind game projects on paid subscriptions it's something I'd definitely consider again in the future.

    For what it's worth, Unfuddle is $6 a month for one user with one project. It's $3 per user and $3 per project. I still think that's pretty reasonable pricing, though.
     
  33. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,613
    Oops. *goes to amend monthly budget statements* :)
     
  34. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Aight lemme get this straight. This is the current setup I settled with:
    Forced the unity to serialize assets in Text.
    Synced Assets and Project Settings with dropbox, ignored everything else (could anyone tell me how to KEEP the unsynced files? It removes the folder when I remove the sync)
    Added a repo in the root folder and pushed it to BitBucket.
    Should I just push .../Assets/Scripts to the repo? From what I've read as long as I don't go over 2 gigs i should be fine, no?

    Am I going to have problems with this setup?
     
  35. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    Your project should be in the repo, not the other way around.

    As well as text serialisation you need to set "Version Control" to "Visible Meta Files".
     
  36. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Wait u mean my project should be INSIDE the .git folder?
     
  37. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,613
    You're missing 'turned on .meta files'
     
  38. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    The .git folder is not the repo.

    It goes something like this:
    Code (csharp):
    1. - RepoFolder
    2.     - .git
    3.     - UnityProjectFolder
    4.         - Assets
    5.         - ProjectSettings
     
  39. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,613
    I usually have my .git inside the UnityProjectFolder, alongside Assets and ProjectSettings. As long as it's not inside anything deeper than that then it should work.
     
  40. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    Yes, that would also work. The important bit is that the repository (which is not the same as the .git folder) contains the whole project. From Kensei's post it sounded like he might have an actual repository inside the project folder.
     
  41. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Aight so I'm good then. What about dropbox? I still can't figure out how to exclude folders without it physically removing them from the drive. Do I just copy-paste them somewhere and then stick them right back in?
     
  42. JamesArndt

    JamesArndt

    Unity Technologies

    Joined:
    Dec 1, 2009
    Posts:
    2,912
    I'm not collaborating, but I've found Dropbox works well if I don't have it running while I've got my Unity project open. Once I'm at a good point for a "check in", I save everything, close Unity and open Dropbox. It then syncs all of the days changes all at once. This gives me a specific check in that I can go back to previous versions of the project, if need be.
     
  43. lorenalexm

    lorenalexm

    Joined:
    Dec 14, 2012
    Posts:
    307
    One thing I haven't seen suggested yet, is running a GitLab instance on your own servers. If you already have the hardware you can avoid the majority of the costs (GitHub, BitBucket) or headaches (Dropbox, Google Drive) while still enjoying the familiarity of these services.
     
  44. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63

    This is exactly what I did, until Dropbox borked my game.
     
    JamesArndt likes this.
  45. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    No idea, I don't use Dropbox. Do you really need both at once?
     
  46. JamesArndt

    JamesArndt

    Unity Technologies

    Joined:
    Dec 1, 2009
    Posts:
    2,912
    Sounds like something unusual happened with your library files. Normally that won't happen.
     
  47. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    I just figured I'd use bitbucket only for Scripts and everything else would be stuck in dropbox. I'll figure it out, thanks for all the help.
     
  48. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,500
    It depends how you're architecting things, but given the often tightly coupled nature of GameObjects, Components and Scripts, I think you're asking for more trouble if you try to version your objects (scenes) and scripts differently.

    Why not just put the whole thing in a Git repository? Why work with multiple potentially conflicting systems to achieve something that just one of them can do more easily without breaking a sweat? Why continue to work with Dropbox, which is not designed for this and has already corrupted your project once?
     
    Tanel and ForgottenCheese like this.
  49. Kensei

    Kensei

    Joined:
    Apr 26, 2013
    Posts:
    63
    Because bitbucket has 2 gigs max repo size, so I figured i'd offload fat things like models/textures/sound to dropbox and just sync code for version control. But now that I think about it, I'll probably ditch dropbox all together, especially now that mega.co.nz is my preferred online storage, i just stash my builds there.

    Anyway, thanks a lot for all the info, I really hope my misfortune (although I did recover) is a lesson to everyone out there that uses dropbox. It's cool sure, specially for stuff like audio and textures, but other then that, nah.
     
  50. bzor

    bzor

    Joined:
    May 28, 2013
    Posts:
    35
    Probably because of bloat, having PSDs and large binary sources with different artists working and updating can explode repo sizes. Plastic SCM and the Asset Server seem to be the best solution ATM, or if you're a smaller project with lots of art you could try something like this: http://tylercodes.azurewebsites.net/?p=241