Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Emutron Questions  (Read 3804 times)

0 Members and 1 Guest are viewing this topic.

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Emutron Questions
« on: May 09, 2003, 12:08:52 am »
2 questions.

I need a sample of an avi and the script that someone has gotten it to run with for a screensaver.  Nothing I have tried works.

Also when I go to lauch a game it simply blows up.  I have tried it on XP and Windows 2000.  The two sample scripts that I downloaded both launch games differently.  Can someone post what they are doing in the event which launches mame.

Any help would be appreciated.  We are trying to get this cabinet ready for a kids birthday.

Thanks!

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Emutron Questions
« Reply #1 on: May 09, 2003, 12:57:17 am »
2 questions.

I need a sample of an avi and the script that someone has gotten it to run with for a screensaver.  Nothing I have tried works.

Also when I go to lauch a game it simply blows up.  I have tried it on XP and Windows 2000.  The two sample scripts that I downloaded both launch games differently.  Can someone post what they are doing in the event which launches mame.

Any help would be appreciated.  We are trying to get this cabinet ready for a kids birthday.

Thanks!

Sorry to hear you're having problems with EmuTron,
Let's see if I can answer your questions,

Quote
I need a sample of an avi and the script that someone has gotten it to run with for a screensaver.  Nothing I have tried works.

You can download the MameArcade avi file from my site at www.pacmanfan.com it's about 5mb and it probably won't be on the site for much longer.
EmuTron can currently play only avi files with no soundtrack and animated gifs.


Playing a movie is identical to loading a bitmap,

To play a movie during the screensaver, use this code

EVENT SCREENSAVER_START // this event is fired once automatically when the screen saver starts
       ACTIONS   
//This line load the movie:
        LoadBitmap(backgroundbitmap,"c:\movies\mamearcade.avi")
//Right after you load the movie, you can set it to loop like this:
        AnimateBitmap(backgroundbitmap,LOOP,"none")
       END_ACTIONS
END_EVENT

EVENT SCREENSAVER_DISPLAY
//this event is called automatically for every frame drawn to the screen
      ACTIONS   
  // this next line displays the movie into the rectangle specified by backgroundrect
   DisplayBitmapStretchFit(backgroundbitmap,backgroundrect)
      END_ACTIONS
END_EVENT

EVENT SCREENSAVER_END
// this is called automatically when the user presses a key
// I have it reload the current script to stop and re-start all animations
      ACTIONS   
        RunScript("scripts\mame.cfg") // reload the script to stop all animations
     END_ACTIONS
END_EVENT


Well, that's playing an avi file inside the screensaver in a nutshell.


Quote
Also when I go to lauch a game it simply blows up.  I have tried it on XP and Windows 2000.  The two sample scripts that I downloaded both launch games differently.  Can someone post what they are doing in the event which launches mame.

Well, there are 2 ways to launch emulators / applications through EmuTron.
Launch is the old method that is more compatible
Launch2 is the new method but more seemless

to use the Launch command, you need to open a  dos .bat  file, write some commands to launch the emulator with the right rom, write a command to relaunch emutron, and close the file, Then you Launch("etlaunch.bat") the file and exit EmuTron. the bat file re-launches EmuTron after it's finished running.

Some code to do all this:
EVENT LAUNCH_GAME
     KEYDEFS
        SCAN_LALT  // the left alt key launches
     END_KEYDEFS
     ACTIONS
     OpenWriteFile ("ETLaunch.bat")
     WriteToFile("cd " +mamepath)
     WriteToFile(mamename + " " + rompath + CurListItem(testgamelist,FILECOL) + ".zip")
     WriteToFile("cd " + emutronpath)
     WriteToFile("emutron.exe")
     WriteToFile("exit")
     CloseWriteFile()
     Launch("ETLaunch.bat")
     ExitProgram() // the ETLaunch.bat file reloads emutron
     END_ACTIONS
END_EVENT

