GUI organizational help please.

Post and discuss creative ideas

GUI organizational help please.

Postby BlueLight » Tue Jul 19, 2011 12:48 pm

Hello as you can see im BlueLight.
Anyways you’re not here for my name and hello’s so let’s get to the problem. Im trying to program a game and right now my only drawback really is knows some simple stuff in java. Mostly how classes interact with each other and how methods in different classes interact with each other. Anyways I find that I can normally add something with in the GUI quite easily compared to most of this stuff which I have a loused grasp on.

If you don’t have enough information to go on ask about it and I will tell you what I got. I’m trying to plan the game out before any real coding gets done and that’s how you should be doing it. However I still haven’t made up my mind on anything.

So noticing that I seem to be able to handle GUI and that I really didn’t have a concrete plan for my GUI. So I came here to request the forums help in planning.
This is a simple picture of what I’m thinking of for the GUI so far and yes it looks like crap that’s because I used Paint… Yes paint.

Untitled.gif
Untitled.gif (4.1 KiB) Viewed 2447 times


Okay so basically a panel is box that holds GUI objects in and displays them. I can set up 5 of them North, West, South, East, and Center. The null space is not a panel it’s just space between center and north panel. Now here is the plan for the GUI so far.

Panel North or 1 will contain character status variables. I also saw some bar’s objects in one of the GUI based library’s so I might give one of them a try. I can think of 2 variables I would really want to a bar for but I can think of 4 that I might try it with. HP, Lust (Variable name change at any time), Magic, Stress. It will also hold information like time of day or even enemy stats possibly.

Panel West or 2 will contain your skills and will basically just show you the values to variables for skill related stuff. I am thinking that I might change it so Panel West is in face a panel east.

We’ll skip 3 and goto Panel South or 4. This is where my buttons will be held and I believe I will have to something in the API called carddraw. I just remember reading something about it on a forum for programming about week back. This is basically the panel that will hold everything the player need to interact with it.

Now back to panel Center or 3. This panel is basically how the world interacts with the player. Now you’ll noticed above it is Tab 1,2,3,4 and nullspace. Basically what im thinking so I don’t need to place buttons in place they don’t really fit I will just add tabs and that’s how you will change screen, more on that later. Anyways first screen will be a text field that is lock from the play editing. This will adds descriptions of what the player see and tells them what’s going on in the world. The second tab would be the world map and that would be a picture. Now I believe I could find a something in the API that would let me at buttons on top of a picture but I don’t have proof of it. That being said do you think I should add buttons to the picture or panel South /4? Tab 3 I think will add player damage read out. I am right now working on a system where body parts have stats and when they get damage it affects that part stats and you’re over all HP. It’s basically what im stuck on since I can’t get the test class to work (damn evil variables). Tab 4 would be appearance.

Now I would love suggestions on what I should add. One thing I haven’t put much thought into in options button or anything you might mind in one like save or load. If you think something cool tell me and I’ll tell you if I think it’s possible. I don’t want to deal with animation since it’s takes to long and im ending it there. Panel visually won’t have any difference default and you won’t be able to tell where one starts or ends for sure.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby Nookie » Tue Jul 19, 2011 2:06 pm

GUI idea.png
GUI idea.png (14.91 KiB) Viewed 2441 times


My suggestion; I added some things as well.
User avatar
Nookie
 
Joined: Tue Jun 14, 2011 4:44 pm

Re: GUI organizational help please.

Postby BlueLight » Tue Jul 19, 2011 2:29 pm

Well i'm not sure if i like it. However i just learn the theory of making .jar files so i'll try to make a prototype of my design and yours so we can see how it will look.

Just give me time to sleep, research setting panel sizes, and forget about this.

(and add panels that are in my prototype GUI in comments only /*in other words they are comments out and are untested*/, plus new GUI elements i have no clue how to add.)

Just a reminder to people, You can completely redesign the GUI since this is completely planning stage. I just need to know where variable are being displayed
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby BlueLight » Tue Jul 19, 2011 2:48 pm

Nookie Wrote:
GUI idea.png


