OnResolutionChange

From Onset Developer Wiki
Revision as of 11:36, 23 March 2019 by BlueMountains (talk | contribs) (Created page with "{{Info|Event|Client|1.0}} {{FuncDescription|Called when the size of the game window changes. Either due to manual resizing or through settings.}} {{FuncSyntax|OnResolutionCh...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
OnResolutionChange

Type: Event
Context: Client
Introduced: v1.0

Description

Called when the size of the game window changes. Either due to manual resizing or through settings.

Syntax

OnResolutionChange(width, height)

Parameters

  • width
    New width (x) size.
  • height
    New height (y) size.

Example

function OnResolutionChange(width, height)
	AddPlayerChat("Resolution changed to "..width.."x"..height)
end
AddEvent("OnResolutionChange", OnResolutionChange)

See also

Game

Vehicle

Player

Weapon

Parachuting

Key

NPC

Object

Package

Pickup

Text

Vehicle

Web UI

Sound

Door

Network