Example #1
0
 public static object Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_XInputGamepadState_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_XInputGamepadState(object transformFrom)
 {
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.XInputGamepadState       target = new global::Microsoft.Robotics.Services.Sample.XInputGamepad.XInputGamepadState();
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.XInputGamepadState from   = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.XInputGamepadState)(transformFrom));
     target.TimeStamp = from.TimeStamp;
     if ((from.Controller != null))
     {
         target.Controller = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Controller)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Controller_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Controller(from.Controller)));
     }
     else
     {
         target.Controller = null;
     }
     if ((from.DPad != null))
     {
         target.DPad = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.DPad)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_DPad_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_DPad(from.DPad)));
     }
     else
     {
         target.DPad = null;
     }
     if ((from.Buttons != null))
     {
         target.Buttons = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Buttons)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Buttons_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Buttons(from.Buttons)));
     }
     else
     {
         target.Buttons = null;
     }
     if ((from.Triggers != null))
     {
         target.Triggers = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Triggers)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Triggers_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Triggers(from.Triggers)));
     }
     else
     {
         target.Triggers = null;
     }
     if ((from.Thumbsticks != null))
     {
         target.Thumbsticks = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Thumbsticks)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Thumbsticks_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Thumbsticks(from.Thumbsticks)));
     }
     else
     {
         target.Thumbsticks = null;
     }
     if ((from.Vibration != null))
     {
         target.Vibration = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Vibration)(Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Vibration_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Vibration(from.Vibration)));
     }
     else
     {
         target.Vibration = null;
     }
     return(target);
 }
Example #2
0
 public static object Microsoft_Robotics_Services_Sample_XInputGamepad_XInputGamepadState_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_XInputGamepadState(object transformFrom)
 {
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.XInputGamepadState target = new global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.XInputGamepadState();
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.XInputGamepadState       from   = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.XInputGamepadState)(transformFrom));
     target.TimeStamp = from.TimeStamp;
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Controller tmp = from.Controller;
     if ((tmp != null))
     {
         target.Controller = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.Controller)(Microsoft_Robotics_Services_Sample_XInputGamepad_Controller_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Controller(tmp)));
     }
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.DPad tmp0 = from.DPad;
     if ((tmp0 != null))
     {
         target.DPad = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.DPad)(Microsoft_Robotics_Services_Sample_XInputGamepad_DPad_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_DPad(tmp0)));
     }
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Buttons tmp1 = from.Buttons;
     if ((tmp1 != null))
     {
         target.Buttons = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.Buttons)(Microsoft_Robotics_Services_Sample_XInputGamepad_Buttons_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Buttons(tmp1)));
     }
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Triggers tmp2 = from.Triggers;
     if ((tmp2 != null))
     {
         target.Triggers = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.Triggers)(Microsoft_Robotics_Services_Sample_XInputGamepad_Triggers_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Triggers(tmp2)));
     }
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Thumbsticks tmp3 = from.Thumbsticks;
     if ((tmp3 != null))
     {
         target.Thumbsticks = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.Thumbsticks)(Microsoft_Robotics_Services_Sample_XInputGamepad_Thumbsticks_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Thumbsticks(tmp3)));
     }
     global::Microsoft.Robotics.Services.Sample.XInputGamepad.Vibration tmp4 = from.Vibration;
     if ((tmp4 != null))
     {
         target.Vibration = ((global::Microsoft.Robotics.Services.Sample.XInputGamepad.Proxy.Vibration)(Microsoft_Robotics_Services_Sample_XInputGamepad_Vibration_TO_Microsoft_Robotics_Services_Sample_XInputGamepad_Proxy_Vibration(tmp4)));
     }
     return(target);
 }