How i made my menu,
What you could do is make an enum, add the menus in it as states (so MAINMENU, HACKS, UPDATER etc) And then make a button class which takes a couple of arguments ( Like x...
Type: Posts; User: elamre
How i made my menu,
What you could do is make an enum, add the menus in it as states (so MAINMENU, HACKS, UPDATER etc) And then make a button class which takes a couple of arguments ( Like x...
Make a new thread about that, and post the code. I'll try to help you then.
So there is no difference between Object object; and Object object = null?
Could you post the code as is now?
2 small things. First of all, try using the .code=java] ./code] tags (replace the . with a [) so it's easier to read. Also why do you do
arrayOneValue = arrayOneValue +1
instead of just...
String day = "";
for (int i=0; i< days.length; i++) {
if (!dag.equals(day)) {
This part, what should it do?
What do you want to achieve exactly? I'm not quite understanding the purpose of this yet.
Also post your full output. This is what i did:
public static void main(String[] args){
String[]...
String[] days = { "Monday", "Tuesday", "Wednesday", "Turshday", "Friday", "Saturday", "Sunday" };
String day = "";
for (int i = 0; i < days.length; i++) {
day += days[i]; // previously...
Ah ok. Your day array has a length of 7 (Monday-Sunday are 7 days). Agreed? So the days.length will return 7. Only the thing is, it starts at 0 instead of 1. So "Monday" will be 0. and then it will...
What is line 32?
Welcome Amol
hello darey
You could update the speed every timer tick, but why not update the position every tick?
make something like an update function. something along the lines of:
public void update(){
x+=xspeed;...
That's true indeed. Now look at the line i pointed out. It will execute that every 10 ms i believe. so every once in a very short while it will execute ball.getXPoint() and ball.getYPoint(). And...
Try to get just 1 ball able to bounce and move properly. If you follow Norm's tips on his post, and then read what i said, you should be able to make a conclusion on what is going wrong :) .
Owh, well mine thought me to use this. by this. you refer to a private data field. Also i'm not quite inderstanding your code. Do you want a simple ball bouncing on the screen? If so, look at this...
Also another tip, instead of writing a "_" in front of every variable the class has, you could also use "this." makes everything a bit easier in my opinion. Example:
private int speed = 0;...
To slow it you could always make the x and y positions a double or float i suppose and do the same for the x and y point. then multiply them by 0.1 or something. It should go slower now.
I dont...
Depends how you make it. You could make a rectangle for each button, then whenever the mouse is pressed you could send the mouse pointer location to all your buttons. In your button you should check...
Your class's name is also Collections, try renaming your class and see what happens :)
For the formatting, i use an ide called Eclipse, it has a really nifty build in formatter. press control shift f and everything goes where it should be. When im working together with other people we...
That is a good solution, you could've also made an if-else statement. No particular advantages to that, but i find it easier to understand my own code that way:
import java.util.Scanner;...
What exactly does it give for error?
Also try using the code taggs.
.code=java]
your code here
./code]
replace the . with [
Welcome to the forum, you can learn a lot on this forum, just read other peoples questions, and read and understand the answers :-).
I've had that problem a lot as well. For some of my friends it was an outdated java version. For the others the .exe worked. Give it a try, it's so much easier.