Games in Python, - Better to use a Java JFrame for the game Window?

I am nearly ready to begin my foray into games in Python. However, is it more advisable to incorporate a JFrame for the game Window? Is Python GUI up to speed?

beavoidSelf EmployedAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

dbruntonQuid, Me Anxius Sum?  Illegitimi non carborundum.Commented:
What types of games are you proposing?
if you're writing your game in Python, you should use a Python GUI.  It would be a major nightmare to try to use a JFrame (or any other part of a Java library like Swing) in Python.

I've heard people say good things about Cocos2D ( which is all in Python and should be fine for any 2D game you might build.

Hope that helps,


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Is Python GUI up to speed? Depends will you be using open GL?
For money?
VR is the future
Graphic User Interface FAQ is worth a read,
There is so many changes coming with game platforms versus computer systems. Microsoft pushing for mobile platforms windows as a Service, Steam has fully integrated to Cloud.
If you have time have a look at this, the games created using Amazon Lumberyard is amazing to say the least.
Free. Powerful. Fully Customizable.
We believe game developers deserve another choice. That’s why we’re building Lumberyard: a game engine with no royalties or seat fees, frictionless integration with Twitch and AWS, plus much more on the horizon.
Example of a game built with it
Star Citizen CitizenCon 2017 KeyNote Highlights
Star Citizen about on Wiki
Cloud Imperium Games
Publisher(s)      Cloud Imperium Games
Director(s)      Chris Roberts
Writer(s)      Dave Haddock[1]
Composer(s)      Pedro Camacho
Geoff Zanelli[2]
Engine      Amazon Lumberyard
Platform(s)      Microsoft Windows
Star Citizen: TBA
Squadron 42: TBA
Genre(s)      Space trading and combat, first-person shooter
Mode(s)      Single-player, multiplayer
HTML5 and CSS3 Fundamentals

Build a website from the ground up by first learning the fundamentals of HTML5 and CSS3, the two popular programming languages used to present content online. HTML deals with fonts, colors, graphics, and hyperlinks, while CSS describes how HTML elements are to be displayed.

beavoidSelf EmployedAuthor Commented:

This won't be for money. I'd like to know as much about Python Frames as I do AWT and swing.

I'd like to know where opinion stands on incorporating Java into a Python project? Is it considered a cheap fallback? It sounds like it isn't that simple. Why? Can you not pass in data to methods and get returned values?

Must it all be ported to pure Python, - also, if I'd ever like to offer it as open-source, these days? (Is Java history?)

I don't need Starcraft 2 graphics yet. It sounds like Python Frames could be adequate for anything I used to be able to do? Should I not be concerned about their ability to be as good as JFrames?
>> I'd like to know where opinion stands on incorporating Java into a Python project?

Pretty close to impossible.  A Java program is a set of bytecode (instructions) which you can't actually execute.  Instead you run Java (actually a Java virtual machine) and that reads the bytecode and executes the program.  So you must be running a Java virtual machine in order to execute Java code.  E.g. To run a java program you say:
"java -jar mycode.jar" <== see how you run "java" not "mycode.jar"

Python does not include this virtual machine - so there's nothing to "run" the Java code.

There was an effort to build a version of Python that could run inside Java ( but that's not really Python.  And I think it died a while ago.

If you had a C (or C++) program already and wanted to call part of that from Python, that would be possible.  Because a compiled C program  is directly executable.  It doesn't need something else to run it.

>> Must it all be ported to pure Python,
Yes (see above)

>>  also, if I'd ever like to offer it as open-source, these days?
You can make your Python or Java or anything else open source if you like.

>> (Is Java history?)
No it's going strong, but it's almost exclusively used for server code these days - i.e. stuff with no GUIs at all.

Good luck,

beavoidSelf EmployedAuthor Commented:

One thing also,
My Pycharm, interpreter is Pycharm CE 2016. 3.3.3

The woman in one Pygame install has 3.6.2
I've wondered if this is possibly my entire problem, upgrade incompatibilities?
Also, must I do anything specific to let the install know where my pygame must be installed, or does it always look in applications/pycharm
Those are all totally different questions from the original - I'd start a new topic if you're having problems with your python install and get some other experts to weigh in to help.

beavoidSelf EmployedAuthor Commented:
I'll do the Python install question, but do you suspect that the different versions, interpreters, are a plausible reason for my problems?
Certainly could be.  Python is one of those languages which suffers from slightly different libraries and installations resulting in very different behaviors.  Package management is a problem in many languages.
beavoidSelf EmployedAuthor Commented:
Thanks All
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Game Programming

From novice to tech pro — start learning today.