• Advertisement
Sign in to follow this  

Which programming language to use?

This topic is 4146 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am a senior in high school and decided to make a computer game for my senior project. I will exhibit and have middle school students play the game. The main problem is my home computers are PCs and the schools only have macs. I was thinking of using Java. What language should I use for it to be compatible on both with minimal coding change, and will Java be compatable on both?

Share this post


Link to post
Share on other sites
Advertisement
I write my games in Java (using LWJGL), and they all work on PC and Mac - and I've never even tested them myself on a Mac. [grin] (They probably work on Linux too, but I don't tend to get many Linux testers).

Another alternative would be to use one of the Blitz languages - IIRC they're compatible with windows and mac, but you'll need to recompile it for each platform.

Share this post


Link to post
Share on other sites
Java will almost certainly work on both.

If you can recompile, then C/C++ and SDL should work, as long as the Macs use OS X. However, if you already know Java, then that's the way to go.

Share this post


Link to post
Share on other sites
As said, Java will work fine. C++ will work if you can compile. C# will work if you have the tmie to use Mono/Tao (which I use as well).

But also:

ruby and Python (Pygame) will work cross platform too. And I know mac ships with a version of ruby already installed (of course the game wrapper libraries would need to be added as dependencies). It probably has Python by default too.

Share this post


Link to post
Share on other sites
i write in java, saves a lot of time with premade classes (even if they can be... cryptic) and like everyone's been saying, works on mac/linux/windows.

It isn't as fast or natural-feeling as C/C++, but it gets the job done and if done right doesn't look like PASCAL.

*shiver*

Share this post


Link to post
Share on other sites
Yeah, I would say go with Java. Since this is just a school project and you need it to be very cross platform. Pretty much anyother language would work as well but you would need to recompile probably. With java you can just compile it at home and run it at school.

If you did not have that requirement I would say go with c++/lua or python (although python can do like java if you have the python intrepeter installed, java is faster though).

Share this post


Link to post
Share on other sites
Quote:
... but it gets the job done and if done right doesn't look like PASCAL.
This elicited a hearty chuckle from myself. Well done, good sir.

Share this post


Link to post
Share on other sites
C/C++ is good because almost everything is written in it.

Java is good because its really portable.

C# is good if youve got Mono.

theres other languages out there as well. If its just for a game, and its not going to require any 3D graphics, BYOND is a good choice because it has all the tools you need in one package, and it can port to Mac and Linux, without any modification to the source.

Share this post


Link to post
Share on other sites
Java's a great choice for portability when paired with something like lwjgl or even the new implementation of Java3D.

Personally, I use C++ with a mix of SDL and OpenGL and a lot of cross-platform experience gained from bumps and scrapes.

Share this post


Link to post
Share on other sites
Thanks for the advice. I will probably use Java based on what you have said, especially since the school network, access privileges, and installing new things onto the network would probably be difficult and involve meeting with the network administrators repeatedly. A major part of the project is learning, so I'm up to studying new languages. Java will also be good since I am learning about the basics to Java for my AP computer science class, so I could learn about Java for 2 reasons at once.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement