Unity 5.1 introduced a new framework to handle client+server networking, also known as UNet.
1
vote
1answer
79 views
Two headphones for two players
We're looking to create a split screen game using Unity that is highly reliant on audio. We would need each player to have their own headphones and use positional audio to navigate through the map.
...
0
votes
0answers
23 views
why command is not executing on local player
I am getting very strange behavior, if my player instantiate as host (Server+Player) then my command function runs perfectly and certain object become instantiate but if I join the host then my ...
0
votes
0answers
10 views
Trouble Getting Unity's Network Lobby to pass LobbyPlayer Info
I'm using the NetworkLobby from the asset store. I'm attempting to take the form input (player name) and update the gameplayer using the associated lobbyplayer object. Per various tutorials and ...
0
votes
0answers
112 views
Network identity objects are disabled when loading additive scene
Short description: I am loading an additive scene in my main scene, its loading fine but its network identity object are disable.
Detail:
I am loading an additive scene thorugh this code so that an ...
1
vote
1answer
26 views
Spawning/Updating objects from client
I hope this is the right place to ask my question... I have been working on a game (all 2D) and I'm facing some problem with the networking part (pretty much a beginner).
My game idea is a shared ...
-1
votes
0answers
96 views
Creating a custom network manager in Unity
I just started to learn UNet over the internet, but it is quite frustrating trying to keep track of learning fundamental things easily. I want to make a server through my custom code without using the ...
1
vote
0answers
21 views
UNET (Multiplayer) calling [command] function twice
I am playing around with UNET but stuck into this weird problem/scenario while testing on same machine (unityEditor and buildRun to create "2 players/instances"
The problem is weird interaction of [...
0
votes
0answers
41 views
Creating a controller for unity cardboard game
I am making a unity google-cardboard game. I want to create 2 apps -
1. The main game unity app
2. The controller android app
I will load both the apps on the different phones. Put the main game app ...
0
votes
1answer
34 views
Unity Multiplayer functionalities or Google's plug-in?
I want to add multiplayer matches to a game I'm making for Android/PC, and something echoed in my mind: would the network functionalities Unity provides work in Android? I ask this because Google has ...
0
votes
1answer
50 views
uNet - Client cant see server spawned objects
I'm facing a problem where when I connect with the host, all the towers spawn. After I connect with a client only to find out there are no towers visible and I can walk through them when looking at ...
0
votes
0answers
46 views
You are trying to load data from a www stream which had the following error when downloading. 400 Bad Request
I have multiple ui image elements that get their data from a server.
The problem is that some times all of them load properly and without any problem and some times some of them randomly fail, it's ...
0
votes
0answers
101 views
Unity Multiplayer non-player object destroy
I am trying to create a 2D top down multiplayer game where the players move and pickup objects.
Below is the spawning of 6 pick-up objects on a random 2D position. This script is attached to a game ...
0
votes
1answer
24 views
unable to map one object position to another object over network
objective: I have a player which instantiate by network manager class. I want to map/sync its position/rotation to another object which is also instantiate by my player object.
(what it i have tried)
...
0
votes
0answers
24 views
Networking in unity
I have a game I developed in XNA (as the client) and a server (that's has little dependency with XNA, which can easily be removed). Currently I don't want to continue developing my XNA game, since it'...
0
votes
1answer
49 views
Unet, client is unable to control spawned units
I am trying to create a simple table top game with Unet. Right now I am just trying to get simple spawn mechanics working. The issue I am having is that the host computer can spawn and control objects ...
0
votes
1answer
57 views
How to sync a LineRenderer in a multiplayer game?
After a lot of searching online, I have come here as a last resort for my problem.
The question says it all. How to sync a LineRenderer?
One answer I found was to use a ClientRpc. I tried it with no ...
0
votes
0answers
35 views
Why unity use UDP protocol? [duplicate]
Why unity use UDP protocol? What's the benefit of using UDP with multiplayers game and give me some example where i use udp protocol for which data ?
Thanks Regards
0
votes
0answers
32 views
Multiplayer using Unity 5.4.1: Commands, ClientRpcs and SyncVars
I'm making a network game using unity. I am wondering about the following:
Are Commands, ClientRpcs and SyncVars guaranteed to be executed when called, or are they fire and forget?
0
votes
0answers
27 views
Attaching a camera to a client via NetworkLobbyManager
I'm using NetworkLobbyManager to co-ordinate a multiplayer unity game and need to set the client camera to follow each client.
What's the best hook to get the GamePlayer on the client so I can tell ...
0
votes
0answers
45 views
What are the performance implications of using SyncVar?
I have an application which is using a [SyncVar].
I'd like to understand the implications of using this for a frequently changing variable. In my case, this is a timer which is updated each frame.
...
1
vote
1answer
64 views
Unity networking, make player disappear for all clients
As title says I need to make the player disappear when he gets in car. Right now, it works as a single-player, but since I am new to unet I don't really know how to achieve this, I tried some ways, ...
0
votes
0answers
111 views
Unity3D Photon Multiplayer Movement Synchronization
I'm making a billiard game and I wanna sync the balls' movement. I'm using Photon network and this is my code so far:
Vector3 vel;
Vector3 angularVelocity;
Vector3 pos;
void Update()
{
...
5
votes
1answer
239 views
When to use Command and RpcClient
I'm working on a multiplayer turn-based project in unity 5.4 and Unity Networking. I'm trying to learn Networking and one thing I am wondering is when to use [Command] and [RpcClient].
I know the ...
0
votes
0answers
61 views
Unity UI Button Not Appearing (listItemPrefab)
Following a tutorial from brackeys (FPS 20) I has the following issue.
https://www.youtube.com/user/Brackeys
The issue is with joining servers in the 3d fps tutorial . When I host a game in a quick ...
1
vote
0answers
74 views
UNET Performance of (many) Kinematic Rigidbodies
I am building a game in Unity in C# using the UNET networking elements.
I am trying to figure out what is the performance cost of kinematic rigidbodies?
My understanding is that, when kinematic, ...
1
vote
3answers
114 views
How do you get audio clips to play on all clients?
I am new to networking with so this is probably a noob question.
For context I am trying to get a gunshot sound effect to play and be heard by all players.
3
votes
1answer
174 views
2 cameras that each player sees through a different one
Im very new to Networking in Unity 5.
Im trying to bring the finished basis for my 2 player, 1 vs 1, turn-based game I made for local multiplayer (both players on same computer) to an online ...
-2
votes
1answer
127 views
MMORPG networkconnection like Vindictus [closed]
to be honest, I like to make "small" MMORPG with my frends. We are 4 guys and are using Unity3D and Blender. I am a Programmer and I am using Eclipse. I know, it's silly to start a Question like "How ...
4
votes
1answer
172 views
Unity and Thread for Reading UDP
I have a GameObject that reads sensor data coming in over UDP (formatted as JSON).
What I am observing in that my handshake (dataReady) is getting cleared by the Update() cylcle fast enough, and I am ...
-4
votes
2answers
81 views
How can I test which of two gameobjects is closest to a third gameobject?
It would be nice if it was as simple as:
public void Closest()
{
if (A.distance > B.distance) {}
}
But any sort of workaround would be acceptable.
1
vote
1answer
127 views
Random Disconnects on UNET
Using UNET, I can't host a game for more than a few minutes unless both server and client are on the same computer. It appears that I am not alone in this.
Essentially, any latency problems or ...
0
votes
0answers
48 views
Unet 2D sync problems
I've studied Unet but I still can't get it to work right :(
I have 3 problems.
The first: I can't force player 1 to always spawn from a specific spawn point (and same with player 2). Therefore I've ...
0
votes
1answer
189 views
Unity3d multiplayer canvas
so I am making multiplayer game and I stuck on one thing, I have blood overlay canvas in my scene(you know, in fps games if somebody shoots you your screen becomes red and this stuff), and when I ...
0
votes
1answer
155 views
UNET spawn dynamically generated object unity
Spawning works when all clients are connected, but if a client connects after I spawn all my prefabs there are errors. I spawn the object before changing its Rigidbody's velocity, which seems to ...
1
vote
0answers
376 views
UnityWebRequest and/or HttpWebRequest give 403 on Android with PUT
I am trying to post an image captured through my game to Facebook through their SDK, and as it requires a URI, I wrote a simple AWS Lambda function to take a byte array and upload it to an AWS bucket. ...
0
votes
0answers
123 views
Networking issue in Unity - listening port is already in use
I am trying to Network a small 2 player Unity game. This is my first go at networking, so please feel free to correct me on anything I am doing wrong. I am attempting to make a simple matchmaking ...
3
votes
1answer
203 views
How do you use SoundManager for multiple player games over the network?
I have created a basic sound manager according to this unity tutorial (https://unity3d.com/learn/tutorials/projects/2d-roguelike/audio). However, I need it to work for multiple players over the ...
0
votes
0answers
452 views
UNet - Local Player Authority
I have an NPC. I would like to give the player the ability to possess the NPC by clicking on it.
//Prefab is spawned with networkIdentity.localPlayerAuthority = true
networkIdentity....
0
votes
1answer
55 views
Physics Object on Client moving too quickly in comparison to the Server: Should be a copy
I have a client server scenario. On the Server a force is applied to a 2d object. I want the client to copy the movements of the server but not through constant positional updates. My current approach ...
1
vote
2answers
413 views
Player shooting himself when moving - Unity UNET
Setting : Creating my first multiplayer game and running into an odd issue. it's a tank game where players can shoot bullets and kill each other
Problem : When the client shoots while moving, the ...
0
votes
1answer
413 views
Object spawn only on Server in multiplayer unity3d game
In my game I have an object let say food, whoever eat that food that player will spawn one more element. I am sharing code here :- I am checking collision in Update. Following code is working fine on ...
1
vote
1answer
231 views
Communication between Photon Cloud game and web server [Unity3D; Photon]
I am creating a multiplayer game using Photon Cloud (Photon Unity Network). For storage of player data (profile, inventory, achievments) I use web server (asp.net mvc & sql server). How to ...
4
votes
1answer
209 views
Unity 5: Use Network Simulator, should I?
I am looking to test intelligent prioritisation of a client server game. In my scenario, two clients are connected to the server. I want one client to have a good connection to the server while the ...
0
votes
0answers
58 views
Animation with pivot-modification in Mecanim
Assume I have two animation cycles:
Walking
Crouching
Both assume that the model's pivot is on the same level as the model's feet.
Now I also have two animated transitions:
Get on all fours while ...
1
vote
3answers
1k views
How to receive broadcast message in Unity?
I am trying to get the broadcasted message in overridden method of NetworkDiscovery.OnReceivedBroadcast(). For that what I had done is below:
I create class which implements NetworkDiscovery where I ...
1
vote
1answer
792 views
Unity 5 Command not being sent
I have a client server build in Unity 5. I want to send a command from the client to the server with a GUI button click, this is for testing purposes. So on my client all I want is to click a button ...
1
vote
0answers
269 views
UNet send message by Client.Send error
I'm try to implement client-server communication base on UNET.
The problem i got now is send custom message to server, but the Client.Send always show error without my understanding.
So what i'm wrong?...
0
votes
1answer
80 views
The best way to pass data between clients in a room
I am developing a backgammon game in Unity and tried to use Photon. But I could not find a step by step help for it and I also know that photon in real-time and it syncs data over 10 times per second. ...
1
vote
0answers
86 views
How do I allow clients to move a GameObject that exists on the server?
I started to delve into the UNet system for the first time the other day and I've run into a bit of an issue while testing on a localhost server. In the scene there is a Rigidbody ball that I want ...
-1
votes
1answer
2k views
How to correctly sync an ArrayList of GameObjects on a server/client
I'm experimenting with networking in Unity and I can't seem to get an ArrayList of GameObjects to sync from the server to the client.
Here is the relevant code:
[SyncVar]
ArrayList walls = new ...