Bottom Page

Thread Rating:
  • 5 Vote(s) - 2.6 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 t_games, Take Two
#11
(Jan-13-2019, 09:18 PM)ichabod801 Wrote: How are you running it, and what version are you using?

Python 3.6.4. I'm just running it on the shell of IDLE. I downloaded the file you said, t_games-0.36.0a4.zip, extracted it and tried running it. What version python are you working with?
You like this post
Quote
#12
(Jan-15-2019, 02:03 AM)Trinx Wrote: Python 3.6.4. I'm just running it on the shell of IDLE. I downloaded the file you said, t_games-0.36.0a4.zip, extracted it and tried running it. What version python are you working with?

Sorry, I didn't see your post in the unreads. It works for me in 3.6 and 2.7. I'm using Anaconda for Python, and if I start IDLE from the folder containing the t_games folder, you can import t_games, call t_games.play() and it works. Otherwise it doesn't work, at least not if the t_games folder isn't in the pythonpath.

I would not recommend using IDLE. I would navigate to the t_games folder in the command line, and try [icode]python play.py[/code].
metulburr likes this post
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures

Quote
#13
(Jan-16-2019, 03:46 AM)ichabod801 Wrote: Sorry, I didn't see your post in the unreads. It works for me in 3.6 and 2.7. I'm using Anaconda for Python, and if I start IDLE from the folder containing the t_games folder, you can import t_games, call t_games.play() and it works. Otherwise it doesn't work, at least not if the t_games folder isn't in the pythonpath. I would not recommend using IDLE. I would navigate to the t_games folder in the command line, and try [icode]python play.py[/code].

Oye, the inbox on this gets confusing sometimes. I had never heard of Anaconda before. I looked it up and saw it was 614mbs, so I haven't downloaded it yet. Why don't you recommend using IDLE? I haven't done much on the cmd of python so I'm not sure how to navigate to files. I tried this but it kept giving me errors:

import os

os.chdir(C:\"""path to desktop""")
It said : was invaild...

???
Quote
#14
What I am suggesting is open the system command line, navigate to the t_games folder in the system command line, and try python play.py.

Without the full error traceback, I can't diagnose the problem you are having with os.chdir. It is working for me, however:

Output:
>>> import t_games Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: No module named t_games >>> import os >>> os.chdir('Documents') >>> import t_games >>> dir(t_games) ['Interface', '__builtins__', '__doc__', '__file__', '__name__', '__package__', '__path__', 'board', 'cards', 'dice', 'full_credits', 'game', 'interface', 'options', 'other_cmd', 'play', 'player', 'test', 'utility']
You can also use the sys module to modify the pythonpath:

Output:
>>> import t_games Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: No module named t_games >>> import sys >>> sys.path.insert(0, 'C:\\Users\\Craig\\Documents') >>> import t_games >>> dir(t_games) ['Interface', '__builtins__', '__doc__', '__file__', '__name__', '__package__', '__path__', 'board', 'cards', 'dice', 'full_credits', 'game', 'interface', 'options', 'other_cmd', 'play', 'player', 'test', 'utility']
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures

Quote
#15
(Jan-16-2019, 05:40 PM)Trinx Wrote: I had never heard of Anaconda before. I looked it up and saw it was 614mbs, so I haven't downloaded it yet. Why don't you recommend using IDLE?

I wasn't saying you should download Anaconda, I was just clarifying my set up, as that could affect how things work.

I would not recommend IDLE because it is one of the lowest quality environments for Python out there. There are plenty of free options out there that are much better. And t_games wasn't even designed for a Python environment. It was designed to be run on the system command line.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures

Quote
#16
(Jan-16-2019, 05:40 PM)Trinx Wrote: Why don't you recommend using IDLE?
Under IDE -> IDLE explains a little about its low quality aspects here.
Trinx likes this post
Quote
#17
All that and it works Confused Thanks for helping me through that, I'll try them out tonight (hopefully). I don't know when I will be able to get on again after today. I'll look into other python environments. Thanks!
Quote

Top Page

Possibly Related Threads...
Thread Author Replies Views Last Post
Star New t_games Release ichabod801 0 175 Mar-19-2019, 08:27 PM
Last Post: ichabod801

Forum Jump:


Users browsing this thread: 1 Guest(s)