Exemplo n.º 1
0
 public void SetCallbacks(IWeaponActions instance)
 {
     if (m_Wrapper.m_WeaponActionsCallbackInterface != null)
     {
         @Attack.started   -= m_Wrapper.m_WeaponActionsCallbackInterface.OnAttack;
         @Attack.performed -= m_Wrapper.m_WeaponActionsCallbackInterface.OnAttack;
         @Attack.canceled  -= m_Wrapper.m_WeaponActionsCallbackInterface.OnAttack;
     }
     m_Wrapper.m_WeaponActionsCallbackInterface = instance;
     if (instance != null)
     {
         @Attack.started   += instance.OnAttack;
         @Attack.performed += instance.OnAttack;
         @Attack.canceled  += instance.OnAttack;
     }
 }
 public void SetCallbacks(IWeaponActions instance)
 {
     if (m_Wrapper.m_WeaponActionsCallbackInterface != null)
     {
         Shoot.started   -= m_Wrapper.m_WeaponActionsCallbackInterface.OnShoot;
         Shoot.performed -= m_Wrapper.m_WeaponActionsCallbackInterface.OnShoot;
         Shoot.canceled  -= m_Wrapper.m_WeaponActionsCallbackInterface.OnShoot;
         Throw.started   -= m_Wrapper.m_WeaponActionsCallbackInterface.OnThrow;
         Throw.performed -= m_Wrapper.m_WeaponActionsCallbackInterface.OnThrow;
         Throw.canceled  -= m_Wrapper.m_WeaponActionsCallbackInterface.OnThrow;
     }
     m_Wrapper.m_WeaponActionsCallbackInterface = instance;
     if (instance != null)
     {
         Shoot.started   += instance.OnShoot;
         Shoot.performed += instance.OnShoot;
         Shoot.canceled  += instance.OnShoot;
         Throw.started   += instance.OnThrow;
         Throw.performed += instance.OnThrow;
         Throw.canceled  += instance.OnThrow;
     }
 }