Author Topic: Portable mode or relative paths  (Read 19291 times)

Madcore

  • Newbie
  • *
  • Posts: 1
    • View Profile
Portable mode or relative paths
« on: October 11, 2015, 07:18:58 AM »
Hi.

I´m using my emulation environment in a external HD in "portable mode", I mean, using relative paths to launch everything ignoring driveletters. I discovered Attract Mode and really like it, but I can't make it work with relative paths, only with absolutes or with system variables. There's a way I can use relative paths or create new variables for the paths?

Thanks, and sorry for my bad english.

De_Cadanz

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Portable mode or relative paths
« Reply #1 on: October 13, 2015, 07:14:51 AM »
Hello, check my emulator config example:
Code: [Select]
executable           retroarch\retroarch.exe
args                 -L cores\genesis_plus_gx_libretro.dll "..\[romfilename]"
rompath              roms\gen
romext               .gen
system               Sega Genesis
info_source          thegamesdb.net
Use subfolder paths as usually, use ..\ for level up :D

akafox

  • Hero Member
  • *****
  • Posts: 985
    • View Profile
Re: Portable mode or relative paths
« Reply #2 on: October 16, 2015, 07:37:40 PM »
MadCore I am sure that is possible. However you will have to make sure that the external drive is the same drive letter every time.

We can help you better if we know what OS you are using though.
People want life easy..then complain about it

mattgrimley

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Portable mode or relative paths
« Reply #3 on: October 17, 2015, 04:01:33 PM »
Relative paths work fine with attract mode in Windows (as De_Cadanz says), though some layouts (such as roboskin) seem to require an extra ..\ in the resource paths.

My mame "emulator" cfg file works fine on Windows for a structure of:
path:\emulators
path:\frontends
path:\Roms
path:\Artwork

Code: [Select]
# Generated by Attract-Mode 1.6.0
#
executable           ..\..\emulators\MAME\v0.163b\mame.exe
args                 [name] -skip_gameinfo -nowindow
rompath              ..\..\roms\mame_v0.163\
romext               .zip;.7z;<DIR>
system               Arcade
info_source          mame
import_extras        ..\..\emulators\MAME\Common_Files\catver.ini;..\..\emulators\MAME\Common_Files\nplayers.ini
artwork    flyer           ..\..\..\..\artwork\MAME\flyers\
artwork    marquee         ..\..\..\..\artwork\MAME\marquees\;..\..\..\..\artwork\MAME\marquees_alt\;..\..\..\..\artwork\MAME\banner\;..\..\..\..\artwork\MAME\wheel\
artwork    snap            ..\..\..\..\artwork\MAME\video_mp4\;..\..\..\..\artwork\mame\snap\
artwork    wheel           ..\..\..\..\artwork\MAME\wheel\;..\..\..\..\artwork\MAME\banner\;..\..\..\..\artwork\MAME\marquees\;..\..\..\..\artwork\MAME\marquees_alt\

However you will have to make sure that the external drive is the same drive letter every time.
This isn't actually needed at all as long as you run attract mode from the same external drive. :)
« Last Edit: October 17, 2015, 04:03:55 PM by mattgrimley »

mondaiji

  • Full Member
  • ***
  • Posts: 46
    • View Profile
Re: Portable mode or relative paths
« Reply #4 on: November 04, 2015, 05:01:00 PM »
Is there anyway to set a global variable for paths without specifying it in every .cfg file?

e.g.

$emulators="..\..\emulators\"

executable           $emulators\MAME\v0.163b\mame.exe

jonnytracker

  • Jr. Member
  • **
  • Posts: 16
    • View Profile
Re: Portable mode or relative paths
« Reply #5 on: November 16, 2015, 02:23:43 AM »
yes, how to command

bionictoothpick

  • Sr. Member
  • ****
  • Posts: 320
  • He who laughs lasts.
    • View Profile
Re: Portable mode or relative paths
« Reply #6 on: April 03, 2016, 07:52:27 PM »
Are you able to elaborate on the "yes how to command"

rloxley

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: Portable mode or relative paths
« Reply #7 on: March 01, 2019, 02:33:59 AM »
Hello everybody :-)

Working fine with relative paths...

EXCEPT all configs, where the arguments line is pointing to the attract.exe. Can't get that to work with relative paths.