If this code doesn't work, check your mamepath, mamename, and rompath.
open up the etlaunch.bat file inside the emutron directory and see what's being written to it. double click on it to test it.

The second method Launch2 is a little easier, however, I just discovered that it has some problems with DMame (Dos mame).

To quote from my doc file:
Launch2
The launch2 function is really a replacement for the Launch command. It has a few more parameters, but much better control over launching applications You can use it by the following syntax:
Launch2 ( exename , exepath ,parameters , pause)
exename is the name of the application you want to launch with the full path, ex: "c:\mame\mame.exe"
exepath is the path it's located ex:
"c:\mame\"
parameters is the parameters you're passing,(like the rom name)
pause is a flag , 0 or 1 to let emutron know whether or not it should wait until the program finishes before continuing.


To sum this up, with the Launch2 command, Emutron pauses all video and audio, and launches another application. It waits until the application (emulator) is done, the it un-pauses and continues onto the next line in the script.

Try this out, and if you're still having problems, email me your script, and tell me where your paths for mame, and your roms are, and I'll try to configure it for you.

-PacManFan
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Re:Emutron Questions
« Reply #2 on: May 09, 2003, 10:21:15 am »
I will try that out.  I think part of the problem is I am not even getting the batch file written out anywhere.

I already tried downloading that avi last night, but the link is broke, or at least the one from the scripts section is.  I didn't see anything on the download page for it.

Either way I am excited about this FE.  I will get it working eventually and hopefully for tomorrow morning.

Thanks again Steve.
« Last Edit: May 09, 2003, 10:23:33 am by nfdavenport »

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Re:Emutron Questions
« Reply #3 on: May 09, 2003, 11:04:44 am »
Hmmmm.  It looks like the exact same code that writes out the batch file works in some places and not in others.  For example, I copied the code to the SCSTART event with minor changes to identify the file, and it writes out fine there.  But for some reason it won't write out in the LAUNCH_GAME event.

I will keep playing around with it.

Edit:  Ooops, scratch that.  It is writing it out and launching now.  Great!  Taking out the delayed launch stuff seemed to help too.  Thanks Steve!

Would still love a copy of that AVI!
« Last Edit: May 09, 2003, 11:25:47 am by nfdavenport »

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Re:Emutron Questions
« Reply #4 on: May 09, 2003, 11:48:56 am »
Oh, also, is the sound working in avi files yet?  I saw old stuff saying it didn't work, but nothing recent.

Thanks!

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Emutron Questions
« Reply #5 on: May 09, 2003, 01:14:57 pm »
Oh, also, is the sound working in avi files yet?  I saw old stuff saying it didn't work, but nothing recent.

Thanks!
Sound is still not working for avi files,
I just ran across some great c++ code on the internet that will allow me to play avi, mpg's .qt, asx , and asf files from withing EmuTron with sound. I'm incorporating the code now, and it should be in the next version.
-PacManFan
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

wee beastie

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 180
  • Last login:October 06, 2003, 03:33:02 pm
  • I'm a llama!
Re:Emutron Questions
« Reply #6 on: May 09, 2003, 03:49:06 pm »
PacManFan,

OK, I don't have the latest version of EmuTron, so I can't tell if these have been fixed (or even brought to your attention), but I noticed a few bugs and/or features that would be helpful.

The first feature is a way to stop an mp3.  For example.  In my mame script, I have the ambient arcade mp3 playing in the background.  I would like that to stop when the screensaver kicks in.  Unfortunately it doesn't, and sound continues playing thru the screensaver.

The second has to do with the screensaver also.  I've noticed that if I leave a game running in mame for awhile (ie the attract screen running but not actually playing the game) the screensaver starts running.  Note:  the screensaver doesn't run over the game, but if I hit the escape key to exit the game and get back to EmuTron, the screensaver movie is going.  Obviously I then hit a button and the screensaver stops.  This is not a major problem, but I fear that this is probably going to affect system performance if a movie is playing "behind" MAME.

