To those that know unity far more than me :)
I have a weird issue in a networked fps... Nothing particularly fancy is happening. I have a gunManager with its own NetworkView (state sync off) attached to a node called 'Weapons' which is some descendant in my player object hiearchy: which also has NetworkView w/ synchronized compressed data.
The GunManager is straight foward, it checks to see if the player has fired then RPC's when the shot is made with RPCMode.Others so that they can display the bullet/rocket/etc....
Given this, my lazerprefab is just a cylinder, but for some reason anytime a player who isn't the server 'fires', they have a local chug. But the server does not experience this. In fact, if the server fires alot everyone in the game chugs. The 'chug' is like a 5-10 FRAME lockup(drop) which is very disorienting. I am pretty sure this is the standard way of architecting networking for a gunshot. At first I thought it was the local Instantiate in the Rpc: FiredOneShot, but if I completely comment this function out I still notice the chugging. Has anyone else come across this or have suggestions to try out ?
Appreciate the advice, ~J
asked Oct 04 '10 at 07:01 PM
It turns out that when I upgraded to Unity 3.0 this problem has completely gone away, so for those experience issues with your networking the older unity did a very bad job with state synchronizing that must have been fixed in unity 3.0, I didn't change any of my scripts and now its running smooth as butter...
answered Oct 06 '10 at 07:20 PM
your code is missing likely the most important check before it fires at all: "is time since last fire > firedelay" (and is firedelay reasonably large for network usage at all).
without that you basically flod the network which means that it will die down rather fast.
answered Oct 04 '10 at 07:39 PM