Build Your Own Arcade Controls Forum

Front End Support => MaLa Frontend => Topic started by: mrclean on December 06, 2007, 05:03:19 pm

Title: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 06, 2007, 05:03:19 pm
It claims to automatically map each respective game automatically to the ugc files, does this mean I need to create a file for each game? and how do i know its working ?
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: fatfingers on December 06, 2007, 05:07:56 pm

You do not need to create a map for each game.  By default it has maps for 4-way, 2way, 8way, analog, etc. games.  The plugin gets the default controls for each game and will automatically apply the correct x-way map for the game.  You only need to create .ugc files for games that you don't like the default controls (for example, q*bert -- 4-way 45 degree rotation).  Basically, if you can move 8-ways in an 8-way game and only 4-ways in a 4-way game, everything is working well.  If you're insistent on knowing you can create a umapper.log file in the mala directory and the plugin will log some very crude debug logs to that file.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 06, 2007, 05:24:08 pm
I feel like everything is set to "analog" mode what game can i test etc to make sure that its doing what it should be
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 06, 2007, 06:15:02 pm
I tested it by making a ridiculous map (all "right"), renaming it the same as the 4-way map, and running a 4-way game.  When I played Frogger, I pushed left and I moved right.  I pushed up and I moved right.  Works!

Don't forget to create a backup of the old files you're replacing, of course - and also to switch it back before guests arrive.

EDIT: Fixed "your" to "you're".  :-[
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 06, 2007, 06:15:33 pm
Quote
  you can create a umapper.log file in the mala directory and the plugin will log some very crude debug logs to that file.

EVENT: Game quit (ROM: 'qberta')

_build_mapname: Built map file name: 'C:\Program Files\mala\Maps\mala.ugc'
_file_exists: Seeing if file 'C:\Program Files\mala\Maps\mala.ugc' exists
_file_exists: 'C:\Program Files\mala\Maps\mala.ugc' does exist
_run_ultramap: command line '"ultramap.exe" "C:\Program Files\mala\Maps\mala.ugc"'
_run_ultramap: Failed to create process '"ultramap.exe" "C:\Program Files\mala\Maps\mala.ugc"': error 2
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 06, 2007, 07:30:06 pm
maps in U360's don't seem to be working in "test pattern" area right now Only one of the maps will.. in other words if i set it to 2-way thats how it will operate in an 8-way mode.. I don't get it im soo confused!
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: fatfingers on December 06, 2007, 09:30:29 pm

Looks like you didn't add the ultramap directory to your path environment variable.  Here is an example (http://www.computerhope.com/issues/ch000549.htm) of how to do that.

In this case, you will want to add the bold contents as shown below:

C:\Program Files;C:\Winnt;C:\Winnt\System32;C:\Program Files\UltraMap

At least, that is the default UltraMap installation directory.  if you installed it in a different directory, then you'll want to modify your path appropriately.

Good luck!
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 06, 2007, 10:24:37 pm
I did that created a path named it "ultimarc" and put in this :::  C:\Program files\ultramap yet another failure..

 _build_mapname: Built map file name: 'C:\Program Files\mala\Maps\mala.ugc'
_file_exists: Seeing if file 'C:\Program Files\mala\Maps\mala.ugc' exists
_file_exists: 'C:\Program Files\mala\Maps\mala.ugc' does exist
_run_ultramap: command line '"ultramap.exe" "C:\Program Files\mala\Maps\mala.ugc"'
_run_ultramap: Failed to create process '"ultramap.exe" "C:\Program Files\mala\Maps\mala.ugc"': error 2
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: Lakersfan on December 07, 2007, 12:27:40 am
this is an interesting thread for me as well. I just started to set up my U360's and I'm not 100% sure the plugin is working either. I'll try some of the suggestions posted here tomorrow morning when I get home.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: fatfingers on December 07, 2007, 01:27:49 am
I did that created a path named it "ultimarc" and put in this :::  C:\Program files\ultramap yet another failure..

What do you mean by "named it 'ultimarc'"???  The c:\Program Files\ultramap needs to go in the PATH environment variable, not a new one.  Basically you need to find the path one on the screen and add that C:\Program Files\Ultramap string to it.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: headkaze on December 07, 2007, 04:13:32 am
fatfingers: I'm not sure why you use the PATH environment variable in your application. There are ways to get the path of a dll in Delphi, then you can use that path to combine a relative path. It also means you don't need to rely on it being the current directory. Using GetModuleFileName you can get the full path of the dll, then remove the name of the exe and use it to combine with your relative folders.

http://www.scalabium.com/faq/dct0098.htm
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: loadman on December 07, 2007, 04:43:29 am
fatfingers: I'm not sure why you use the PATH environment variable in your application. There are ways to get the path of a dll in Delphi, then you can use that path to combine a relative path. It also means you don't need to rely on it being the current directory. Using GetModuleFileName you can get the full path of the dll, then remove the name of the exe and use it to combine with your relative folders.
http://www.scalabium.com/faq/dct0098.htm

I think FatFingers Uses C++  , but yeah.... in my plug-in's in Delphi I use a command like this to make sure that the plug-in is looking for files in the right directory

eg:
Code: [Select]
if fileexists (extractfilepath(application.exename)+'plugins\EmuWave_Config.ini') then
   begin

That way it does not matter what directory the user has MaLa in, I just look for subdirectories hanging off that.

I hope that helps?  I would have loved to have know that tip when I started. I got into a lot of 'current directory' problems when I started writting MaLa plug-ins.   ;)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: headkaze on December 07, 2007, 05:37:59 am
In that case for C++ I would use the following

Code: [Select]
void GetApplicationDir(char *str)
{
char szPath[MAX_PATH+1];
GetModuleFileName(NULL,szPath,MAX_PATH); // Get the exe filename (e.g. "C:\foo\bar.exe"
char* psz = strrchr(szPath,'\\');  // Find the last backslash

if(!psz) { strcpy(str,szPath); return; }

psz[1] = '\0';   // Trim it off (leaving "C:\foo\")

strcpy(str,szPath);

return;
}
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaOld Man on December 07, 2007, 07:09:46 am
I hate to hijack this thread, but first let me say "hats off" to the creators of mala.
It is a very versatile front end, and I love it.
 :applaud:
Now my question. Is it possible to write plugins using VB6??
Thanx.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: loadman on December 07, 2007, 07:19:26 am
Now my question. Is it possible to write plugins using VB6??
Thanx.

Sorry to hijack this thread.

Nah, I went down that path. VB6 uses a different type of DLL( which is all a plug-in for really mala is)

But if you want to try your hand at another language I'm sure you will get plenty of support. In essence a MaLa plug-in is pretty straight forward. Give it a whirl. This link shows you how to start for free and the supplied example will show you what a plug-in can do.  :)

http://wiki.arcadecontrols.com/wiki/Mala_Plugins (http://wiki.arcadecontrols.com/wiki/Mala_Plugins)

Start a new thread if you have questions   :)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: loadman on December 07, 2007, 07:21:08 am
(e.g. "C:\foo\bar.exe"


How very UNIX of you  ;D
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: headkaze on December 07, 2007, 07:45:25 am
(e.g. "C:\foo\bar.exe"


How very UNIX of you  ;D

I pasted that from a C++ dll I wrote but I didn't write that function. I know I didn't write it because it has comments, and I rarely write code with comments lol I've used that phrase before and I don't consider myself a UNIX guy. Although I was a bit of a wiz on System V back in the day ;)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: fatfingers on December 07, 2007, 08:21:42 am

The problem here is that UltraMap.exe can be installed anywhere.  I don't have a DLL (or exe) to use GetModuleFileName on because I don't know where it is.  I could write a config file I suppose so people can put the location of their ultramap.exe in it, but I was originally hoping to do everything without a config file.  Apparently I overestimated the familiarity with computers of many people -- it all comes easy to me, so sometimes I forget it doesn't for all.

I'm open to other suggestions.

Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaOld Man on December 07, 2007, 08:22:57 am
Now my question. Is it possible to write plugins using VB6??
Thanx.

Sorry to hijack this thread.

Nah, I went down that path. VB6 uses a different type of DLL( which is all a plug-in for really mala is)

But if you want to try your hand at another language I'm sure you will get plenty of support. In essence a MaLa plug-in is pretty straight forward. Give it a whirl. This link shows you how to start for free and the supplied example will show you what a plug-in can do.  :)

http://wiki.arcadecontrols.com/wiki/Mala_Plugins (http://wiki.arcadecontrols.com/wiki/Mala_Plugins)

Start a new thread if you have questions   :)

OK thanks, its just that old saying about new tricks and old dogs..
Maybe after Christmas is behind me, I will have some time to study up on Delphi or C++
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: headkaze on December 07, 2007, 09:00:50 am

