Table of Contents

Method Swipe

Namespace
MaaFramework.Binding
Assembly
MaaFramework.Binding.Native.dll

Swipe(int, int, int, int, int, int, int)

Swipes from a starting point to an ending point with duration.

For adb controller, contact means finger id (0 for first finger, 1 for second finger, etc.).

For win32 controller, contact means mouse button id (0 for left, 1 for right, 2 for middle).

public MaaJob Swipe(int x1, int y1, int x2, int y2, int duration, int contact = 0, int pressure = 1)

Parameters

x1 int

The horizontal coordinate of the starting point.

y1 int

The vertical coordinate of the starting point.

x2 int

The horizontal coordinate of the ending point.

y2 int

The vertical coordinate of the ending point.

duration int

The millisecond of the swipe duration(ms).

contact int

The contact id.

pressure int

The pressure.

Returns

MaaJob

A swipe MaaFramework.Binding.MaaJob.

Remarks

Wrapper of MaaFramework.Binding.Interop.Native.MaaController.MaaControllerPostSwipeV2(System.IntPtr,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32).