I'll probably get the latest version of EmuTron at some point in the near future, but I'm too busy setting up other emus, that I haven't tried updating yet.

Thanks for all your work!!!

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Emutron Questions
« Reply #7 on: May 09, 2003, 05:07:56 pm »
PacManFan,

OK, I don't have the latest version of EmuTron, so I can't tell if these have been fixed (or even brought to your attention), but I noticed a few bugs and/or features that would be helpful.

The first feature is a way to stop an mp3.  For example.  In my mame script, I have the ambient arcade mp3 playing in the background.  I would like that to stop when the screensaver kicks in.  Unfortunately it doesn't, and sound continues playing thru the screensaver.

The second has to do with the screensaver also.  I've noticed that if I leave a game running in mame for awhile (ie the attract screen running but not actually playing the game) the screensaver starts running.  Note:  the screensaver doesn't run over the game, but if I hit the escape key to exit the game and get back to EmuTron, the screensaver movie is going.  Obviously I then hit a button and the screensaver stops.  This is not a major problem, but I fear that this is probably going to affect system performance if a movie is playing "behind" MAME.

I'll probably get the latest version of EmuTron at some point in the near future, but I'm too busy setting up other emus, that I haven't tried updating yet.

Thanks for all your work!!!

Hey wee beastie,
Get the latest version, I think I sent you a custom build before. In order to stop an mp3 from playing, call PlayMP3 with something that doesn't exist like:
PlayMp3("nomp3","nocallback") or some other bogus data.

And don't worry about the movie playing behind mame, it's not. I think what's going on is, in the build I sent you to test out Launch2, When I launch2 a game, I tell EmuTron what time it is , and When the game is over and EmuTron starts back up, I tell it what time it is again, so it can re-start animations, video, sound , etc.. All this is going on behind the scenes. I think in the version I gave you,  my screen saver counter thinks Emutron had been running the whole time with no input, go it immediately goes into screen saver mode when you return from a game. I had noted that, and the new 2.15 version has that fixed.

-PacManFan
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Re:Emutron Questions
« Reply #8 on: May 10, 2003, 03:26:26 pm »
Well, late last night we got the cabinet all put together and everything working pretty much like we hoped.  Somewhere nearby my friend's son is having a kick butt birthday party.

I just wanted to report back and comment on Emutron.  I wouldn't have gotten the project done without it.  Being a programmer I much preferred its flexibility over its complexity, although I almost gave up a couple of times.

Here's what we wanted out of a frontend:
-categorized menu
-skinnable
-could run other non-mame executeables
-played mp3s
-could use the Arcade '84 .mov files for screensaver.

Obviously, Emutron did the first few easily.  The screensaver was another trick.  I never did get it to work inside Emutron, but I didn't spend much time at it since there isn't any sound yet anyways.  It really wasn't all that hard however, using the launch command.  I copied how the script created a batch file that ran a program (like mame) and then restarted Emutron when it was done.  Using that method it was simple.  

First I made made a windows screensaver out of .AVIs that I created from the quicktime movies.  Then I made a batch file that started the screen saver immediately. (fairly simple: 'screensaverfile.scr -test' all on one line.  You get a brief message saying something like it is now testing the screensaver.)  The batch finished by restarting emutron.  Then I simply launched the batch file and exited emutron inside the screensaver start method.  It isn't as pretty as if it were done directly in emutron, but it got the job done nicely.

Now for the few problems I had.  Of course, I never read completely through the docs so I these things may be possible or mentioned already, etc.  Take these comments from user friendliness perspective.

