How should i go about making a simple card game? (e.g. solitaire) I am familiar w/ terminal programs in java and c/c++, but i am not familiar w/ the graphical side. Is openGL too complex for a simple card game? I guess ultimately I'm asking where do I start? What language & functions do I need?
JavaFX 2 or Qt are really easy to start with, just look at the tutorials.
Netbeans comes prepackaged with a GUI Builder. If you like drag and drop and can write your own java listeners behind it, this is not a bad option.
http://netbeans.org/features/java/swing.html
Related
I would like to ask you for an advice, what would be the best approach to create a RTS game in Java nowadays. I have some experience with JavaFX applications, but I guess it is not exactly inteded for such things and it is much better to use in "office" applications and there are not so many examples of games created using JavaFX. Or am I wrong and it can be used for that purpose?
I know there are such engines like Unity or Unreal, but I would like to make something like this in Java. Should I go for LWJGL or something like this in this case? I think that 2d engine should be enough for what I would like to do.
What would you recommend for that? Thanks for your suggestions. I know there are some topics like this, but I would like to know what is currently on top.
maybe this is what you are looking for: https://github.com/AlmasB/FXGL
You mentioned Unity and Unreal and this is certainly not comparabel with that. But in your headline you ask for a 2D engine and I think it fits in this category.
There's the java based (not specifically JavaFX) libgdx (https://libgdx.badlogicgames.com/), which could be adapted to JavaFx.
So as you can probably tell from my question I am very new at all of this. I am creating a small "particle simulator" (really just gravity thing). I am modeling both X and Y positions. My question is how do I incorporate graphics. I don't really care about re-working my existing code (in java application format). In my prevois research I came along Jquery and Css but I am not sure on how to implement either or them. Also in researcher I found java graphics but I am not sure on what or if library's are involved in making that would I only found commands. I have used them before but that was in a fake environment(codeacdemy). I have created a small GUI in netbeans using a Jframe. That leads into a somewhat second question of what would I use in a GUI to have something graphically involved.
here's a tutorial on how to use graphics in java:
http://docs.oracle.com/javase/tutorial/uiswing/painting/index.html
Well, I had this question in mind for a long time.
Even though I have a complex requirement,i will keep it as simple as possible.
I have background process which takes two arguments which I use to execute from command line.
The first argumets can have three valid values and the secong argument can have two valid values.
I usually run that process on command line in solaris unix.and that process is completely coded in C++.
What I want now is I wish to create a simple gui in java for running the process in background.
I am complete new to the advanced concepts of java, and I am aware of some core java which I studied in my college days.
So,My question overe here how do I start creating a gui?
What all do I need to create a simple gui using java?
I am confident enough to learn gui programming in java as I am a c++ programmer.
Please give me some right directions to give some life to my thought and any some good materials available on the net would be helpful.
I would start by looking at;
Creating a GUI with Swing
Concurrency in Swing
Concurrency in Java
I'd also become familiar with ProcessBuilder (a simple example) and Basic IO
MarvinLabs also makes some great points as well
The Google search you'll want to use is "java swing tutorial". Swing is Java's GUI library.
You can also have a look at: Java GUI frameworks. What to choose? Swing, SWT, AWT, SwingX, JGoodies, JavaFX, Apache Pivot?
You really just need a JFrame and a JPanel. The JFrame is the physical window that the gui lives in, while the JPanel is the content manager. You place JComponents (e.g. JLabel, JComboBox) into the JPanel.
Java Api: http://docs.oracle.com/javase/7/docs/api/
Examples of using each component: http://docs.oracle.com/javase/tutorial/uiswing/components/index.html
IMO, you may try using JavaFX 2.1 to develop your GUI in java. It has Scene builder tool to design your application, built-in support css-like skin.
Check the concurrency in Javafx 2.1 here.
I'm developing a desktop application using java + SWT/JFace, which I'm not very familiar. The program need to show some pictures presenting the program's progress like this.
Sorry for my poor English, I'm not sure whether it's suitable to use the word "moving", actually I mean that the diagram is changing like Flash when an event occurs. I'm considering making some flash movies to play, but it seems difficult as I need to add third-party jars and I'm not good at flash. Is there any better way to doing work like this? I need your suggestion.
Thank you and sorry for my poor English again if I made some English mistakes that troubled you :)
You can use java2d and the awt-swt bridge or there is a framework called Timing Framework which works for swt and swing.
probably you need a gif embeded in your window. java cannot paly any animations unless you have series pictures and play them one by one very soon.
My game would be a simple 2D tower defense type game. It should have some animations and sounds. I've only learned Java so this seems like a huge plus for choosing that option. But I'm fairly new to programming so i suppose it wont be a huge problem to switch.
From my limited research, either Python using pygame or Java using lwjgl seems to be best suited for my kind of game.
What are your thoughts? Benefits of one over the other? Other suggestions?
Java + LWJGL is very low level and you'll have to write a lot of the sound and animation code yourself. A better choice would be Java + Slick2D (a 2d library on top of LWJGL). You can find it at http://slick.cokeandcode.com
A benefit from Pygame for the kind of game you want to do is the Python Pygame Tower Defense project that could be a pretty good tutorial for what you want to do, isn't it ?