Things You'll Need
Instructions
Develop your Flash game as you would any other by starting new document and building the pieces your game will need to function.
Implement the Wii remote API by downloading and extracting it into the same directory as your Flash project file and placing the following line at the top of each code file you wish to use the Wii remote feature in:
import com.wiicade.*
This line should go into each code file for each layer you wish to use. For example: if you have a code file for Layer 1 Frame 1 and a separate code file for Layer 2 Frame 1, you must place the statement at the top of both files in the Flash Studio Actions editor.
Once you have the necessary import statement in your code, you can begin using the advanced features of the WiiCade Remote API. Here's a good example of how it should look:
import com.wiicade.*
function onEnterFrame() {
if(remote.isDown(WiiRemote.BUTTON_B))
Don't leave anything out or it won't work properly.
Upload your game to an existing web host or one of your own.
Navigate to your game through the browser and play it.
GO
GO
var remote = Wii.getPrimaryRemote()
GO
{
var x = remote.getCursorX()
GO
var y = remote.getCursorY()
GO
//Shoot something!
}
}