-Rapid input, like holding down the joystick to scroll through the list will eventually make emutron crash almost everytime on our setup.  (FYI, we're using an I-PAC in USB mode with the keyboard attached to the I-PAC.)

-Emutron won't run without a mouse attached to the machine, at least on windows2000.

-The list format seemed fairly picky and I had problems editing it by hand.  Extra spaces on the ends of rom names would cause problems when building filenames, etc.  I would hesitate to suggest it, but I would like a nice XML format.

-The config program wouldn't run on my windows 2000 machine so I had to make the lists on winXP.  Once after trying to do a list import, it never worked correctly again and I had to reinstall to a clean directory.

-I wanted to build a filter based on the clone field, but it didn't seem to be an option.  Being able to do it based on raster/vector  trackball and other would be nice too.

-Somehow I once got a nice list end separator on one short list, but lost it later.

-I didn't seem to have a lot of control over the way the game selection list worked.  It would be really nice if you could make it scroll smoothly.  It is very jumpy and distracting in its current form.

-Often times mame wouldn't started correctly from emutron, but running the ETLaunch.bat that had been created worked fine.  Perhaps ET hadn't finished giving up control over the windows resources it is using quickly enough?

There were other minor issues, but these are the ones I remember the most.  Over all I am very pleased and excited to have gotten everything working.  Please remember this was from a one and a half day experience and if I had time I might have figured more out myself.  

Of course, half the day was spent trying to figure out how to convert quicktime6 files to AVIs and making screensavers without paying for software I didn't already own. :)  I ended up having to sample the sound from the wave-out device and remux the streams.

Anyway, thanks for all the help!  I am anxious to see what's coming next.

-Nathan








wee beastie

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 180
  • Last login:October 06, 2003, 03:33:02 pm
  • I'm a llama!
Re:Emutron Questions
« Reply #9 on: May 10, 2003, 03:52:20 pm »
Nathan,

I can comment on Emutron crashing when scrolling thru games quickly.  It isn't a bug with emutron.  The problem is that you've got a bad screenshot in your game list.  This can be fixed by deleting the bad screenshot.  So, scroll thru your gamelist slowly, and when the bad screenshot is displayed (most likely it will first appear in the "screenshot previews" at the bottom) your emutron will crash.  So, note what game it crashes on, go to your game list and note which game is 5 below the one that caused it to crash (as the game preview shows the next 5 games down the list), then go into your screenshots directory and delete that screenshot.

That's how I fixed the same problem.

As for it not scrolling smoothly or fast enough, it really depends on how much you have going on.  I turned off the alpha blending on the cab pics and the bitmap animations on the flyer (you know the cabinet pic fading in and out and the flyer that shrinks and expands) this eliminated those problems as well.  I believe we both may need a better processor or more ram to handle all those features "smoothly."

I can't guarantee that this will fix your problems, but I had the same issues and found these to be the solution.  So go ahead and give it a try.

PacManFan, I don't mean to steal your thunder a you know more about your frontend than I do.   I'm simply trying to lend a helping hand.

wee beastie
« Last Edit: May 10, 2003, 03:54:43 pm by wee beastie »

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Emutron Questions
« Reply #10 on: May 10, 2003, 04:33:40 pm »
No problem wee, beastie,
This is the sort of thing I was hoping to see, other users helping out.
As far as the ETConfig probram goes, I've heard afew few reports about problems on XP. Currently, adding new features is on hold (except multi-monitor support)until I re-write the etconfig setup program in c++, it will include a few new features such as an optional XML format, ability to sort / filter by a few more fields such as clone info, controller types, screen orientation, and a few more fields out of the listinfo.
Most importantly, I'm rewriting the etconfig to include the Skinner / autoscripter feature.
Once this is complete,  you'll never have to write a line of script again (Hopefully  ;)). It's coming along nicely, and allows you to drag and drop differant visual features (text /bitmaps /preview lists/ etc..) on the script and right click to set up thier properties (when they are loaded/ when they are displayed/ how they are displayed/ etc..)
I plan to release it the same day HC releases his new front end.  ( ;) just kidding!)
--PacManFan
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

)p(

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 964
  • Last login:March 27, 2009, 03:38:15 am
  • We are the Galaxians...
    • Emulaxian:cabinet and frontend
Re:Emutron Questions
« Reply #11 on: May 10, 2003, 05:29:57 pm »
It's coming along nicely, and allows you to drag and drop differant visual features (text /bitmaps /preview lists/ etc..) on the script and right click to set up thier properties (when they are loaded/ when they are displayed/ how they are displayed/ etc..)--PacManFan

That's sounds really nice :D
I am curious, as it has not been done before, how you plan to integrate the animation of the bitmaps in the skinner. Will it also be done interactively and visually? that would be cool!

(I did setup the basics a while back in my skinner to use keyframed animation but I am not happy with it...it gives me not enough control as I can do it in Director much better directly for my own skins.  So hopefully I can learn something about how you solve this when I get back to working on my fe  ;) )


