Coverage for lutris.runners.nulldc : 53%

Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
# -*- coding:Utf-8 -*- ############################################################################### ## Lutris ## ## Copyright (C) 2009, 2010 Mathieu Comandon strycore@gmail.com ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 3 of the License, or ## (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA ###############################################################################
# pylint: disable=C0103 """Runner for the Dreamcast emulator NullDC
Since there is no good Linux emulator out there, we have to use a Windows emulator. It runs pretty well.
NullDC is now OpenSource ! Somebody please port it to Linux. The open source NullDC version (1.0.4) doesn't work with wine !
Download link : http://nulldc.googlecode.com/files/nullDC_104_r50.7z
"""
"""Initialize NullDC
joy2key $(xwininfo -root -tree | grep nullDC | grep -v VMU |\ awk '{print $1}') \ -X -rcfile ~/.joy2keyrc \ -buttons y a b x c r l r o s -axis Left Right Up Down """
'option': 'iso', 'type': 'file', 'name': 'iso', 'label': 'Disc image' }] 'option': 'fullscreen', 'type': 'bool', 'name': 'fullscreen', 'label': 'Fullscreen' }] self.settings = settings
"""Install NullDC""" dlg = DirectoryDialog('Where is NullDC located ?') config = LutrisConfig(runner=self.__class__.__name__) config.runner_config = {'system': {'game_path': dlg.folder}} config.save(config_type='runner')
"""Check if NullDC is installed""" if not self.check_depends(): return False nulldc_path = self.get_nulldc_path() if not nulldc_path or not os.path.exists(nulldc_path): return False else: return True
""" Return the full path for the NullDC executable.""" if not self.nulldc_path: return "" else: return os.path.join(self.nulldc_path, self.executable)
"""Run Dreamcast game""" #-config ImageReader:DefaultImage="[rompath]/[romfile]" path = self.settings['game']['iso'] path = path.replace("/", "\\") path = 'Z:' + path
command = ["wine", self.get_nulldc_path(), "-config", "ImageReader:DefaultImage=\"%s\"" % path]
self.check_regedit_keys() # From parent wine runner return {'command': command, 'joy2key': {'buttons': 'y a b x c r l r o s', 'window': 'nullDC', 'notwindow': 'VMU'}} |