Help running from arch linux

Avatar

By christian 28 Dec 2017 23:43

New member · 6 comments

I've tried following the directions from the following link:

https://www.tuxemon.org/arch-install.html

but I'm getting the following errors on running "python2 tuxemon.py":

/home/christian/tuxemon/tuxemon/core/platform/__init__.py:22: SyntaxWarning: name '_pygame' is assigned to before global declaration
  global _pygame
Traceback (most recent call last):
  File "tuxemon.py", line 59, in <module>
    from core.main import main
  File "/home/christian/tuxemon/tuxemon/core/main.py", line 33, in <module>
    from . import prepare
  File "/home/christian/tuxemon/tuxemon/core/prepare.py", line 66, in <module>
    CONFIG = config.Config(CONFIG_FILE_PATH)
  File "/home/christian/tuxemon/tuxemon/core/components/config.py", line 66, in __init__
    self.starting_position = [int(self.config.get("game", "starting_position_x")),
  File "/usr/lib/python2.7/ConfigParser.py", line 618, in get
    raise NoOptionError(option, section)
ConfigParser.NoOptionError: No option 'starting_position_x' in section: 'game'

Thanks in advance, this project looks exciting!

Avatar

By christian 30 Dec 2017 08:46

New member · 6 comments

Also, installing from the AUR and running "tuxemon" gives

/usr/bin/python: Error while finding module specification for 'core.prepare' (ModuleNotFoundError: No module named 'core')
/usr/bin/tuxemon: line 36: Starts the core.main.main() function which, in turn, initializes
pygame and starts the game, unless headless is specified.

To run an individual component (e.g. core/prepare.py):

: No such file or directory
/usr/bin/tuxemon: line 37: from: command not found
/usr/bin/tuxemon: line 38: from: command not found
/usr/bin/tuxemon: line 39: import: command not found
/usr/bin/tuxemon: line 40: import: command not found
/usr/bin/tuxemon: line 44: syntax error near unexpected token `('
/usr/bin/tuxemon: line 44: `    opts, args = getopt.getopt(sys.argv[1:], "hs", ["help", "server"])'

Avatar

By Qiangong2 6 Jan 2018 04:13

Member · 20 comments

You'd be better off downloading directly from the development branch on github. the unstable-latest build it links to is (ironically) not the latest. If you want to get the latest, download from github instead.

Avatar

By christian 6 Jan 2018 06:10

New member · 6 comments

Sorry for the dumb question, but how do I build and run?

Avatar

By bitcraft 7 Jan 2018 06:01

Champion · 146 comments

https://github.com/Tuxemon/Tuxemon/arch … opment.zip

Download this zip file, then the following should work for you.  Tuxemon is a python project, and there is nothing to build.  If the AUR package has already installed python and pygame, then the following will install everything else.

cd Tuxemon
sudo pip install -U -r requirements.txt
python tuxemon/tuxemon.py
Avatar

By christian 7 Jan 2018 11:10

New member · 6 comments

Okay, here's my error at the moment:

[christian@christianity Tuxemon-development]$ python tuxemon/tuxemon.py
Traceback (most recent call last):
  File "tuxemon/tuxemon.py", line 60, in <module>
    from core.main import main
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/main.py", line 33, in <module>
    from . import prepare
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/prepare.py", line 78, in <module>
    CONFIG = config.Config(DEFAULT_FILE_PATH, CONFIG_FILE_PATH)
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/components/config.py", line 75, in __init__
    self.sound_volume = float(config_get("sound", "sound_volume"))
ValueError: could not convert string to float: '255 ; Not used'

Avatar

By bitcraft 8 Jan 2018 16:35

Champion · 146 comments

You can edit your ~/.tuxemon/tuxemon.cfg file and change the volumes to this:

[sound]
sound_volume=1
music_volume=1

Or:
1. erase the ~/.tuxemon/tuxemon.cfg file
2. download a new development zip file
3. try again

This is caused by a bug in the default config.  If you are interested in keeping tuxemon current and following along with the development, you can use git to keep your local version up-to-date (instead of using the zip files).

Avatar

By christian 9 Jan 2018 01:59

New member · 6 comments

I'm sorry to keep bothering you guys.

[christian@christianity Tuxemon-development]$ python tuxemon/tuxemon.py
Traceback (most recent call last):
  File "tuxemon/tuxemon.py", line 60, in <module>
    from core.main import main
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/main.py", line 35, in <module>
    from .components.player import Player
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/components/player.py", line 34, in <module>
    from core.components.npc import Npc
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/components/npc.py", line 37, in <module>
    from core.components.entity import Entity
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/components/entity.py", line 27, in <module>
    from core.components.map import proj
  File "/home/christian/tuxemon/Tuxemon-development/tuxemon/core/components/map.py", line 37, in <module>
    import pyscroll
  File "/usr/lib/python3.6/site-packages/pyscroll/__init__.py", line 38, in <module>
    from .data import *
  File "/usr/lib/python3.6/site-packages/pyscroll/data.py", line 11, in <module>
    import pytmx
  File "/usr/lib/python3.6/site-packages/pytmx/__init__.py", line 24, in <module>
    from .pytmx import *
AttributeError: module 'pytmx.pytmx' has no attribute 'TiledTerrain'

Avatar

By bitcraft 9 Jan 2018 22:47

Champion · 146 comments

Shoot, that is my fault.  I just made a fix with pytmx for that.  Update the dependencies and try again.

sudo pip install -U -r requirements.txt
python tuxemon/tuxemon.py
Avatar

By christian 9 Jan 2018 23:13

New member · 6 comments

It works!!

Thank you.