private void InitializeConnection() { try { var channelFactory = new ChannelFactory <ISkyShootService>("SkyShootEndpoint"); _service = channelFactory.CreateChannel(); _pingTimer.Elapsed += (sender, args) => _service.GetServerGameTime(); _pingTimer.Start(); } catch (Exception e) { FatalError(e); } }
public long GetServerGameTime() { return(_service.GetServerGameTime()); }