Class VInputButtons
The buttons class of VInput.
VInput 按鈕群類別。
Inherited Members
Namespace: Votanic.vIO.VInput
Assembly: Votanic.vIO.dll
Syntax
public class VInputButtons : Buttons
Methods
ButtonDown(Int32, Boolean)
Return true if the button is pressed.
當按鈕按下時傳回 true。
ButtonDown(0)
Declaration
public override bool ButtonDown(int index, bool reversed = false)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Button index |
System.Boolean | reversed | Reverse the result if true |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
ButtonHold(Int32, Boolean)
Return true if the button is held for a while.
當按鈕長按一段時間時傳回 true。
ButtonHold(0)
Declaration
public override bool ButtonHold(int index, bool reversed = false)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Button index |
System.Boolean | reversed | Reverse the result if true |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
ButtonPress(Int32, Boolean)
Return true if the button is pressing.
當按鈕按住時傳回 true。
ButtonPress(0)
Declaration
public override bool ButtonPress(int index, bool reversed = false)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Button index |
System.Boolean | reversed | Reverse the result if true |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
ButtonUp(Int32, Boolean)
Return true if the button is released.
當按鈕放開時傳回 true。
ButtonUp(0)
Declaration
public override bool ButtonUp(int index, bool reversed = false)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Button index |
System.Boolean | reversed | Reverse the result if true |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
SetHoldingDuration(Int32, Single)
Set the holding type target seconds of a button.
設定一個按鈕的長按時間。
SetHoldingDuration(0, 1)
Declaration
public override void SetHoldingDuration(int index, float holdingDuration = 1F)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | Target index |
System.Single | holdingDuration | Target seconds |
Overrides
SetHoldingDuration(Single, Boolean)
Set the holding type target seconds of buttons.
設定按鈕群長按輸入類型所需的目標秒數。
SetHoldingDuration(1, true)
Declaration
public override void SetHoldingDuration(float holdingDuration = 1F, bool setToAll = false)
Parameters
Type | Name | Description |
---|---|---|
System.Single | holdingDuration | Target seconds |
System.Boolean | setToAll | Set to all input indices if true, else only set to the index using global value
|