GetBirdsEnabled

From Multi Theft Auto: Wiki
Revision as of 23:10, 28 January 2012 by Castillo (talk | contribs) (→‎Example)
Jump to navigation Jump to search

This function will tell you if the birds are enabled or disabled.

Syntax

bool getBirdsEnabled ()

Returns

Returns true if the birds are enabled or false if the birds are disabled.

Example

This example Enables or Disables the Birds.

Click to collapse [-]
Client
function setBirdsState()
	setBirdsEnabled(not getBirdsEnabled()) -- Disable the Birds if they're enabled, either Enable them.
	outputChatBox("The birds are now ".. (getBirdsEnabled() and "Enabled" or "Disabled") ..".") -- Output the new Birds state.
end
addCommandHandler("birds",setBirdsState) -- Add the command handler attached to the function "setBirdsState".

Requirements

This template will be deleted.

See Also