In The Dark :(

Monkey Forums/Monkey Programming/In The Dark :(

Stuart(Posted 2014) [#1]
As an absolute beginner, ( and disappointed paying customer ), I would have expected clear and concise step by step instructions supplied with Monkey explaining, demonstrating EXACTLY how to setup everything necessary in order to compile for each platform.
I wish to be able to compile for Desktop/GLFW, Android and Flash except the documentation provided leaves a LOT to be desired by the novice such as myself.
I wonder if I may prevail upon the kindness of those who have the knowhow and have succeeded in doing the above to show me step by step, thankyou. :)


Paul - Taiphoz(Posted 2014) [#2]
You mean like these?

https://dl.dropboxusercontent.com/u/56777267/MonkeyHelp/Target%20SDKs.html

Or are you looking for something more descriptive?


Stuart(Posted 2014) [#3]
I am sorry, I know that you are trying to be helpful and I do appreciate your time but the above I find to be just as frustratingly undescriptive.
I would greatly appreciate step by step instructions specifying exactly what to place where and if it's not too much to ask, the reasons for why.


Paul - Taiphoz(Posted 2014) [#4]
You can install the SDK's anywhere you want, the only thing that I can think of that needs to be installed in any kinda specific place is MingGW when ever I'v had it moved its failed to work so I leave it in its default location..

if you open monkey/bin/config_winnt.txt this file points to the location of each SDK, but if you have installed them in other places then all you need to do is go through each section and then add a new line with the path to where you installed it.

this would be my android section
'--------------------
'Android SDK and tool paths.
'
'Must be set to a valid dir for ANDROID target support
'
ANDROID_PATH="${SYSTEMDRIVE}\android-sdk-windows"
ANDROID_PATH="C:\monkey_sdks\android-sdk-windows"


So I have a folder called monkey_sdks in my c drive and thats normally where I put anything sdk related, in this case android-sdk-windows , so I added that line to the file so that monkey knows where to look for that specific sdk.

hope that helps.


rIKmAN(Posted 2014) [#5]
Check out this post from dawlane, hopefully it will work for you.

http://www.monkeycoder.co.nz/Community/posts.php?topic=7996&post=79575


skid(Posted 2014) [#6]
You do realise that writing a good game is 100 times harder than installing any particular target?

Perhaps you should consider asking for a refund before you fail completely.


therevills(Posted 2014) [#7]
@Skid
Perhaps you should consider asking for a refund before you fail completely.

That's a bit harsh don't you think... most of us agree here that the doco isn't the best here and there is room for improvement (it has got better over time)... Stuart has admitted to being "an absolute beginner", we all have to start somewhere.


skid(Posted 2014) [#8]
Anyone who considers monkey a tool for beginners or for that matter suitable for coding budgeting apps is seriously deluded. This community is not doing itself any favors by pretending that Monkey-X is something that it is not.


AdamRedwoods(Posted 2014) [#9]
This community is not doing itself any favors by pretending that Monkey-X is something that it is not.

someone's grumpy! ;^D

I wish to be able to compile for Desktop/GLFW

start here, ASSUMING you're on windows:
http://www.mingw.org/wiki/Getting_Started

there's a simple GUI installer link on that page, although, if you just install MinGW to "C:/MinGW" you'll see things will progress nicely. Get the 32-bit version!
then, under "c:/monkey/bin" look for config.winnt.txt and edit the part that looks like this:
MINGW_PATH="${SYSTEMDRIVE}\MinGW"


get that far FIRST.
if you have problems, come back, and post where you had problems (post in this same thread). someone will help you if you supply them with enough info, and tell them what you've tried so far.


MikeHart(Posted 2014) [#10]
@skid: I always thought you were somehow together with Mark in this BlitzResearch thingymegingy. Was that never be the case or did you guys had a bad breakup? Recently you sound a tidybit negative.


Paul - Taiphoz(Posted 2014) [#11]
Yeah im also surprised by that post skid but then we can all have bad days..

I also dont agree at all . People start with c++ , java and everything in between so to say its no hood for beginners is just wrong.

In my humble opinion ofc .


Supertino(Posted 2014) [#12]
I have never had issues following the simple steps in the monkey docs, on the first page click the "Target SDK" link then click the appropriate target and follow it through.


Paul - Taiphoz(Posted 2014) [#13]
I recall having a little issue at the time but thanks to the peeps here it was resolved real fast, and I think as I recall it was only with android, that sdk installer is a beast.

Fly's and Honey.. Fly's and Honey :)


MikeHart(Posted 2014) [#14]
I think the problem here is that once you leave the desktop route, you NEED to read yourself into the SDK docs of a vendor, like Google for Android. Monkey is not a tool like Corona for an example, that spits out a complete apk file for you to upload. You need to setup your development environment like you would do when you develop natively.
Actually you need to do that to a certain extend with other tools like Corona too. Soemtimes Windows is harder to setup than OSX. But still you need to get familiar with the toolchain.

I don't think it is Monkeys responsibility to explain every little step that it takes to get an APK into the Google market. The requirements change pretty often and I don't think Monkey has to document these changes and requirements. Google already does that, but it can be sometimes hard to understand. Same goes for Apple.

New developers see tools like Monkey and others and think it is very easy to start mobile dev. Or HTML5 dev. You hit a button and the tool does everythign for you. But it isn't, developing a game is just one step in the whole process. And that goes with all the tools out there. You need to read up on the platform you want to target, there is no way around that.


dawlane(Posted 2014) [#15]


Check out this post from dawlane, hopefully it will work for you.

http://www.monkeycoder.co.nz/Community/posts.php?topic=7996&post=79575

Now at http://monkey-x.com/Community/posts.php?topic=7996&post=79872

Perhaps you should consider asking for a refund before you fail completely.

skid I have to agree here with therevills. That was harsh. And as Paul says "I also dont agree at all . People start with c++ , java and everything in between so to say its no hood for beginners is just wrong." after all everyone has to start some where.

Anyone who considers monkey a tool for beginners or for that matter suitable for coding budgeting apps is seriously deluded. This community is not doing itself any favors by pretending that Monkey-X is something that it is not.
I myself have never considered Monkey a tool for beginners. To me it's more of a intermediate language akin to C#/Java/C/C++.
But someone who is new to programming stumbles cross the Monkey site, browses through the those big flashy pages and may get the impression that Monkey does it all for you. There is not one mention in the overview that you will require to install additional tools and software development kits unless you actually go into the documentation and as any one who has use BRL products in the past knows what the documentation tends to be like. Nor is there any mention that due to Monkey targeting a number of platforms that certain features will not be available to all targets and you will have to implement these yourself which means you need to learn about the target and the programming language used for that targets SDK.

As for the community. I find it possibly one of the best and helpful, especially for new users. The biggest problem is that the same questions keep getting asked again and again. This can be down to people either not reading/understanding the documentation or the lack of it; or not using the form search or not formulating the search criteria to get the results your looking for. I am surprised that there isn't a sticky in each section with answers to the most commonly asked questions.


Danilo(Posted 2014) [#16]
I had myself problems with Flash and Android target setup on Mac OS X, and it actually took me some hours to get it working.

Flex SDK for Flash didn't like latest Java 1.7 - had to un-install two Java 1.7 versions completely and install Java 1.6.0_65 from Apple to get it working.

Used the whole last night to get the Android target working. After reading many topics in this forum and trying and trying,
it is finally working. The small section in the help file didn't help with setting up all the required paths correctly.

Sounds so easy: Install W, X, Y, and Z. Done. But it is not always as easy as it may sound, especially when you get incompatibilities between versions of
Ant, Java, Android SDK, Android NDK, Adobe Flex SDK 4.6, Apache Flex SDK 4.11.0, MinGW, Visual C++/VisualStudio, Xcode, ... and setting up
all environment variables correctly for all targets to get it working correctly.
Experts always get it working, but sometimes even experts need some hours to do it. Not-so-experienced users just don't know what to do
when a problem comes up, because that is not something mentioned in the help files. I can understand that it may be very frustrating to new users.

The good thing is:
You can find answers to almost all of this problems already, hidden somewhere deep in this forums -
because many people already had the same problem with setting up all this stuff correctly. ;)

Now that I have everything working on Mac OS X, I have to install all the SDKs and tools
on Windows and Linux, too. Setup hell. lol :D


dawlane(Posted 2014) [#17]
Linux is possibly the easiest and the hardest to set up as long as you don't stray to far away from what's in the package repositories and know what you are doing.
HOW TO: Install Monkey on Linux (a rough guide).


Danilo(Posted 2014) [#18]
Thanks dawlane, that will definitely help.


Gerry Quinn(Posted 2014) [#19]
Installing packages and getting them running may be technically easier than writing a good game - but it can be terribly annoying and frustrating, especially if you're the sort of programmer who likes to write their own stuff.

One good thing about Monkey is that you can do them one at a time if you want (in practice I found installation went easily anough anyway).


marksibly(Posted 2014) [#20]
Hi Stuart,

Sorry to hear you are having problems installing the various SDKs required by Monkey.

I'm currently writing up some guides that will hopefully make this easier, but alas, it'll never be 'easy'! The installers are buggy, there are issues with 32bit vs 64bit, file permissions, conflicting SDK versions etc etc.

For what it's worth though, I reckon this stuff *is* harder than the actual game coding! At least with game coding, you have control over everything, and when things go wrong its generally due to something you did and can therefore have a shot at finding/fixing.

That said, if you're finding it all too hard going, please do contact shareit for a refund.


dawlane(Posted 2014) [#21]
@marksibly: The problem with writing a guide is that you can write one in one week and by the following week it's out of date. It can become a never ending struggle just to keep any kind of install guide current. Maybe the best solution is to have a general set up guide within the beginners section or maybe some kind of wikki where those that use a particular target on a regular basis can add guides for that target.


Paul - Taiphoz(Posted 2014) [#22]
Use lots of screen shots mark, a picture tells a thousands stories, as for the steps changing due to sdk alterations, that's something that cant be avoided, the good thing is that a good guide even after an sdk changes will still be informative and probably help a user deal with the changes themselves.

I have seen a lot of guides for various other things, a lot of 3D modelling a few years ago when I did it a lot had guides that went out of date the second the tool chain got updated, but the core things they were teaching remained the same even if the buttons or options moved, so with a little luck a decent sdk guide will be the same, the steps may change a little over time but a good one will still equip a new user with the information required to make that logical step and adjust for the change.


Stuart(Posted 2014) [#23]
I simply cannot adequately, satisfactorily express my gratitude and appreciation for the kindness, selflessness and warmheartedness of those here who have provided invaluable help and words of encouragement.
Much to my very pleasant surprise I have received a personal message from Mark Sibly, for which I sincerely thank you.
This personal gesture of yours evidences that you truly do care about the customer and we all who are enthusiastic about your product.


Paul - Taiphoz(Posted 2014) [#24]
I'v said a million times, this community and its people are second to none, we might be small, but good things DO! come in small packages <inner voice - that's what she said>

I also would not hold anything against skid, were all entitled to our opinion and our bad days where we get our grump on.


dawlane(Posted 2014) [#25]
@Stuart: Your first post says you an absolute beginner. The question I would like to ask is have you had any programming experience? Have you done any artwork using any paint programs? Have you done any thing with creating audio? If the answer is no then it's going to be a bit of a steep learning curve, but every one has to start somewhere. Just don't be expecting to write games like some of those on the apps section right way. Writing computer games is possibly one of the most challenging forms of computer programming as you have to do many things in real time and not all hardware or devices are the same. When you buy a game for the PC you see a "system requirements"; This should be read as "This is the minimum system that it will run on and not very good at that". When you wish to write a game for multiple devices you have to keep this in mind at all times. What may work well for an iPhone may not work so well on a Android Device.

Even if you have had experience at programming, art and sound it can be quite a task. If you are not familiar with an device, operating system or a application. Then you could spend hours getting the anything to work or work correctly. You should do a search on the problems that you can get with just installing Visual Studio. There have been a few times when I have sworn and almost thrown the computer out of the window because third party tools and Software Development Kits.


zoqfotpik(Posted 2014) [#26]
Stuart I do think the documentation leaves a little to be desired. I think most of the people who use monkey came from blitzmax and many of them are professional programmers, and the product is somewhat geared toward that level of knowledge.

I think you will find the community here to be very helpful.

Personally, I've been programming for 35 years now and I had used blitzmax for a year or so and it still took me quite some time to figure out how things were done in monkey. I do agree that Monkey could stand to be more beginner-friendly-- there are some conceptual hurdles that can be a bit difficult to get to grips with.

If you work at it and study and modify the examples you will figure it out. People here will help.

I suggest that you begin working with one target, specifically GLFW. That requires installation of the free Microsoft VC2010 compiler, and I think instructions are in the help. Don't even think about android at this point because that will require a whole other ball of wax.

At the risk of not sounding encouraging, I will say that game programming is pretty close to profoundly difficult and is the hardest thing I've done other than higher math. You should evaluate the degree of desire you have to program games, because you're going to need to want it real bad. If you don't want to deal with this kind of headache five times a day, or sometimes a bad week of hair tearing, you are better off doing just about anything other than programming games for a living. That's just the reality of it. You get used to it over time.

What you are running into right now is called "compiler fun," the difficulties of setting Up the software for an unfamiliar language. It is a hurdle with just about any language out there, for some reason it's always hard, but Monkey is about 2/10 on the difficulty scale.

When you get the compiler set up, welcome to programming, which is basically similar to predicate calculus.

At the same time, John Carmack started somewhere. Take a look at Commander Keen and compare that to Skyrim and Rage.


marksibly(Posted 2014) [#27]
Ok, spent a bit of time on this today - uninstalled JDK, Flex etc and reinstalled desktop/android/flash targets from scratch.

Still more to do, but is this going in the right general direction?


Target setup guide for Windows!

***** Desktop *****

* Download and run Mingw installer: http://www.monkeycoder.co.nz/downloads/tdm-gcc-4.8.1-3.exe

* For 'Wizard Action', select 'Create'.

* For 'Select Edition' select 'MinGW/TDM (32-bit)'.

* For 'Installation Directory' select C:\MinGW

* Download, extract and run the OpenAL installer: http://www.monkeycoder.co.nz/downloads/oalinst.zip

* Restart Monkey. You should now be able to build/run for the desktop target.

* If you install MinGW to a different directory, edit your Monkey bin\config.winnt.txt file so that Monkey can find MinGW. Find the first line that starts with 'MINGW_PATH=' and modify it so that it matches your MinGW installation path. See the existing config.winnt.txt file for examples.


***** Installing the Java JDK (required by Android, Flash targets) *****

* Navigate to the the Java JDK downloads page: http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html

* Download and run the appropriate installer for your OS, eg: 'jdk-7u51-windows-i586.exe' for 32 bit Windows, or 'jdk-7u51-windows-x64.exe' for 64 bit Windows.

* Find the location the JDK was installed to! This will be a directory that starts with 'jdk' and inside your 'Program Files\Java' (for 64 bit Windows) or 'Program Files (x86)\Java' (for 32 bit Windows) directory.

* Edit your Monkey bin\config.winnt.txt file so that Monkey can find the JDK. Find the first line that starts with 'JDK_PATH=' and modify it so that it matches your JDK installation path. See the existing config.winnt.txt file for examples.


***** Installing Ant (required by the Android target) *****

* Navigate to the Ant downloads page: http://ant.apache.org/bindownload.cgi

* Download one of the 'Current Release of Ant' archives, eg: apache-ant-1.9.3-bin.zip

* Extract the archive and copy it your system drive, eg: C:\apache-ant-1.9.3.

* Edit your Monkey bin\config.winnt.txt file so that Monkey can find Ant. Find the first line that starts with 'ANT_PATH=' and modify it so that it matches your Ant installation path. See the existing config.winnt.txt file for examples.


***** Installing the Android SDK *****

* Install the Java JDK.

* Install Ant.

* Navigate to the Android SDK downloads page: http://developer.android.com/sdk/index.html

* Click on 'Use an Existing IDE'.

* Click on 'Download the SDK Tools for Windows'.

* IMPORTANT! Before running the SDK Tools installer, you should create a 'System Environment Variable' called JDK_HOME which contains your JDK installation path - ie: it should contain the same value as the JDK_PATH setting in your config.winnt.txt file. This variable is used by the Android SDK installer to locate your JDK, and without it the SDK installer may refuse to install the Android SDK.

* Once you have created the JDK_PATH environment variable, run the SDK Tools installer.

* IMPORTANT! It is strongly recommended that you install the SDK Tools to a directory outside of 'Program Files' or you may get permission errors when trying to install packages. Installing the SDK Tools to C:\android-sdk-windows works well.

* Once the installer has finished, it will automatically run the 'SDK Manager' app. This should have some default packages selected - install these packages.

* Also, install the 'Android 3.2 (API 13)' package.

* Edit your Monkey bin\config.winnt.txt file so that Monkey can find the Android SDK. Find the first line that starts with 'ANDROID_PATH=' and modify it so that it matches your SDK Tools installation path. See the existing config.winnt.txt file for examples.

* Restart Monkey. The Android target should now be available. However, you will need to either find/install the USB driver for your Android device, or create/run an Android emulator using the 'AVD Manager' in order to be able to run code on Android.


***** Flash *****

* Install the Java JDK.

* Download and run the Flex Installer: http://flex.apache.org/installer.html

* IMPORTANT! Confusingly, you will be prompted for an installation location twice - the first time for the location of the installer itself (just leave it as is), the second for the Flex SDK, which is the bit actually required to build Flash apps. Also note that the directory you specify for the Flex SDK must already exist.

* Edit your Monkey bin\config.winnt.txt file so that Monkey can find the Flex SDK. Find the first line that starts with 'FLEX_PATH=' and modify it so that it matches your Flex SDK installation path. See the existing config.winnt.txt file for examples.

* Restart Monkey. You should now be able to build/run for the Flash target.




dawlane(Posted 2014) [#28]
@Mark: A few points.
* IMPORTANT! Before running the SDK Tools installer, you should create a 'System Environment Variable' called JDK_HOME which contains your JDK installation path - ie: it should contain the same value as the JDK_PATH setting in your config.winnt.txt file. This variable is used by the Android SDK installer to locate your JDK, and without it the SDK installer may refuse to install the Android SDK.
I would not advise anyone to do this for you are tying the system to use the JRE that comes with the JDK. Unless the user regularly updates the JDK and it's location in the environment variables, then they are leaving the system vulnerable to malicious attacks and problems with web browsers. One web browser is Firefox, as it will not run Java/JavaScript with an old JRE plugin. If anything they should install the JRE separately as it sets up the environment variables and when allowed will notify the user that there is a Java update available for installation.

When I use Linux. I have to manually check and update Oracle Java to keep it current.
I will be later doing a clean install of the iMac and will be exploring Oracle 7 Java/JDK istallation. But my research so far points to doing a manual installation in a similar fashion to Linux.

* If you install MinGW to a different directory, edit your Monkey bin\config.winnt.txt file so that Monkey can find MinGW. Find the first line that starts with 'MINGW_PATH=' and modify it so that it matches your MinGW installation path. See the existing config.winnt.txt file for examples.
It should be pointed out that MinGW's path cannot have any spaces.


Redbeer(Posted 2014) [#29]
Mark's statement:

For what it's worth though, I reckon this stuff *is* harder than the actual game coding! At least with game coding, you have control over everything, and when things go wrong its generally due to something you did and can therefore have a shot at finding/fixing.



Is exactly my sentiment. I run into this with "most" development software I use. To me the math and figuring out how to make things work, with some exceptions of course, is FAR easier than trying to guess my way through how someone else decided that the packaging should work, what versions are compatible, where things need to be, what paths will work (I've run into problems where specifying a path breaks because I often install things on secondary drives), etc or trying to follow a bunch of directions that may not be complete as the creator thought, or have changed enough that one can't transfer enough knowledge to understand what they're saying.
There is no "debugger" to help figure out what is wrong most of the time, other than it fails, and generally it's a mess that varies from 20 minutes of time, to sometimes whole days to get something working.
This is made worse because I often don't know what Monkey is doing internally, and with a large code base, it can be hard to find, even for the code that is open to me.
What this really needs is a theory of action/general principles about what Monkey needs to see and why, about what the various terms mean, and why you need certain parts/how they are referenced by Monkey (how the config files work). I have no idea what that definitively looks like, but that would help.

As far as "updates and changes" go. I think the best course would be to state, with every release, what SDK version for each platform Monkey has been tested to work with (what was current at the time), and on what OS version(s), as well as state that in the instructions. This way, at least we have a starting point for what DID work at the time of writing.


dawlane(Posted 2014) [#30]
Well Setting up Monkey on a virgin OS X 10.9 (Mavericks) was fun.
Installed Xcode 5, Java 7 Update 51 + JDK, Android SDK and Apache Flex.
Tip if you edit the config file using TextEdit make sure that you turn off smart quotes and smart dashes because if you don't you could spend some time scratching your head wondering why SDK's aren't being detected.

Now have to write my mad method down for doing it.

Any one have any ideas why the iphone simulator doesn't run from Ted?


marksibly(Posted 2014) [#31]
> I would not advise anyone to do this for you are tying the system to use the JRE that comes with the JDK.

What's the alternative?

I couldn't get the Android SDK to install unless this was set. It would just report 'JDK not found' and exit...

Perhaps it's because I was using the 64bit JDK, but I would have thought this was preferable (if it works, which it seems to)?

[edit]
After more digging around, it may be because I've banished Java from my browser etc!

But still, how should the 'guide' read when it comes to installing the JDK then?
[/edit]


dawlane(Posted 2014) [#32]
But still, how should the 'guide' read when it comes to installing the JDK then?
That's a bit of a tough one when dealing with Windows and 64bit. I would say that the JRE installer needs to be run first (possibly both the 32bit and 64bit versions for a 64bit OS) and then install the JDK that Monkey requires. But then trick could be in the install order; JDK first then the JRE. I will have to see.

I will be soon be having to reinstall Windows 7 64bit and I can check then exactly what is happening. Currently Win7 has Java 7 Update 51 installed the JDK is on the old side (jdk1.7.0_09 32bit) and was what was left over from the last time I did a re-install of Windows 7. But the JAVA_HOME isn't in the PATHS and the SDK,AVD Manager both run.

EDIT: I would use JAVA_HOME as a last resort incase there was a big problem.


dawlane(Posted 2014) [#33]
@Mark: I have spent around four hours investigating JAVA_HOME, JRE, JDK and Android SDK installation on windows. I haven't looked at NDK.

I take it that you was trying to use the Android SDK executable installer. That installer to me is bad news; checking to see if the Java SDK is installed and not letting you continue with the installation until you set JAVA_HOME. If any thing it should just give you a warning. The SDK/AVD Managers should only need the JRE installed to do their jobs.

Setting JAVA_HOME for system wide or local user from a security point of view should be OK as long as nobody starts to add %JAVA_HOME%\bin, %JAVA_HOME%\jre\bin or %JAVA_HOME%\jre\lib (think thats where the browser plugin is) to their PATH variable. Of course every time you want to use another JDK you then have to change it or over ride it which isn't a problem for Monkey as it already does it.
An option here that could work to install Android SDK would be to temporarily set JAVA_HOME via the command line and starting the installer from there.
set JAVA_HOME="path-to-jdk"
cd path-to-android-installer-location
"android-sdk-installer.exe"

Edit: Scratch that. The set JAVA_HOME above didn't work.

The other and less messy method is to download the android-sdk.zip archive under 'Download for Other Platforms', extract the android-sdk-windows directory to say C:\sdk and point Monkey to it.

OK JDK description
I don't think that Android applications care if you use the 32bit JDK or the 64bit JDK build tools, but web browsers do care about which JRE is installed. On a 32bit system this isn't a problem, but on a 64bit system it's a different story.

For 32 bit Windows
Run the 32 bit installer and leave the selection as it is (the default is to install all).
The Developer Tools and Source Code default directory is C:\Program Files\Java\jdk1.7.0_[version update].
The Public JRE is a separate installer process started by the jdk installer. The JRE default location is C:\Program Files\Java\jre7

For 64bit Windows
You can install both the 32bit and the 64bit JDK's along with the JRE's, but you must keep them separate from each other
The default locations are.

x86 JDK install (32bit)
The Developer Tools and Source Code default directory is C:\Program Files (x86)\Java\jdk1.7.0_[version update].
The Public JRE is a separate installer process started by the jdk installer. The JRE default location is C:\Program Files (x86)\Java\jre7

x64 JDK install (64bit)
The Developer Tools and Source Code default directory is C:\Program Files\Java\jdk1.7.0_[version update].
The Public JRE is a separate installer process started by the jdk installer. The JRE default location is C:\Program Files\Java\jre7

If you just want to install the x64 JDK and it's related JRE you must still have the 32 bit JRE installed for a number of web browsers.
Run the x86 JDK and deselect Development Tools and Source Code to just leave the Public JRE and continue or download the Java RE SE x86 installer and run that.

In all versions, you will find the Java settings Applet in the Windows Control Panel.

I think
***** Installing the Java JDK (required by Android, Flash targets) *****
* Navigate to the the Java JDK downloads page: http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
* Download and run the appropriate installer for your OS, eg: 'jdk-7u51-windows-i586.exe' for 32 bit Windows, or 'jdk-7u51-windows-x64.exe' for 64 bit Windows.
* NOTE: 64bit Windows Users: It is possible (under vista/Win7) to use either the i586 jdk installer or the x64 jdk installer as long as the installations remain separate. But if you use only the x64 jdk installer, you may find that a number of web browsers will be missing the Java-Plugin. If this is the case then install the JRE, e.g 'jre-7u51-windows-i586.exe' from
http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html
or use
https://java.com/
Installing both JDK's or just the Pulbic JRE from the i568 JDK will solve this issue.
* Find the location the JDK was installed to! This will be a directory that starts with 'jdk' and inside your 'Program Files\Java' (for 64 bit Windows) or 'Program Files (x86)\Java' (for 32 bit Windows) directory.
* Edit your Monkey bin\config.winnt.txt file so that Monkey can find the JDK. Find the first line that starts with 'JDK_PATH=' and modify it so that it matches your JDK installation path. See the existing config.winnt.txt file for examples.
should work for JDK. But I don't know about dual install on Windows 8 as I do not own it.

For Android SDK
***** Installing the Android SDK *****
* Install the Java JDK.
* Install Ant.
* Navigate to the Android SDK downloads page: http://developer.android.com/sdk/index.html
* IMPORTANT! It is strongly recommended that you install the SDK Tools to a directory outside of 'Program Files' or you may get permission errors when trying to install packages. Installing the SDK Tools to C:\android-sdk-windows works well.
* There two installation methods; a Windows executable and a compressed zip archive. The Windows installer requires you to add a environment variable before execution.
* To use the latest compressed zip archive
* Click on 'DOWNLOAD FOR OTHER PLATFORMS'
* In the section 'SDK Tools Only' under Platform Windows 32 & 64-bit. Click the package named 'android-sdk_[version]-windows-zip' to download. Note: You will also see the Android SDK executable installer here as well.
* After downloading the archive. Use an archive tool such as WinZip/7Zip to extract the 'android-sdk-windows' directory from within the archive.
* Navigate to this directory and run the 'SDK Manager' app. This should have some default packages selected - install these packages.
* Also, install the 'Android 3.2 (API 13)' package.
* To get the latest executable installer
* Click on 'Use an Existing IDE'.
* Click on 'Download the SDK Tools for Windows'.
* IMPORTANT! Before running the SDK Tools installer, you should create a 'System Environment Variable' called JDK_HOME which contains your JDK installation path - ie: it should contain the same value as the JDK_PATH setting in your config.winnt.txt file. This variable is used by the Android SDK installer to locate your JDK, and without it the SDK installer may refuse to install the Android SDK. Please note if you should ever use another version of the jdk. Then the JAVA_HOME variable will need to be updated.
* In Windows Vista/7/8 you can add JAVA_HOME by doing this through the Control Panel->User accounts 'Change my Environment Variables'. For this to take effect you must log out and back in.
* Once you have created the JAVA_HOME environment variable, run the SDK Tools installer.
* Once the installer has finished, it will automatically run the 'SDK Manager' app. This should have some default packages selected - install these packages.
* Also, install the 'Android 3.2 (API 13)' package.
* Edit your Monkey bin\config.winnt.txt file so that Monkey can find the Android SDK. Find the first line that starts with 'ANDROID_PATH=' and modify it so that it matches your SDK Tools installation path. See the existing config.winnt.txt file for examples.
* Restart Monkey. The Android target should now be available. However, you will need to either find/install the USB driver for your Android device, or create/run an Android emulator using the 'AVD Manager' in order to be able to run code on Android.



Gerry Quinn(Posted 2014) [#34]
"For what it's worth though, I reckon this stuff *is* harder than the actual game coding! At least with game coding, you have control over everything, and when things go wrong its generally due to something you did and can therefore have a shot at finding/fixing."

Probably that attitude is true of a lot of people here - it's the attitude that tends to make people prefer tools like Monkey to those like Unity etc.


zoqfotpik(Posted 2014) [#35]
Yeah, compiler hell actually is unreasonably difficult, at least when something goes wrong.


dawlane(Posted 2014) [#36]
For what it's worth though, I reckon this stuff *is* harder than the actual game coding!
Just image having to build an SDK from source code. Especially those SDK's that rely on external dependencies that need to be built from source as well. And you have to do it all over again when there is an update. You can spend more time just maintaining the development tools than actually writing some code.


marksibly(Posted 2014) [#37]
> * In the section 'SDK Tools Only' under Platform Windows 32 & 64-bit. Click the package named 'android-sdk_[version]-windows-zip' to download. Note: You will also see the Android SDK executable installer here as well.

Had forgotten about the Android SDK in .zip format!

I'm not sure about your claim that JAVA_HOME represents a 'security issue' - if it's not set to JDK, how do tools find javac (since it doesn't seem to be in PATH)? Most references to JAVA_HOME I can find say it should be set to JDK for development, eg:

http://stackoverflow.com/questions/17601827/which-one-should-java-home-to-point-jdk-or-jre

I can't find any references to potential security problems involving JAVA_HOME.


dawlane(Posted 2014) [#38]
I have never even tried the Android SDK in .zip format!
Mark I think you really need to to take a break from Monkey and play around with installing things the hard way with Linux for awhile ;-). All these Windows installers are taking the fun out of owning a computer.

Do we really need to cover the exe installer then?
Not really, unless they decide to ditch the zip format distribution. I think that they created that executable for *cough* ease of installation.

There is one thing. I haven't tested this myself, but I think that Android/flex/ant sdk's paths cannot have any space within their paths.

So far the only thing on Windows that I haven't managed to do yet is build Ted with QtCreator and MinGw combo.


marksibly(Posted 2014) [#39]
Did you see my comment re: JAVA_HOME and security?

I suspect JAVA_HOME is only used by ANT and maybe a few other 3rd party tools - ie: it's not a 'java thing'.

Probably best to just get them to set this as part of JDK installation.


dawlane(Posted 2014) [#40]
Did you see my comment re: JAVA_HOME and security?
You must have done a bit of editing while I was writing that reply.

I'm not sure about your claim that JAVA_HOME represents a 'security issue' - if it's not set to JDK, how do tools find javac (since it doesn't seem to be in PATH)?
I did some double checking on that.
Didn't notice in the post that I had put should instead of would.
Setting JAVA_HOME for system wide or local user from a security point of view would be OK as long as nobody starts to add %JAVA_HOME%\bin, %JAVA_HOME%\jre\bin or %JAVA_HOME%\jre\lib (think thats where the browser plugin is) to their PATH variable.


As long as the end user knows that doing such things as including the JAVA_HOME\jre\bin and JAVA_HOME\jre\bin\plugin2 (npjp2.dll in plugin2 should be the browser plugin) within their SYSTEM PATH variable. Then it could be a security risk if it's not updated when a new release of the JRE/JDK comes out.
Some people just add environment variables to the system and just forget all about them.

JAVA_HOME would be OK as long as they are using the JDK part and not the JRE part that is in the JDK directory. On Linux if you want use Oracle JDK/JRE you either have to rely on a third party PPA or use the JAVA_HOME and add JAVA_HOME with sub directories in a .profile or updatealternatives along with system links for browser plugins and keep them update manually. The PPA are treated like any other Linux package repository.

Probably best to just get them to set this as part of JDK installation.
For Monkey, I would just go with the zip file extraction for Android. After all, you have programmed transcc to use it's own environment set up i.e: JDK_PATH. If a user decides to use another tools to edit/compile the resulting Monkey code, etc, Then they should follow that tools install/set up instructions.