It's scraping all games and artwork well, it's even starting the Emulators and the games, BUT it freezes all emulators immediately...

Seems the emulators just can't handle these paths, as they are obviously set correct for attract mode to work fine.

Example:

Code: [Select]
# Generated by Attract-Mode v2.3.0
#
executable           ..\RocketLauncher\RocketLauncher.exe
args                 -s "[emulator]" -r "[name]" -p AttractMode -f "H:\Vintage Collection\Attract\attract.exe"
rompath              ..\Games\virtualboy
romext               .7z;.zip;.vb;.VB;.ZIP;.7Z
system               Nintendo Virtual Boy
info_source          listxml
exit_hotkey          Joy0 Button8
artwork    boxart          ..\Games\virtualboy\boxart
artwork    cartart         ..\Games\virtualboy\cartart
artwork    flyer           ..\Games\virtualboy\boxart
artwork    marquee         ..\Games\virtualboy\marquee
artwork    snap            ..\Games\virtualboy\snap
artwork    wheel           ..\Games\virtualboy\wheel

ONLY THIS is working. Doesn't matter how much "..\" i am replacing the "H:\Vintage Collection" with in the "args" line... it doesn't work.
Already tried just "attract.exe", failed also...

The folder structure is:

H:\Vintage Collection\Attract\attract.exe
H:\Vintage Collection\Systems\(Emus in seperate folders)
H:\Vintage Collection\Games\(Roms in seperate folders)
H:\Vintage Collection\RocketLauncher\RocketLauncher.exe
Windows 10 x64 Enterprise.

Any idea?

progets

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1274
    • View Profile
Re: Portable mode or relative paths
« Reply #8 on: March 03, 2019, 01:51:57 PM »
Both of these styles work for me.

Code: [Select]
args                 -s "[emulator]" -r "[name]" -p AttractMode -f "\Vintage Collection\Attract\attract.exe"

Code: [Select]
args                 -s "[emulator]" -r "[name]" -p AttractMode -f "..\Attract\attract.exe"

ZheN

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: Portable mode or relative paths
« Reply #9 on: June 24, 2020, 07:14:14 AM »
Hi, just registered to notify the following:

I was trying to get my setup to work with relative paths, but for some strange reason I could not get it to work, until I moved AttractMode into a subfolder.
Snap etc would load fine, but could not get the game to start.

So NOT working:
Filestructure:
  \AttractMode
  \Emulators\RetroArch

And then trying to launch roms with ..\Emulators\RetroArch\retroarch.exe
Code: [Select]
#
executable        ..\Emulators\RetroArch\retroarch.exe
args                 -L cores\nestopia_libretro.dll "[romfilename]"
rompath           ..\Roms\Nintendo NES\Roms
romext             .nes;.unf;.unif;.fds;.zip;.rar;.7z
system             Nintendo Entertainment System (NES)
info_source       thegamesdb.net
artwork    flyer  ..\Roms\Nintendo NES\Assets\Boxart
artwork    snap  ..\Roms\Nintendo NES\Assets\Snap


Working:
Filestructure:
  \Frontend\AttractMode
  \Emulators\RetroArch

And then launch roms with ..\..\Emulators\RetroArch\retroarch.exe
Code: [Select]
#
executable        ..\..\Emulators\RetroArch\retroarch.exe
args                 -L cores\nestopia_libretro.dll "[romfilename]"
rompath           ..\..\Roms\Nintendo NES\Roms
romext             .nes;.unf;.unif;.fds;.zip;.rar;.7z
system             Nintendo Entertainment System (NES)
info_source       thegamesdb.net
artwork    flyer  ..\..\Roms\Nintendo NES\Assets\Boxart
artwork    snap  ..\..\Roms\Nintendo NES\Assets\Snap


I have absolutely no idea why. But maybe it could help others..
« Last Edit: June 24, 2020, 07:15:57 AM by ZheN »

beccobunsen

  • Jr. Member
  • **
  • Posts: 22
    • View Profile
Re: Portable mode or relative paths
« Reply #10 on: June 24, 2020, 11:43:53 AM »
I run attract mode from external drive, with this configuration..

