AGK vs Monkey?!

Started by bmcalex, September 03, 2017, 16:41:41

Previous topic - Next topic

MikeHart

Quote from: RonTek on September 06, 2017, 15:11:51
Hey Mike, it looks like it depends on the code changes, changing the title on android build took 17s, that's just the NDK .so file w/o the final gradle build. On that note, I'm still having problems setting up gradle on Monkey2, it seems it was not setup properly. On other foss projects, it is automatic when you run gradlew.bat and so now I have to install gradle manually. :/

I can't help you with M2. I just managed to get Android Studio running for CX. Wish was a hassle for itself. Or my stupidity, I don't know :D

Pingus

Monkey2 examples takes time the first time they are builded, but further builds are much faster (not everything needs to be recompiled).

However, I made the following test that is not very encouraging:

I take a demo sample (pacman from Playniax PYro2 by example). Then I copy-paste a local code until I get 10000 lines of code in the same function (which is of course not a good practice ;).
First build require 49 secs to build. If I change nothing, the second build takes just 1 second. Ok fine.
Now I modify a line in any other function. And it takes again 49 secs !
My project beeing more on the 50000 lines side, it is totally impossible to imagine waiting several minutes each time I change a code line somewhere.! :o

Similar test with AGK show no compiling difference between a 1000 or 10000 lines code which is logical because there is no 'building/linking'.

