Class com.wiicade.Wii

Description

This class is the entry point into the functionality provided by the Wii console.

Method Index

getPrimaryRemote(), getRemote(), isWii()

Method Detail

isWii

static public function isWii():Boolean

Return true if the current system is a Nintendo Wii, false if it is any other platform.

Return

true if running on a Wii, false otherwise

getRemote

static public function getRemote(identity:Number):WiiRemote

The Wii can support up to four Wii Remote controllers. These controllers are numbered 0, 1, 2, and 3. Call this function with one of those four values to retrieve an object containing information about the specific remote.

Parameters

identityThe id of the Wii Remote you wish to query.

Return

A WiiRemote object containing information about the remote.

getPrimaryRemote

static public function getPrimaryRemote():WiiRemote

Out of the four remotes, only one remote is allowed to directly interact with the webpage. This remote is the "Primary" remote. While this remote is usually the first remote (id 0), it is possible for other remotes to be the primary remote if the first remote is turned off.

Use this function to retrieve a WiiRemote object containing information about the primary remote. This function is useful in single-player games where the user expects the remote that's turned on to be able to interact with the Flash movie.

Authors upgrading from the earlier WiiCade API should use Wii.getPrimaryRemote() in place of calling functions on the WiiMote object.

Return

The WiiRemote object for the current remote.