Table of Contents

Class UnityIPCEventSender

Namespace
Alacrity.Internal
Assembly
Alacrity.Internal.dll

Inter-process event sender intended for Alacrity internal usage. You can use this to manually send events instead of relying on the default behaviour of Alacrity.

public class UnityIPCEventSender
Inheritance
UnityIPCEventSender
Inherited Members

Constructors

UnityIPCEventSender(IPCPipe, int)

public UnityIPCEventSender(IPCPipe pipe, int bufferSize)

Parameters

pipe IPCPipe
bufferSize int

Methods

SendKeyEvent(int, MouseButtonOrKeypressEventType)

Send a keyboard event. The keycode should be a Unity KeyCode and will be converted to the correct Windows keycode after being received by the browser.

public void SendKeyEvent(int keyCode, MouseButtonOrKeypressEventType eventType)

Parameters

keyCode int
eventType MouseButtonOrKeypressEventType

SendLoadUrlEvent(string)

Send an event indicating to load a new URL provided by the given string.

public void SendLoadUrlEvent(string url)

Parameters

url string

SendMouseButtonEvent(int, int, byte, MouseButtonOrKeypressEventType)

Send a mouse button event (e.g. left click, right click) and whether the button was pressed or unpressed.

public void SendMouseButtonEvent(int mouseX, int mouseY, byte mouseButton, MouseButtonOrKeypressEventType eventType)

Parameters

mouseX int
mouseY int
mouseButton byte
eventType MouseButtonOrKeypressEventType

SendMouseMoveEvent(int, int)

Send a mouse move event to indicate the mouse has been moved to a new position.

public void SendMouseMoveEvent(int mouseX, int mouseY)

Parameters

mouseX int
mouseY int

SendMouseWheelEvent(float, float)

Send a mouse wheel event with a given x and y delta in pixels.

public void SendMouseWheelEvent(float xDelta, float yDelta)

Parameters

xDelta float
yDelta float

SendResizeEvent(int, int)

Send an event indicating to resize the browser to the given width and height.

public void SendResizeEvent(int width, int height)

Parameters

width int
height int

SendSetFramerateEvent(int)

Send an event indicating to adjust the refreshrate of the browser to the new provided rate.

public void SendSetFramerateEvent(int newFramerate)

Parameters

newFramerate int