The problem here is that UltraMap.exe can be installed anywhere.  I don't have a DLL (or exe) to use GetModuleFileName on because I don't know where it is.  I could write a config file I suppose so people can put the location of their ultramap.exe in it, but I was originally hoping to do everything without a config file.  Apparently I overestimated the familiarity with computers of many people -- it all comes easy to me, so sometimes I forget it doesn't for all.

I'm open to other suggestions.

Ahh I see.. well I guess if the path of UltraMap is not stored in the registry when you install it, you could add it to the environement variable programmatically. I'm not sure how to do that though but it shouldn't be too difficult I would think.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: fatfingers on December 07, 2007, 09:50:52 am
well I guess if the path of UltraMap is not stored in the registry

I assume you meant is stored in the registry?

Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 07, 2007, 11:51:41 pm
I'm still super lost and my joysticks / mapper doesnt map correctly still stuck in using exclusivly just 8-way mode for everything as of now... I think I need a video or pictures im that retarded
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 11:14:51 am
Let's start from the beginning mrclean:

Can you go into the UltraMapper Utility and manually change your maps?  (I assume "yes" because you said you change them to 8-way).

The plug-in is in the right spot, correct?  Your paths should look like this:

Code: [Select]
   [MaLa dir]\plugins\UltraStikMapPlugin.mplugin
   [MaLa dir]\Maps\*.ugc

You change the "Path" value in your environmental variables?

Have you tried making a "rom-specific" map.   Copy 4-way.ugc or whatever and paste it in the same folder.  Change it's name to the name of a rom that uses that specific control type and fire it up?   Does it work?

(Quick related question to everyone else, not a hijack - what file does the plugin utilize to get the control type of a specific game?)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: loadman on December 08, 2007, 05:10:57 pm
(Quick related question to everyone else, not a hijack - what file does the plugin utilize to get the control type of a specific game?)

Controls.ini. MaLa reads it and passes the data onto the plugin on the fly when a game is selected in the list.  Note: If you change something in controls.ini you will have to refresh the main game list in order to force mala to read that file again.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 06:15:22 pm
Quote
You change the "Path" value in your environmental variables?

Im not sure exactly what i should be doing with that .. i typed in "ultimarc" as the name and pointed it to the mapper software what am i doing wrong got screen shots ?
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 06:44:56 pm
No, you don't add a new value.  You change the value of "PATH" by adding "C:\program files\ultimarc".  See picture I added.   

Go to CONTROL PANEL -> SYSTEM -> ADVANCED TAB -> ENVIRONMENTAL VARIABLES -> Click Edit when you highlight the "Path" value (or double click) and at the end of the whole list, add a semicolon and the path to your ultramap software.

EDIT: Added what it should look like if you're changing it correctly. 

And thanks loadman for your answer.  That's what I figured but I didn't want to assume.  MrClean, you have a copy of controls.ini too, correct?
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: loadman on December 08, 2007, 07:03:53 pm
Quote
Go to CONTROL PANEL -> SYSTEM -> ADVANCED TAB -> ENVIRONMENTAL VARIABLES -> Click Edit when you highlight the "Path" value (or double click) and at the end of the whole list, add a semicolon and the path to your ultramap software.]Go to CONTROL PANEL -> SYSTEM -> ADVANCED TAB -> ENVIRONMENTAL VARIABLES -> Click Edit when you highlight the "Path" value (or double click) and at the end of the whole list, add a semicolon and the path to your ultramap software.

