IsMTAWindowActive

From Multi Theft Auto: Wiki
Revision as of 21:22, 30 January 2011 by MaddDogg (talk | contribs) (typo)
Jump to navigation Jump to search

This function returns whether any system windows that take focus are active. This includes the chatbox input, console window, main menu and transferbox. To get the status of the debug view, see isDebugViewActive.

Syntax

bool isMTAWindowActive ()

Returns

Returns true if the focus is on the MTA window, false if it isn't.

Example

Click to collapse [-]
Client

This function kill a player if it comes out in the standard menu MTA

function dontAllowAnyOpenWindow ()
	if isMTAWindowActive ()	then
		 setElementHealth ( thePlayer, 0.0 )
	end	 
end
setTimer ( dontAllowAnyOpenWindow, 50, 0 )

See Also

General functions

Browsers

Buttons

Checkboxes

Comboboxes

Edit Boxes

Gridlists

Memos

Progressbars

Radio Buttons

Scrollbars

Scrollpanes

Static Images

Tab Panels

Tabs

Text Labels

Windows