My suggestion; I added some things as well.


Okay so you got the bars, tabs ,options up top or north panel. Im guessing if i was to hit option it would pop up with something in the middle of the screen.
Okay how would hitting the buttons to the low left work? they would they interact with the middle panel or make some pop up?

The invintory it self i didn't even think about but i need to learn about making girds so im going to be doing that I think.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby Nookie » Tue Jul 19, 2011 4:06 pm

BlueLight Wrote:
Okay so you got the bars, tabs ,options up top or north panel. Im guessing if i was to hit option it would pop up with something in the middle of the screen.
Okay how would hitting the buttons to the low left work? they would they interact with the middle panel or make some pop up?

Yes


BlueLight Wrote:The invintory it self i didn't even think about but i need to learn about making girds so im going to be doing that I think.

I assume that your game has RPG elements so an inventory would be nice to put in.
User avatar
Nookie
 
Joined: Tue Jun 14, 2011 4:44 pm

Re: GUI organizational help please.

Postby BlueLight » Tue Jul 19, 2011 5:23 pm

Ya i need a formula for levels. Anyways i think I understand what i need to with the test class so im going to do that then try to program my GUI bare bones design without tabs.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby IronEagle » Wed Jul 20, 2011 8:04 am

I believe there are a few things you need to consider first:-
1. the gaming algorithms like damage taken and damaged received. it shouldn't just be something gives a set amount of damage.
2. the gui is actually the wrong order. it should go
1.Story, 2. base code (algorithms and the like), 3. gui.
3. Are you sure you want to use Java? It isn't exactly known to be speedy and if speed doesn't matter, python might be a better choice as it is, from what I have heard, easier to understand and learn then Java.

In general, I think you should think through what exactly you want this to be, and choose the proper tools for the job.

On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language
IronEagle
 
Joined: Sun Jun 26, 2011 12:29 am

Re: GUI organizational help please.

Postby Nookie » Thu Jul 21, 2011 7:55 am

IronEagle Wrote:On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language


...and the reasons are?
User avatar
Nookie
 
Joined: Tue Jun 14, 2011 4:44 pm

Re: GUI organizational help please.

Postby BlueLight » Thu Jul 21, 2011 8:38 am

IronEagle Wrote:I believe there are a few things you need to consider first:-
1. the gaming algorithms like damage taken and damaged received. it shouldn't just be something gives a set amount of damage.
2. the gui is actually the wrong order. it should go
1.Story, 2. base code (algorithms and the like), 3. gui.
3. Are you sure you want to use Java? It isn't exactly known to be speedy and if speed doesn't matter, python might be a better choice as it is, from what I have heard, easier to understand and learn then Java.

In general, I think you should think through what exactly you want this to be, and choose the proper tools for the job.

On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language

1 Ya i'm working on it. I'm going to go with more of a Japanese RPG more relying on levels then grinding.
2 Sorry if this sounds rude but i don't care about convention that will save me a pain in the butt later at this time. Let me learn the hard way so i don't have to try it later in life.
3 Ya i want jave. It's text based i don't think i need speed. I've already got my foot firmly in the door with java and the fact that you say "heard" doesn't make me want to change my mind in the least.

Whats wrong with the tools i got? The only thing you've stated is that java is slow and python is better and easier. How ever what you didn't take in to account is that learn 2 languages is likely going to be hard on me and if i drop java then i lose the support of my family to help me. I don't want to relearn something i know somewhat how to do, I want to program and if i need help be able to ask for it.

Okay you've given me dreams and fairtails about faster and better stuff. The fact is that i'm using java because i understand it, if i was learn from scratch i would've forgone java and gone with action script 3. Next I do find your post insulting since it sounds like your using hearsay as fact and you don't even try to back it up.

By the way you state things you don't program but you deal with programmers alot. Most likely a work thing. Now you might be a manager and if thats true and your like most managers that started out as programmer then you likely stopped, your rusty, and not update on whats the standards. So sorry if i don't take what you have to say to heart but i'm not here to make a living. I'm doing this because it's fun and you forces me to think.