Does that test means something compare to real practice ? Would it be different if instead of a function with 10000 lines I would have 100 functions of 100 lines (which is closer to real practice but I'm lazy to test it) ?


RonTek

#47
Quote from: MikeHart on September 06, 2017, 15:24:22
Quote from: RonTek on September 06, 2017, 15:11:51
Hey Mike, it looks like it depends on the code changes, changing the title on android build took 17s, that's just the NDK .so file w/o the final gradle build. On that note, I'm still having problems setting up gradle on Monkey2, it seems it was not setup properly. On other foss projects, it is automatic when you run gradlew.bat and so now I have to install gradle manually. :/

I can't help you with M2. I just managed to get Android Studio running for CX. Wish was a hassle for itself. Or my stupidity, I don't know :D

Ah no worries ;D Hey with some luck and effort, I finally got my gradle setup and working now for Monkey2. Build the pool aka billiard aka 8 Ball Hustler bananas demo on droid. But wait, hmmm.. for a 2D game or demo, it seems there's a bit of a lag.  :-\

For anyone who wants to have a go at it..

8 Ball Hustler Monkey2 Demo APK Download (Debug)
https://www.dropbox.com/s/v1uyhyzmwajnrai/pool-debug.apk?dl=0




RonTek

#48
Quote from: Pingus on September 06, 2017, 16:08:21
Monkey2 examples takes time the first time they are builded, but further builds are much faster (not everything needs to be recompiled).

However, I made the following test that is not very encouraging:

I take a demo sample (pacman from Playniax PYro2 by example). Then I copy-paste a local code until I get 10000 lines of code in the same function (which is of course not a good practice ;).
First build require 49 secs to build. If I change nothing, the second build takes just 1 second. Ok fine.
Now I modify a line in any other function. And it takes again 49 secs !
My project beeing more on the 50000 lines side, it is totally impossible to imagine waiting several minutes each time I change a code line somewhere.! :o

Similar test with AGK show no compiling difference between a 1000 or 10000 lines code which is logical because there is no 'building/linking'.

Does that test means something compare to real practice ? Would it be different if instead of a function with 10000 lines I would have 100 functions of 100 lines (which is closer to real practice but I'm lazy to test it) ?

Those build times seems acceptable, at least for me. I'm more concerned with performance particularly when using 3D and on an average android device. Maybe Monkey2 is for newer or latest mobile devices??

Also, I can't find any Mojo3D examples to try out. hah!  ???




Steve Elliott

#49
lol back in the day (at college) I had similar compile times from the College (shared) Mini Computer writing Pascal.

These compile times are unacceptable in this day and age IMO.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

Qube

Funny how we had patience "back in the day" waiting for things to load off cassette. These days if we click on build and it's not up and running in a few seconds ( or quicker ) a mild rage builds inside :P
Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

Steve Elliott

#51
lol very true...I remember the ZX Spectrum loading times.  You got used to it...But today, that is something I would not accept.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

Pingus

Sure that compile time is long especially when you get used to < 8 s compile time with bmax (for a 50000+ project) since years.

RonTek

Quote from: Pingus on September 06, 2017, 22:35:45
Sure that compile time is long especially when you get used to < 8 s compile time with bmax (for a 50000+ project) since years.

I agree, you can compare it (Monkey2) with Blitzmax build time if you are a BRL user.

In general, if you are a young and hip coder, I don't think it matters. Fast forward, when you realize that you are not like that Highlander guy and only have N years to live then time is of the essence, even those precious build seconds. ;D

ThickO

Quote from: Steve Elliott on September 06, 2017, 20:42:51
lol very true...I remember the ZX Spectrum loading times.  You got used to it...But today, that is something I would not accept.

Yes and the error at the very end of the load. I never had a tape load error out at the beginning.
3D makes my head hurt...

playniax

The compile times are not bad. Yes, the first time can take a while but after the compile time is just a matter of seconds. It does seem to depend on how many changes you make and where to slow down a bit.

I am using monkey2 everyday and really, if the compile time was so bad I would already have thrown in the towel. Patience is really not my strong suit and the monkey2 language is really a joy to work with.

Monkey2 is also evolving rapidly. You can't compare it with say monkey2 from a year ago.

I have not tried AGK yet ( I will some day ) but I use monkey for the language and nothing even comes close!

Xaron

#56
Monkey 2 is probably a joy to work with when you know the language. The almost non existing documentation makes it nearly impossible for newcomers to even make some easy first steps. It's just frustrating even for me who tried it here and there and knowing Monkey 1 in and out.

When it comes to the language itself I simply don't get why one should use it for the language aspects. C++ and C# are both far superior and not harder to grasp.

When it comes to the whole package, I agree, Monkey 2 IS indeed a nice solution. For desktop only I'd say there are tons better out there (as I already said) for cross platform it's really nice.

playniax

Okay, not here to start any arguments but...

> The almost non existing documentation makes it nearly impossible for newcomers to even make some easy first steps

Not that I am not agreeing with you on the docs, they could be A LOT better but maybe we are forgetting that monkey2 is relatively new?! Mark did a lot in such a small time! Also the language is 'FREE' and in active development! If it doesn't fill your need now, it may do so in a year or maybe never. Also nobody is asking anybody to wait.

BlitzMax wasn't that much better on the docs side, monkey1 wasn't that much better and from a lot of languages I have seen its also not a lot better. One just needs code examples, the other needs a complete step by step book! Not judging here, just who knows why this is.

> C++ and C# are both far superior and not harder to grasp

Yes, for you probably. For me sure but I just never liked them! Why? Don't know, just don't. When I started I did everthing in machine code and later assembler. I liked that very much but have no idea why.

But at the end of the day it is just a personal preference but objective opinions are hard to find...

RonTek

#58
With my recent tests, Mojo3D still fails on android with those shader errors so technically it is not yet cross platform and so I could say it is too early to recommend or use Monkey 2. With Mojo3D officially included in the release, Monkey2 is now presented as both 2D and 3D.

As for docs, with BlitzMax, I refer to the wiki here and the old forum archive
https://en.wikibooks.org/wiki/BlitzMax/

There's also an entry for MX but only a few articles there..
https://en.wikibooks.org/wiki/Monkey_X/

I agree with Martin there with Monkey 2 docs being non existent, it actually is. I have search and copy someone's template example just to get started with Mojo3D. I mean, Mojo3D is now included, so I find it a bit weird and inconvenient not finding any examples.

Perhaps this is a good site to start making those docs for Monkey 2??







MikeHart

Rontek: Look inside the mojo3d module folder. The bananas/examples are there. At least the last time I checked which was a while ago.