Hey, i realise there are the functions. Network.Isclient and Network.IsServer, however they dont match my needs. Im trying to compare an IP address with the servers IP address, if(Network.player.ipAddress != TheOtherIpaddress) doesnt work as when the server uses this function, the var TheOtherIpaddress, is empty, but doesnt register as null.
Not sure if this is making half the sense it should.
Note, The server works as a server/client system, its not standalone.
asked Dec 14 '09 at 06:23 PM
I think you just need to create an RPC function in a persistent gameobject in your scene (the one called connectionGUI in the official multiplayer project). That rpc function needs to "return" the IP, so quite simply at a point (possibly OnNetworkLevelLoad or a similar one-shot system function) you make a call.
In the same script there's the following
so that your "serveripaddress" variable is conveniently loaded once you need it, after 'OnNetworkLevelLoad' has executed.
Welcome to the horrible world of networking