Code: [Select]
executable           ..\RocketLauncher\RocketLauncher.exe
args                 -s "[emulator]" -r "[name]" -p AttractMode -f "..\attract\attract.exe"
rompath              ..\roms\mame2003
romext               .zip;.7z;<DIR>
system               mame
info_source          listxml
import_extras        ..\listextra\2003\catver.ini;..\listextra\\2003\nplayers.ini;..\listextra\2003\mame2003-plus.xml
exit_hotkey          Escape
artwork    flyer           ..\media\mame\flyer
artwork    marquee         ..\media\mame\marquees
artwork    snap            ..\media\mame\videos;..\media\mame\snap
artwork    wheel           ..\media\mame\wheel

with directory tree like this:

[[retrogames]]
       |
       [attractmode]
       |                 
       |
       |
       [media]
       |         |
       |         mame
       |                  |
       |                  flyer
       |                  snap
       |
       [emulators]
       |              mame
       |              retroarch
       |
       [roms]
       |        mame2003
       |        genesis
       |
       [rocketlauncher]


Saludos...
« Last Edit: June 24, 2020, 11:46:30 AM by beccobunsen »

arthurvalenca

  • Sr. Member
  • ****
  • Posts: 125
    • View Profile
Re: Portable mode or relative paths
« Reply #11 on: June 26, 2020, 05:02:57 AM »
Code: [Select]
# Generated by Attract-Mode v2.6.1
#
executable           \AM-2.6.1\emuladores\Mame\Arcade.exe
args                 [name]
rompath              \AM-2.6.1\Games\Arcade
romext               .zip
system               Arcade
info_source          listxml
import_extras        ..\AM-2.6.1\Emuladores\Mame\catver\catver.ini
artwork    3d              ..\AM-2.6.1\media\Arcade\Box 3D
artwork    flyer           ..\AM-2.6.1\media\Arcade\Flyer
artwork    marquee         ..\AM-2.6.1\media\Arcade\Marquee
artwork    play            ..\AM-2.6.1\media\Arcade\Screenshot Play
artwork    select          ..\AM-2.6.1\media\Arcade\Screenshot Select
artwork    snap            ..\AM-2.6.1\media\Arcade\Snaps
artwork    title           ..\AM-2.6.1\media\Arcade\Screenshot Title
artwork    wheel           ..\AM-2.6.1\media\Arcade\Wheels
artwork    loading    ..\AM-2.6.1\media\Arcade\Loading


it works well, the folders are all in the root directory of AM.

prefor

  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: Portable mode or relative paths
« Reply #12 on: July 03, 2020, 11:06:21 AM »
Could someone please help me?

I'm using these Codes

Code: [Select]
# Generated by Attract-Mode v2.6.1
#
executable           ..\emulators\retroarch\retroarch.exe
args                 -L cores\snes9x2010_libretro.dll "[romfilename]"
rompath              \AttractMode\roms\Super Nintendo Entertainment System\
romext               .smc;.zip
system               Super Nintendo (SNES)
info_source          thegamesdb.net
artwork    flyer           ..\AttractMode\roms\Super Nintendo Entertainment System\media\flyer
artwork    marquee         ..\AttractMode\roms\Super Nintendo Entertainment System\media\marquee
artwork    snap            ..\AttractMode\roms\Super Nintendo Entertainment System\media\snap
artwork    wheel           ..\AttractMode\roms\Super Nintendo Entertainment System\media\wheel

All the artworks work well when i write "..\AttractMode\roms...." But not when i write "..\roms" for some reason.

But i can't get Retroarch to work :(
I've tried

Code: [Select]
executable           ..\emulators\retroarch\retroarch.exe
args                 -L cores\snes9x2010_libretro.dll "[romfilename]"
rompath              \AttractMode\roms\Super Nintendo Entertainment System\

Code: [Select]
executable           ..\AttractMode\emulators\retroarch\retroarch.exe
Code: [Select]
executable           ..\..\AttractMode\emulators\retroarch\retroarch.exe
Code: [Select]
executable           ..\..\emulators\retroarch\retroarch.exe
Nothing seems to work :(

The program can find my roms but for some reason i can't launch any game, Retroarch just crashes (it blinks for like 1 seconds) and brings me back to AttractMode. Please anyone :(
« Last Edit: July 03, 2020, 11:09:35 AM by prefor »