Ahh, I think I see what you are saying. If it wasn't set up this way, it's actually possible that the separate thread could set isPaused to false AND execute notify() before the animator thread...
Type: Posts; User: bbr201
Ahh, I think I see what you are saying. If it wasn't set up this way, it's actually possible that the separate thread could set isPaused to false AND execute notify() before the animator thread...
I think my problem is that I understand synchronization, but I'm not understanding how it works here.
1. pauseGame() is called and isPaused is set to true.
2. the animator thread will check...
I have a basic understanding of a mutex, but not a lot of hands on experience with threads in general. Basically, my understanding is that all code in synchronized blocks is known as the monitor, and...
Oops, apparently the answer is yes, it does release the lock. But what is the point of synchronizing anything? According to the author, a boolean cannot be read by one thread and changed by another...
hi all,
i haven't worked with threads much, and i have a question about how synchronzied would work in this situation. here is a stripped down example of a game class:
public class GamePanel...
hi stoptheerrors,
A quick glance at your code reveals many problems. A few things catch my eye right away. First, I've never seen a main with a parameter other than args. The command line...
Ack, I think this is a bit of a problem for me. I would hate to dedicate so much effort into JOGL for a browser game. I would also hate to dedicate so much effort into Java3D if it is no longer...
It's called Pro Java 6 3D Game Development. Might want to look into why there are 1 star reviews, though.
Here you go: Amazon.com: Pro Java 6 3D Game Development: Java 3D, JOGL, JInput and JOAL...
The author has a new book which came out in 2007; I think it's more focused on 3D. For some reason, it only has a 3 star review on amazon. Anyway, check this out:
Differences from KGPJ
Oh yeah, I'm going to start with 2D stuff first. It's just that the book says it uses Java 3D for 15 chapters or so, which I imagine is most of it. I was really planning on creating a game people...
Thanks, I bought "Killer Game Programming in Java". Just a quick question: Does the user require anything more than a standard JRE if I make use of Java3D? If so, this seems like a bit of a hassle.
tax, cost, and payment are instance variables. This means that every Change object created will have its own copy of these variables. If you include the static keyword in the declaration, these...
Thanks for the reply. I know that "gaming" and "Java" are usually not described as the best combination, but I think that is mostly in regards to resource heavy games and not browser games. For...
Are java applets still a frequent choice for browser games? Or would you say that something like flash has mostly taken over this aspect?
I ask because I am considering looking into creating a 2D...
What more needs to be said? You should probably provide more information about what type of information you are looking for.
If you are just looking to fill space for a homework assignment or...
Not sure, I've never heard of it. I guess my only questions would be: is this only managed through windows explorer or could it be configured to work with eclipse? and also, I guess I wouldn't be...
Well, if the class is abstract, then you can't instantiate it. So, is it possible this abstract class is extended somewhere where the authorizeGet() method is implemented?
hi all,
I've never used CVS before and I'm just trying to experiment with the features in Eclipse. Is it most common for a CVS server to be running on linux? I've read that CVSNT is a free CVS...
Ahh, I see. Is it common to see entire GUI applications written "by hand" and without the use of a Visual Editor? According to Sun's java tutorial this can be a very "challenging" experience and I...
And you added the breaks for the second switch statement also?
switch(j){
case 1: card = card.concat("of Hearts"); break;
case 2: card = card.concat("of Diamonds"); break;
...
If so,...
hi all,
Can anyone advise on which IDE/Visual Editor is used most commonly in professional settings for GUI application development?
It seems as though Eclipse is by far the most popular IDE...
If you use switch/case you should add a break after every case, otherwise it will fall through to the other cases.
switch(i){
case 1: card = card.concat("Two "); break;
case 2: card =...
I didn't look at the code in detail at all, but I see this:
//THIS IS THE ERROR I AM GETTING "Cannot instantiate the type BankAccount"
BankAccount acc = new BankAccount(name, amount);
......
Ahh, sweet. I didn't know about that CardLayout. It looks like that is exactly what it is designed for. Thanks.
hi all,
About to start working with swing for the first time and have a question. What is the best way to change between different views and/or modes in a program?
For example, let's say I...