示例#1
0
        protected TelemetryValue(iRSDKSharp.iRacingSDK sdk, string name)
        {
            if (sdk == null) throw new ArgumentNullException("sdk");
            if (!sdk.VarHeaders.ContainsKey(name))
                throw new ArgumentException("No telemetry value with the specified name exists.");

            var header = sdk.VarHeaders[name];
            _Name = name;
            _Description = header.Desc;
            _Unit = header.Unit;
        }
        protected TelemetryValue(iRSDKSharp.iRacingSDK sdk, string name)
        {
            if (sdk == null) throw new ArgumentNullException("sdk");

            _exists = sdk.VarHeaders.ContainsKey(name);
            if (_exists)
            {
                var header = sdk.VarHeaders[name];
                _name = name;
                _description = header.Desc;
                _unit = header.Unit;
                _type = header.Type;
            }
        }
 protected void Broadcast(iRSDKSharp.BroadcastMessageTypes type, int var1, int var2, int var3)
 {
     if (!_wrapper.IsConnected) return;
     _wrapper.Sdk.BroadcastMessage(type, var1, var2, var3);
 }