MapToolLauncher (or BAT file) works but MapTool never starts

Articles on how to do things in MapTool (answers only here -- questions should stay in the main MT forum)

Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice

Forum rules
Please discuss all HOWTO topics in the main forum. They will be moved here by a moderator when appropriate.
b0mbtrack
Kobold
Posts: 1
Joined: Tue Apr 13, 2010 6:28 am

MapToolLauncher (or BAT file) works but MapTool never starts

Post by b0mbtrack »

I have a new computer with windows 7, don't know if that matters, and when I click on maptools the little screen comes up that tells you the max mem. and min mem. when I click ok from there nothing happens. Anyone know what I need to do?

Phergus
Deity
Posts: 7132
Joined: Fri May 12, 2006 8:56 pm
Location: Middle of Nowhere, NM
Contact:

Re: maptools not loading

Post by Phergus »

It means that the java executables aren't in your path.

Try this:
Open a Command Prompt as Administrator.

CD into your C:\Windows\SysWOW64 directory.

Check for any java executables there. There shouldn't be any since the launcher isn't working.

Then type in:
Code:
mklink java.exe ..\system32\java.exe
mklink javaw.exe ..\system32\javaw.exe
mklink javaws.exe ..\system32\javaws.exe


And try the Launcher again.
Note that does assume you have Java installed and that there are the three Java executables in the system32 directory.

User avatar
Full Bleed
Demigod
Posts: 4736
Joined: Sun Feb 25, 2007 11:53 am
Location: FL

Re: maptools not loading

Post by Full Bleed »

This issue seems to come up often.

With Win 7 64 on a 32 bit Java install, the strange thing is that Phergus' MapToolLauncher.exe worked for me without having to do anything. But if I try and run any of the bat files it doesn't work (presumably a pathing issue.)

Phergus, is there something that you do differently in the launcher than the bat files that would account for that?


PS: Would it be possible to include a bat file with the install that would do the necessary pathing for people that have this problem? And could they just "Run as Adminstrator" to get it to work?
Maptool is the Millennium Falcon of VTT's -- "She may not look like much, but she's got it where it counts."

User avatar
Azhrei
Site Admin
Posts: 12086
Joined: Mon Jun 12, 2006 1:20 pm
Location: Tampa, FL

Re: maptools not loading

Post by Azhrei »

Full Bleed wrote:This issue seems to come up often.
It certainly has lately.
Phergus, is there something that you do differently in the launcher than the bat files that would account for that?
It won't be that he's doing anything different, but rather than the GUI environment itself is different. Not because of the PATH variable, but because the GUI has different libraries that are handling things differently. For example, calling system() when linked to the command line libraries probably works differently than calling it when linked to the GUI DLLs.
PS: Would it be possible to include a bat file with the install that would do the necessary pathing for people that have this problem?
Possible? Yes. But better for the user to fix their system so it's setup correctly. But then I'm not a fan of coddling users. 8)

User avatar
Full Bleed
Demigod
Posts: 4736
Joined: Sun Feb 25, 2007 11:53 am
Location: FL

Re: maptools not loading

Post by Full Bleed »

Azhrei wrote:Possible? Yes. But better for the user to fix their system so it's setup correctly.
Actually, it would be better for Java to install correctly. Some people have this issue and others don't. Why can I use the .exe and not the bat files on a fresh OS and Java install, but others can use both or neither? It makes little sense.

But then I'm not a fan of coddling users. 8)
Guess I don't look at it as "coddling users."

For many, this may be the only pure java app that they ever run. There isn't a good reason for it to be an annoying one. For every user that actually takes the time to register and ask why it doesn't work, 2 or 3 probably just move onto something else thinking that MT is too much trouble.

If the solution is a simple bat file that a user could click on and "Run as Administrator", or if the launcher could check for the pathing issue and fix it, what makes more sense: Answering the same question over and over again or just providing an automated solution?

No, you're probably right. Better for MT to weed out the technically non-proficient from the start. If they can't get past this they'll never get port-forwarding setup right. :roll:
Maptool is the Millennium Falcon of VTT's -- "She may not look like much, but she's got it where it counts."

nortonweb
Cave Troll
Posts: 70
Joined: Tue Apr 07, 2009 8:19 pm

Re: maptools not loading

Post by nortonweb »

I've started getting this issue on my home PC. If I start maptool from a clean reboot it works fine but if not normally it won't.
This is only a recent thing.
For me I fixed it by lowering the memory allocated to mapTool. If I drop it it works fine.

User avatar
Full Bleed
Demigod
Posts: 4736
Joined: Sun Feb 25, 2007 11:53 am
Location: FL

Re: maptools not loading

Post by Full Bleed »

nortonweb wrote:I've started getting this issue on my home PC. If I start maptool from a clean reboot it works fine but if not normally it won't.
This is only a recent thing.
For me I fixed it by lowering the memory allocated to mapTool. If I drop it it works fine.
This isn't the same issue. It sounds like your system has a memory leak (http://en.wikipedia.org/wiki/Memory_leak) caused by something else running on it.