peter

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Emutron Questions
« Reply #12 on: May 10, 2003, 06:05:23 pm »
It's coming along nicely, and allows you to drag and drop differant visual features (text /bitmaps /preview lists/ etc..) on the script and right click to set up thier properties (when they are loaded/ when they are displayed/ how they are displayed/ etc..)--PacManFan

That's sounds really nice :D
I am curious, as it has not been done before, how you plan to integrate the animation of the bitmaps in the skinner. Will it also be done interactively and visually? that would be cool!

(I did setup the basics a while back in my skinner to use keyframed animation but I am not happy with it...it gives me not enough control as I can do it in Director much better directly for my own skins.  So hopefully I can learn something about how you solve this when I get back to working on my fe  ;) )


peter

I'm laying out the animations along a time-line, For each event , you can right click on it to bring up an animation view. The animations are layed out from left to right and color coded to show if they (1 loop)  (2 call other animations) or (3 stop after they are done). It looks sort of like a movie editor view.

Basically, the skinner layout is EmuTron running in an "Interactive" mode. You can add new variables, move things around, change parameters, and get instant feedback about how it looks. You can single-step through the display event and see how things are being drawn. You can manually fire off events to see how they perform. There is also a "sequencing" view to show the layout of actions in the events.
-PMF
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

nfdavenport

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 16
  • Last login:December 23, 2003, 09:45:42 pm
  • Going Wireless
Re:Emutron Questions
« Reply #13 on: May 10, 2003, 08:46:27 pm »
Thanks for the tip beastie.

Sounds like lot of cool new stuff coming along, I can't wait.  I wish I new more c++ and windows programming so I could help.  Unfortunately, I am a java developer and think that a pointer is something like the helpful hint that beastie gave me and not a programming language construct.

I also had a thought about the scrolling selection list.  Maybe the selected value could move down rather than rolling the list up.  Each time you hit the bottom you scroll down a whole 'page' worth.  I think that would look a little smoother.  Is this something I could change through scripting or is it built into the executeable?

Anyway, have a great weekend guys.

-nathan


wee beastie

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 180
  • Last login:October 06, 2003, 03:33:02 pm
  • I'm a llama!
Re:Emutron Questions
« Reply #14 on: May 10, 2003, 11:19:10 pm »
hehhhehe

I pimped out the frontend.  In the background it's playing the arcade84 avi file.  The gamelist is on the left of the screen and the right side has a cab/screenshot pic.

The cab alphblends in then blends out.  As it's blending out, a screenshot is alphablending in at the same location on the screen.  Looks great, but it's heavy on  my system.  The avi in the background doesn't seem to hurt performance too much, but the 2 alphblending images begins to make it stutter a bit .  It makes sense as it's animating 2 alpha values- one starting at max and one starting at min.  The real trick to improve performance I've found is to set the timer on the alpha blending really high (mine is set to 10,000 ms) then it will run smooth enough on my system.

Boris

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 11
  • Last login:October 21, 2004, 03:12:42 pm
    • The Boris zone
Re:Emutron Questions
« Reply #15 on: June 02, 2003, 02:45:22 pm »
I plan to release it the same day HC releases his new front end.  ( ;) just kidding!)
--PacManFan
Dragon is out, waiting the new Emutron... ;D