Nookie Wrote:
IronEagle Wrote:On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language


...and the reasons are?

It seems like it's slow. Not that it stops corporations from using it.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby idFADE » Thu Jul 21, 2011 4:43 pm

IronEagle Wrote:3. Are you sure you want to use Java? It isn't exactly known to be speedy and if speed doesn't matter, python might be a better choice as it is, from what I have heard, easier to understand and learn then Java.
On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language


1. Your information is antiquated. Recent Java releases is only a little bit slower than C++, speed doesn't necessarily have to do with the language as well, a poorly optimized C++ application can be way slower than a highly optimized Java or python application. Python is a good language though, and many argue that it is easy to learn, with easy synthax and powerful functions. However, it all depends on what type of programmer you are. Personally I prefer curly braces over tabs to designate my function blocks. I talked with some Python programmers and even they complain about the tabs.

2. If 8 out of 10 programmers you met shudder and puke when they think of Java you must have met them C programmers XD Java isn't the worst language, I would argue that Visual basic is. However, Java isn't fit for all the environments one might want to deploy it in. The JRE for example, it makes it harder for the programmer to get down on hardware level which is sometimes needed when designing applications. But worst language is an exaggeration, minecraft is coded in Java, and it have been very successful.

Oh, and im new here.

idFade
Code: Select All Code
int[] msg = {72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100};
idFADE
Newly Registered
 
Joined: Tue Jun 14, 2011 6:17 pm

Re: GUI organizational help please.

Postby IronEagle » Thu Jul 21, 2011 9:47 pm

Nookie Wrote:
IronEagle Wrote:On a side note, I have meet with many programmers, and 8 out of 10 of them shudder and puke whenever they think of Java and will argue that it is the worse language


...and the reasons are?

Slow, Interpretated with a C++ like syntax; Not that C++ is bad, but when making a high level language, you normally want it to be easier. That is the whole point of high level languages. And what is even worse, when compared to a compiled language, it is slow. But the important part is how it fares against other interpreted languages. Or is it? No, to get a far comparision, you have to compare it to other "Just-in-Time" languages such as: LuaJit (not to be confused with plain `Lua`) or Javascript (V8). I am not sure about Javascript on V8 but a friend assures me that it is faster, if not as fast and as for LuaJit, it is currently being hailed as the fastest of any JIT or interpreted language.

I won't say there is NO reason to learn Java. I won't say it is the worst tool in a programmers arsenal. I won't say it's slow, bloated, or ugly, but when it comes right down to it, would you rather have the manual or powered screwdriver? You can use either, they will accomplish the same thing.

I may or may not have just accidentally joined a group of diverse people that all coincidentally hate Java, but if you want the thoughts on java by a very respected `hacker`, here is a link to an essay made by Paul Graham: http://www.paulgraham.com/javacover.html
IronEagle
 
Joined: Sun Jun 26, 2011 12:29 am

Re: GUI organizational help please.

Postby idFADE » Fri Jul 22, 2011 1:02 am

Since i can't edit my earlier post due to moderation time im gonna have to double post, sorry moderators but please let this pass.

To the OP:
I would recommend you to hard code your layout in java. Swing is hellish so don't use it for any layout based stuff. Create buttons and menu's with photoshop or something, then use a graphics or graphics2D object to draw them at specific coordinates. Then create a mouse motion listener that sends data to the graphics rendering thread whenever the mouse hovers over the selected areas of the screen.

That's my advice.

I would not recommend you to use any layout managers. Sun created them to make the java programmer's life hell xD
Code: Select All Code
int[] msg = {72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100};
idFADE
Newly Registered
 
Joined: Tue Jun 14, 2011 6:17 pm

Re: GUI organizational help please.

Postby BlueLight » Fri Jul 22, 2011 9:29 am

oh i also forgot to name another resource i can use if im stuck on something. I didn't even think about this.
Anyways i could ask a whole IT department for help. xD
don't ask... but in a sense i could.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby IronEagle » Sat Jul 23, 2011 5:04 pm

