MonkeyPro54 now available! [MONKEY NEWS]

Monkey Forums/Monkey Programming/MonkeyPro54 now available! [MONKEY NEWS]

marksibly(Posted 2012) [#1]
Hi,

MonkeyPro54 is now up!

The major new feature is 'reflection', a technique where a program can dynamically inspect/modify/invoke/manipulate its consts, globals, fields, methods, functions and classes.

See the new reflection module section on the wiki/IDE 'modules' page for some docs. More coming...

Also, there's a little demo in bananas/mak/reflectiontest that enumerates all decls in your app.


Modules:

reflection module added!

mojo xna - added WP7 support for accelerometer.

mojo graphics - DrawText alignment offsets now Floor()ed.

xna mojo - music functions now disabled if MediaPlayer.GameHasControl is false at startup.

xna mojo - added WP7 support for multitouch.

cpp monkey.lang - fixed double fclose() in LoadString.

monkey.lang - added String.FromChars( chars:Int[] )


Targets:

xna - Target solution now includes windows phone project.

xna - Added XNA_ACCELEROMETER_ENABLED="true" to xna CONFIG.TXT

glfw - tweaked compiler settings a bit so debug builds go a bit faster.

stdcpp/glfw/ios - moved #includes to separate main.h files. Hoping to precompile these eventually...


Trans (v1.30):

Reflection support added!

XNA builds now only build Windows version - much faster than building both Windows/XBOX!

Added more flexible interface casting - interfaces can now be cast to and from ANY class/interface. I thought this choked AS, but now doesn't seem to...

Fixed C++ cast-interface-to-object bug.

Added String.FromChars( chars:Int[] )




slenkar(Posted 2012) [#2]
nice!
I was looking forward to reflection thanks


therevills(Posted 2012) [#3]
Just tested v54 with Diddy's GUI test on HTML5, FLASH, GLFW (Win), Android and XNA - all works!!

Samah's checking out the reflection mod now... it'll be interesting to see what he says - (Samah - LeetJavaHaxor + Fanboi! - LOL ;P)


dopeyrulz(Posted 2012) [#4]
Nice! Thanks Mark!


therevills(Posted 2012) [#5]
Hey Mark, just wondering why you have removed AppTitle from the app.monkey (since the code is still there in the targets)? Also you left a test (Global Test:=100) variable in mojo.monkey.


Samah(Posted 2012) [#6]
I had to "stubify" AppTitle in MonkeyLua... :(

Samah - LeetJavaHaxor + Fanboi! - LOL ;P)

You know it! ;)


Aman(Posted 2012) [#7]
Nice, I was looking forward to adding WP7 support for accelerometer.


TeaBoy(Posted 2012) [#8]
woohoo, good stuff :)


wiebow(Posted 2012) [#9]
Nice. The docs do not mention the reflection module though. The online wiki does.


Raz(Posted 2012) [#10]
Always great to see many improvements, but selfishly, more so to see so many XNA improvements :)


devolonter(Posted 2012) [#11]
Reflection - that's what I needed in the port flixel for Monkey. Thank you!


dopeyrulz(Posted 2012) [#12]
Always great to see many improvements, but selfishly, more so to see so many XNA improvements :)

Yep - same here!

Mark, the help advises the Accelerometer (AccelX, AccelY and AccelZ) is not available for Windows Phone.

Also confirming Touch and Accelerometer working ok!


Blitzbat(Posted 2012) [#13]
If I use the reflection and the fontmachine module i can't compile my code.
Thats realy strange. The error is the following:

C:/Monkey/MonkeyPro54/modules/fontmachine/bitmapfont.monkey<27> : Error : Method Font.GetTxtWidth:Int(Local text:String) must be implemented by class BitmapFont


therevills(Posted 2012) [#14]
When using the reflection module, it compiles everything - so all your code must be compilable.


Volker(Posted 2012) [#15]
Updating the fontmachine module should do it.


ziggy(Posted 2012) [#16]
@Blitzbat: Be sure to be using latest version of the FontMachine module. it's been updated several times in the last four days.


Blitzbat(Posted 2012) [#17]
Thanks! Now it works!


JD0(Posted 2012) [#18]
Exactly what I was waiting for - can't wait to check this out.


matt(Posted 2012) [#19]
@marksibly is there any chance of search (with intellisense style matching) being added to the online wiki docs? It's the only thing I really miss from my old doc system.

Cheers


taumel(Posted 2012) [#20]
This, and that you get no docs when you're offline.


therevills(Posted 2012) [#21]
and that you get no docs when you're offline.


You can also select 'offline docs' within IDE options if for some reason you don't have online access.


matt(Posted 2012) [#22]
It would also be nice if that was automatic. :)


taumel(Posted 2012) [#23]
@therevills
Wow thanks, i haven't seen this one. Still too much used to the BlitzMax prefs.


frank(Posted 2012) [#24]
This means:

http://www.monkeycoder.co.nz/Community/post.php?topic=2038&post=19747

that we can have scripting now? :)