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. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Legacy Networking and uNet

Discussion in 'General Discussion' started by Lachee1, Nov 22, 2015.

  1. Lachee1

    Lachee1

    Joined:
    Aug 21, 2012
    Posts:
    16
    Hey everyone,

    I am fairly new to the Unity Community, so I am not sure how you guys will react, hopefully it would be nicely.

    I have been using Unity for quiet a while (as I imagine most of you would be) and I developed ways and systems around old "legacy" systems. For example, I still use the legacy animations instead of Mechanim as I developed classes and scripts around those and its much easier than learning the new systems for quick prototypes.

    I have recently just upgraded from Unity 4.3 to Unity 5.2 and have been enjoying its new features... to a point. A lot of my networking code is now deprecated because its part of the "legacy" networking and everything is telling me I should be using the new uNet. To be honest, I do not know very much on uNet and I probably should follow more tutorials before making this thread, but here it goes anyways.

    I do not like the new uNet. Yes, I have not used it before and its the stereo-typical "hating of the new things", and I realise that and do plan on learning it... eventually. At the moment I just started a project that I wish to implement networking in quickly, using the systems that I have already developed using NetworkViews and RPCs. I have been using this system for lots of projects and a couple of years actually, so I am fairly acquainted to it, unlike the uNet.

    so you might be thinking right now "Well, what's the big deal? You can still use legacy networking, so stop complaining you whiner! uNet is so much better anyways!". Well, you do have a point. uNet does seem much more powerful and I can still use legacy. Only problem with using legacy is that its been depreciated, which means a) I get warnings that i have to constantly disable and most importantly b) The legacy code can be removed at any time.

    While there hasn't been any official removal date that I know off, its still very, very bad programming practice to use depreciated code. I wish to request that the legacy code gets moved into new namespaces and the depreciation tags removed from them. I would imagine a namespace such as UnityEngine.Legacy.Netwoking would be appropriate for the legacy networking, however old code would require a new import for them to still work.

    This work around will help separate legacy code that should not be used any more with current methods and still allow people to use the legacy code if required.

    Sorry if this is a bit of a rant, I am just annoyed that my code I have developed is now mostly pointless. Thank you for your time reading this.
     
  2. Kiwasi

    Kiwasi

    Joined:
    Dec 5, 2013
    Posts:
    16,860
    I'd strongly suggest not upgrading your editor version until you are willing to deal with the pain of an update.
     
  3. Lachee1

    Lachee1

    Joined:
    Aug 21, 2012
    Posts:
    16
    Fortunately I still have my 4.3 version of unity, however its very buggy and crashes often, something unity 5 doesn't do... yet. I have just tried making my project with uNet and gave up after a hour of trying to get the players to sync correctly. RPC's where and still are the nicest things about unity networking.