BlueLight Wrote:By the way you state things you don't program but you deal with programmers alot. Most likely a work thing. Now you might be a manager...

That's wrong. I am a programmer, I just haven't taken a look at python. I deal with programmers a lot because I am part of a programming group. I can't really suggest the languages I like to use because I prefer to program in C, C++, and C#, which arn't exactly the best beginner languages. Java is accepted in the industry because
Paul Graham Wrote:It's designed for large organizations. Large organizations have different aims from hackers.
http://www.paulgraham.com/javacover.html

This is all I have to say. I do wish you the best of luck with your project, regardless of what tools you choose to make it in. ;)
IronEagle
 
Joined: Sun Jun 26, 2011 12:29 am

Re: GUI organizational help please.

Postby BlueLight » Sun Jul 24, 2011 1:11 am

I am done with this programming book called "Head First Java". While there are a few codes i still need to input and look over but i've read the main body text.
However if i had a better knowledge about the book i wouldn't have pick it. A lot of the codes have some quirk in the code. Some slow it down, Bad practice, or are completely stupid like uncompleted code because of bracket.


IronEagle Wrote:That's wrong. I am a programmer, I just haven't taken a look at python. I deal with programmers a lot because I am part of a programming group. I can't really suggest the languages I like to use because I prefer to program in C, C++, and C#

Sure i could believe that. To bad my guess was off.
IronEagle Wrote:This is all I have to say. I do wish you the best of luck with your project, regardless of what tools you choose to make it in. ;)

Thank you and sorry for being rude but i found what you said earlier a attack not that i believe you were planning it to sound like it. What made it worse is you gave me hearsay with out giving us anything concrete.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby idFADE » Sun Jul 24, 2011 3:30 am

IronEagle Wrote: I can't really suggest the languages I like to use because I prefer to program in C, C++, and C#, which arn't exactly the best beginner languages. Java is accepted in the industry because
Paul Graham Wrote:It's designed for large organizations. Large organizations have different aims from hackers.


Firstly: A java programmer can understand C# code, and vice verse. They are based on the same principles from what I have seen. So why isn't C# as good as "beginner" language as java?
Secondly: Do you know how easy it is to decompile java class files? It can be very easily done and this has some anti-hacker java programmers upset since they can't control who can access their code. However, hackers and crackers love it. It's easy to modify, all you have to do is decompile it from the bytedata and you get everything in pretty .java files, there are several decompilers available.

No offence towards you IronEagle, but do you really know C#?
Code: Select All Code
int[] msg = {72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100};
idFADE
Newly Registered
 
Joined: Tue Jun 14, 2011 6:17 pm

Postby BlueLight » Sun Jul 24, 2011 9:51 pm

idFADE Wrote:
IronEagle Wrote: I can't really suggest the languages I like to use because I prefer to program in C, C++, and C#, which arn't exactly the best beginner languages. Java is accepted in the industry because
Paul Graham Wrote:It's designed for large organizations. Large organizations have different aims from hackers.


Firstly: A java programmer can understand C# code, and vice verse. They are based on the same principles from what I have seen. So why isn't C# as good as "beginner" language as java?
Secondly: Do you know how easy it is to decompile java class files? It can be very easily done and this has some anti-hacker java programmers upset since they can't control who can access their code. However, hackers and crackers love it. It's easy to modify, all you have to do is decompile it from the bytedata and you get everything in pretty .java files, there are several decompilers available.

No offence towards you IronEagle, but do you really know C#?

