Search Unity

Any guides for legacy network users?

Discussion in 'Multiplayer' started by lmbarns, Mar 5, 2017.

  1. lmbarns

    lmbarns

    Joined:
    Jul 14, 2011
    Posts:
    1,628
    I'm really saddened by the deprecation of the old system. I still have yet to figure out how to get the basic functionality I had and understood so well.

    Usage:

    I make tech demos for tradeshows, I typically have tablets and pc's networked together running completely different projects, one might just be relaying input/output to/from an arduino to simulate something going on in VR on another box, and a tablet may just be switching elements being interacted with in VR. The entire tablet project is just a scene with a network view and script on a canvas that relays info the the server, which broadcasts down to all the other clients, each client implements it's own usage of the event fired.

    I shipped a project in October that had 7 pcs and 3 tablets, some of the pcs had the same runtimes with different cameras, 3 cameras facing horizontally and 3 facing vertically to show the overhead view from the same position. Both of those runtimes were being projected onto walls/ceilings to create and experience you walk through. Tablets let you interact with the scenes. It took me 2 days to network it all with the legacy system.

    The other project at the same show had htc vives networked in an experience along with 2 other touchscreen all-in-ones that were the "spectator app" that allowed people to change props in the VR experiences, think mr potatohead dressing room. Again, complex network took a couple days to build and just worked.

    Issues:

    Last weekend I got hosed trying to use uNet instead at a hackathon. Firstly, I don't want to instantiate a character prefab the way it does by default, I spent hours overriding S*** in the networkmanager to sync values across clients and rig up "actions" and rpcs with the new system.

    Once I had it all working in regular clients, I moved to VR, I could instantiate scene objects, but there was some crazy ownership issues or something, if client A grabbed a networked scene object in VR to pick it up, it would become jittery and seemed like there was an ownership issue where the client picking it up was moving it but the other client was setting it's position to the non grabbed position.

    Spent hours pulling my hair out and it never worked right. The old system was as simple as:

    pseudo:
    Network.Initialize("", 4444);
    _view = Getcomponent<networkview>();
    _view.RPC("ChangedHead", smoptions.allbuffered, indexofNewhead);

    Then in the VR the ChangeHead would change the 3d model in the scene, while the android client would change the graphic in the UI.

    So. Simple.

    So my question is there any guides or tutorials to retrain those of us who were accustomed to the old system? I went through a lot of the tutorials but they're all tailored towards instantiating a player for each client, and not options for what model to use on remote clients vs local, can't instantiate 2x htc vive camera rigs in the same scene for example.