No Offence to my good mate fatfingers. But can someone show him a better way to deal with paths in C++ so that the set-up process is not so hard  :(    he he   because I plan to get some U360 for xmas  ;D
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 07:47:36 pm
No, you don't add a new value.  You change the value of "PATH" by adding "C:\program files\ultimarc".  See picture I added.   

Go to CONTROL PANEL -> SYSTEM -> ADVANCED TAB -> ENVIRONMENTAL VARIABLES -> Click Edit when you highlight the "Path" value (or double click) and at the end of the whole list, add a semicolon and the path to your ultramap software.

EDIT: Added what it should look like if you're changing it correctly. 




Wahooooooo ! !!  ! That did it ! !! ! THANKS!  !!

I tested 3 games, a 4-way,and 8way and an analog  umpapper log file said;
........_run_ultramap: '"ultramap.exe" "C:\Program Files\mala\Maps\4way.ugc"' completed successfully
.......EVENT: Game start analog.ugc"' completed successfully Etc....
~... which is great but..

*However; just one error while loading q-bert i got this (http://img266.imageshack.us/img266/1776/81843522wj7.png) http://img266.imageshack.us/img266/1776/81843522wj7.png but yet after it said "completed successfully," in the umapper log file?


Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 07:53:14 pm
There was a naming error in the 45 degree, 4-way scheme (because ultramap uses a different name).   You have two options:

1. Open the 4-way,45 degree.ugc file in the MAPS directory of MALA with notepad and change the map files to "4 Way, Diagonals Only.um" (without the quotes).

2. Go to your Ultramap/maps directory and rename "4 Way, Diagonals Only" to "4-way, 45 degree angles" (leaving the extension the same). 

I recommend the first way.

(By the way: The Environmental Path editing and the Q-Bert mapping tripped me up a bit at first too.   Regardless, still a great plugin!   :cheers:)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 08:25:04 pm
Dave, I tried doing both methods and neither worked? same error ?
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 08:34:49 pm
Make sure the file names in the maps section of the Ultramap software and the names in the 4-way, 45 degree.ugc file (in the mala/maps path) match exactly.  That includes spaces, commas, etc.   
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 08:43:50 pm
Gonna keep trying.. but not to hi-jack my own thread but im looking for 1280x1024 mala layout(s) I really like the BLUE layout from gamecreature, but i cant seem to find it in that high of a resolution and then i stumbled upon the retro one with the animation space invaders scrolling by i thought that was sooo cool! but I need 1280x1024 I noticed that When i tried to stretch one to that resolution the windows green button / bottom bar kept apearing and flickering almost like a layer ontop of MaLa whats up with that ?>
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 09:03:41 pm
I'll make it easy (unless you changed the names of the maps in the Ultramap folder).

1. Go to MALA\MAPS (assuming default install)
2. Open 4way45degree.ugc with notepad.
3. Select all text and delete.
4. Copy the following:

Code: [Select]
# This is an Ultimarc UltraStik Game Configuration file
UltraStikGameConfigurationFileFormatVersion=1.0

UltraStik1MapFile=4-Way, Diagonals Only
UltraStik2MapFile=4-Way, Diagonals Only
UltraStik3MapFile=
UltraStik4MapFile=

5. Paste it into the now empty notepad file you opened.
6. Save.

As for your layout - why not drop down your screen resolution.  The MAME games all use much lower resolutions anyhow.    Even if it's a multi-use computer (i.e. desktop), Mala has a setting that will change the resolution to the size of the theme when you start it up).  This should expand your choices significantly.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 09:24:21 pm
obviously i messed with this file too much.. now I no longer get the error.. but in qbert I have NO movement what-so-ever
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 09:29:36 pm
Now this is Odd.. I just played namco's classics vol. one fine.. tried to reload it with MaLa.. and it kicked me right out after MAME decoded the game.. then i was presented with the OK/ Move joystick left right...  "100% video emulation / etc..." but I just played it moments ago ? boots me right back to MaLa with a Dos box in the background that i never used to get in mamewah? it dissapeared too fast said something i think about speed emulation not sure.. but my main concern is that I just played that Namco classics game fine and now its not letting me play it? Any one else have the same issue ?:

tried to get back into a savestate from gun.smoke.. no issues on that game.. so inreguards to Namco's classics Vol.1.. I'm not sure if this is just a game specific issue with mame / or mala / or the umapper ?
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: DaveMMR on December 08, 2007, 09:33:21 pm
obviously i messed with this file too much.. now I no longer get the error.. but in qbert I have NO movement what-so-ever

Make a new map in Ultramap for Q*Bert (or re-edit the old one) and match that file name in the 4way45degree.ugc file. 

Now this is Odd.. I just played namco's classics vol. one fine.. tried to reload it with MaLa.. and it kicked me right out after I got to the screen when it said "100% video emulation / etc..." but I just played it moments ago ? boots me right back to MaLa with a Dos box in the background that i never used to get in mamewah?

You may want to start a new thread on that one.
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: mrclean on December 08, 2007, 11:14:01 pm
i think this image pretty much sums it up (http://www.cartoonesque.com/futurama/rsrc/illu/pacman.jpg)

Thanks Again DaveMMR..

I still didn't fix Q*Bert.. too tired maybe tomorrow but a big thank you, along with everyone else on this friendly forum. I'll be starting a thread tomorrow in reguards to MaLa it self I'm gonna need alotta help.. I had mamewah working with everything (ALL emu's etc..)But.. I'm converting to MaLa  and have my work cut out for me, keep an eye gonna need help for sure  ;-)
Title: Re: How do I know MaLa Pluggin for my U360's are working properly ?
Post by: Ninja Supremacist on January 03, 2008, 10:31:21 am
-