When you boot your computer take a look at your Task Manager (ctrl-alt-del in Windows) and see how much memory the default processes are running. When you can't run MT at the higher amount of memory, check the processes again and see which program is consuming a significantly higher amount of memory than it was before. That might tell you what program is causing the problem.
Maptool is the Millennium Falcon of VTT's -- "She may not look like much, but she's got it where it counts."

nortonweb
Cave Troll
Posts: 70
Joined: Tue Apr 07, 2009 8:19 pm

Re: maptools not loading

Post by nortonweb »

I never considered that... now I want to go home and check darn this work thing it gets in the way so many times :D

Phergus
Deity
Posts: 7132
Joined: Fri May 12, 2006 8:56 pm
Location: Middle of Nowhere, NM
Contact:

Re: maptools not loading

Post by Phergus »

Full Bleed wrote:With Win 7 64 on a 32 bit Java install, the strange thing is that Phergus' MapToolLauncher.exe worked for me without having to do anything. But if I try and run any of the bat files it doesn't work (presumably a pathing issue.)
If I'm not mistaken the Path that is available in the command prompt doesn't include the syswow64 directory so batch files won't find the Java executables if they are there.
Full Bleed wrote:Phergus, is there something that you do differently in the launcher than the bat files that would account for that?
Not so much something I do different as more what Azhrei said. I'm actually using the CreateProcess() call and that is getting a different path than what you get from running a command in a command prompt. I imagine if I poked around in the Windows docs a bit I could figure out how to find the Java executables and then start things appropriately.
Full Bleed wrote:PS: Would it be possible to include a bat file with the install that would do the necessary pathing for people that have this problem? And could they just "Run as Adminstrator" to get it to work?
Sure. Something like this in a bat file should work:

Code: Select all

mklink %windir%\syswow64\java.exe %windir%\system32\java.exe
mklink %windir%\syswow64\javaw.exe %windir%\system32\javaw.exe
mklink %windir%\syswow64\javaws.exe %windir%\system32\javaws.exe

User avatar
Azhrei
Site Admin
Posts: 12086
Joined: Mon Jun 12, 2006 1:20 pm
Location: Tampa, FL

Re: maptools not loading

Post by Azhrei »

Phergus wrote:Sure. Something like this in a bat file should work:
That's a good idea. Name it so that people on WinXP and earlier (is anyone still there?) don't run it and you should be good.
FullBleed wrote:Actually, it would be better for Java to install correctly.
A clean install of Java should put the files in the right place. If they're not in the right place, then whoever did the OS build screwed it up. But that's obvious, I suppose.



Side question: why is there a syswow64 directory? Does Windows now come with World-of-Warcraft preinstalled? That would be amazingly efficient...

:mrgreen:

Phergus
Deity
Posts: 7132
Joined: Fri May 12, 2006 8:56 pm
Location: Middle of Nowhere, NM
Contact:

Re: maptools not loading

Post by Phergus »

Side question: why is there a syswow64 directory? Does Windows now come with World-of-Warcraft preinstalled? That would be amazingly efficient...
Heh. :)

Syswow64 is where the 32-bit binaries are kept for when 32-bit programs are run in the Windows on Windows 64 emulator.

User avatar
Azhrei
Site Admin
Posts: 12086
Joined: Mon Jun 12, 2006 1:20 pm
Location: Tampa, FL

Re: maptools not loading

Post by Azhrei »

Phergus wrote:Syswow64 is where the 32-bit binaries are kept for when 32-bit programs are run in the Windows on Windows 64 emulator.
There's not really an emulator, is there? Something as simple as a thunking layer would be sufficient, I would think.

I'm not familiar with the Windows memory model much anymore, but in the flat address space on 64-bit Linux, the bottom 4GB is where 32-bit apps live and the only requirement for them to work is a layer that converts 32-bit values into 64-bit values (filling the top bits with zero) and then forwarding to the 64-bit libraries. (Well, that and some magic to fix certain return values.)

Phergus
Deity
Posts: 7132
Joined: Fri May 12, 2006 8:56 pm
Location: Middle of Nowhere, NM
Contact:

Re: maptools not loading

Post by Phergus »

Yeah, I imagine that's what it really is.

Imvarda
Kobold
Posts: 2
Joined: Tue Mar 16, 2010 5:57 am

Re: maptools not loading

Post by Imvarda »

I also have this issue and I tried the suggested fix.

This is what happens:

http://dl.dropbox.com/u/5075273/rawr.png


Any suggestions on how to fix it?

I have windows 7, just reinstalled Java, then I tried doing the fix thing.

Phergus
Deity
Posts: 7132
Joined: Fri May 12, 2006 8:56 pm
Location: Middle of Nowhere, NM
Contact:

Re: maptools not loading

Post by Phergus »

My guess is that you messed up when you did the links and made them all to the javaws.exe file instead of java.exe to java.exe and so forth.

Post Reply

Return to “How To”