Skip to content
Go to file

Latest commit


Git stats


Failed to load latest commit information.

#Flixel for Monkey

This is a port of flixel to the Monkey language. The port is translated from flixel v2.55 written by Adam 'Atomic' Saltsman.


Monkey v60 or higher

###Supported targets

HTML5, Flash, Android, iOS, XNA, GLFW, PSM, Win8, WP8


  • For users with git installed:

    • Go to the Monkey modules directory
    • Do git clone flixel
    • Optionally. Do git submodule update --init to get bananas
  • For users without git:

###Upgrade to new version

  • For users with git installed:

    • git pull
    • Optionally. Do git submodule update to update bananas
  • For users without git:

    • Download the latest version of the library from downloads directory
    • Replace flixel module content by archive data

###Naming conventions

  • All-caps case (eg: 'ALLCAPS' ): Constants
  • Pascal case (eg: 'PascalCase' ): Globals, functions, class, methods, properties
  • Camel case (eg: 'camelCase' ): Fields, locals and function parameters


  • FlxSave currently is not ported
  • Debugger is absent
  • To build Windows Phone applications you must add a reference to Microsoft.Phone to the project



Import flixel


Function Main()
	New HelloWorld()
	Return 0
End Function

'Main class of the game
Class HelloWorld Extends FlxGame
	Method New()
		Super.New(640, 480, GetClass("HelloWorldState"))	
	End Method
	Method OnContentInit:Void()
		Register here all your assets, to use within application
		FlxAssetsManager.AddImage("ball", "graphics/ball.png")
		Now you can load an image in the game this way:
		Local sprite:FlxSprite = New FlxSprite(0, 0, "ball")
	End Method

End Class

'Main game state 
Class HelloWorldState Extends FlxState
	Method Create:Void()		
		Local helloWorld:FlxText = New FlxText(10, 10, 620, "Hello World!")	
		helloWorld.SetFormat(FlxText.SYSTEM_FONT, 16, FlxG.WHITE, FlxText.ALIGN_CENTER)	
	End Method
	Method Update:Void()
		'put your game logic here
		'... or here
	End Method
End Class

See more examples in the bananas folder.

You can’t perform that action at this time.