IsCtrlPressed

From Onset Developer Wiki
Revision as of 10:16, 19 November 2019 by 28days (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
IsCtrlPressed

Type: Function
Context: Client
Introduced: v1.0

Description

Check if the player has pressed the Ctrl key.

Syntax

IsCtrlPressed()

Parameters

  • This function has no parameters.

Return Value

  • Returns true on success.

Example

AddEvent("OnKeyPress", function(key)
	if IsCtrlPressed() and key == 'R' then
		AddPlayerChat("You have pressed CTRL + R")
	end
end)

See also