Okay so idFADE first java has a lot of security put in to the compiler so you don't blow up the computer from a bad program. While i believe C based languages don't (Don't know much about C,C#, or C+.)I know with C+ you can ruin your computer if your not careful. Besides there maintained by different company's. Think of it like talking English and German. A lot of words sound the same but the grammar is completely different.

Second
I can't make heads or tails for what your really saying. Are you saying people are decompiling the code or downloading the program from the server it's running at then decompiling it?
Because i can believe decompiling it but not downloading a server application. Besides I think he was talking about security in the program so a cracker can't hack in to your system and steal information.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re:

Postby idFADE » Mon Jul 25, 2011 12:11 am

BlueLight Wrote:Okay so idFADE first java has a lot of security put in to the compiler so you don't blow up the computer from a bad program. While i believe C based languages don't (Don't know much about C,C#, or C+.)I know with C+ you can ruin your computer if your not careful. Besides there maintained by different company's. Think of it like talking English and German. A lot of words sound the same but the grammar is completely different.

Second
I can't make heads or tails for what your really saying. Are you saying people are decompiling the code or downloading the program from the server it's running at then decompiling it?
Because i can believe decompiling it but not downloading a server application. Besides I think he was talking about security in the program so a cracker can't hack in to your system and steal information.


I didn't think about it from that aspect, i suppose the fail safes in the JRE makes it easier for beginners, however, C# must have some of those features as well since it's based on the same principles as java from what i seen. C++ and C don't have much fail safes though, as you say. Which makes them harder to learn. To ruin the computer you have to write a very bad program though.

I only know a tiny bit about the process of decompiling java applications, it works like this:
You download a JAR, have the decompiler analyse the .class files stored in the JAR, then it reconstructs them into .java files. I don't know about decompiling directly from the server though.
However, i have heard talk about java programs being easy to exploit as well due to some way the compiler handles the memory. This is only talk i have heard though, im not much for cracking stuff, but i like hackers.
Code: Select All Code
int[] msg = {72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100};
idFADE
Newly Registered
 
Joined: Tue Jun 14, 2011 6:17 pm

Re: Re:

Postby BlueLight » Mon Jul 25, 2011 12:25 am

idFADE Wrote:
BlueLight Wrote:Okay so idFADE first java has a lot of security put in to the compiler so you don't blow up the computer from a bad program. While i believe C based languages don't (Don't know much about C,C#, or C+.)I know with C+ you can ruin your computer if your not careful. Besides there maintained by different company's. Think of it like talking English and German. A lot of words sound the same but the grammar is completely different.

Second
I can't make heads or tails for what your really saying. Are you saying people are decompiling the code or downloading the program from the server it's running at then decompiling it?
Because i can believe decompiling it but not downloading a server application. Besides I think he was talking about security in the program so a cracker can't hack in to your system and steal information.


I didn't think about it from that aspect, i suppose the fail safes in the JRE makes it easier for beginners, however, C# must have some of those features as well since it's based on the same principles as java from what i seen. C++ and C don't have much fail safes though, as you say. Which makes them harder to learn. To ruin the computer you have to write a very bad program though.

I only know a tiny bit about the process of decompiling java applications, it works like this:
You download a JAR, have the decompiler analyse the .class files stored in the JAR, then it reconstructs them into .java files. I don't know about decompiling directly from the server though.
However, i have heard talk about java programs being easy to exploit as well due to some way the compiler handles the memory. This is only talk i have heard though, im not much for cracking stuff, but i like hackers.


I don't really know the difference between C, C#, or C++ since it wasn't anything that interested me. Really the reason why i started learn java was because my dad and step mom decided they were going to learn it so they went out a bought a few books. They made no progress btw. Anyways i looked though a few of their books and then ask if they would buy me head first since it was a book both of them had a copy of and that way we could all learn the same things at once. Several Saturdays later and we're done with that hellspawn of a book.

in theory you can compile or decompile anything. You just have to be able to read the file. So i don't see how any language is safe from what your talking about. What i think he was talking about was from out side attacks on the server. I don't know anything about security other than file saving.
User avatar
BlueLight
Gangs n' Whores Developer
 
Joined: Sat Jun 04, 2011 8:23 am

Re: GUI organizational help please.

Postby idFADE » Mon Jul 25, 2011 7:35 pm

I wouldn't go to any java based forum and call head first a hellspawn, a lot of programmers call it THE book to learn java basics.
I would recommend you take a look in Developing games in java by david brackeen.
Code: Select All Code
int[] msg = {72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100};
idFADE
Newly Registered
 
Joined: Tue Jun 14, 2011 6:17 pm

Next

Return to Discussion



Who is online

Users browsing this forum: No registered users