Welcome to the Browser-Base Game Zone forums!
Why are you choosing java? Are you going to use standalone java or applet?
Quote from: hiigara on February 12, 2012, 05:10:35 PMWhy are you choosing java? Are you going to use standalone java or applet?I'm a bit tired of C/C++ And Java has nice properties (can be turned into BBG, 3DMMORPG, flash like singleplayer online game, standalone downloadable game, util. It is easily "compiled" as PC/LinuxMac/various mobiles versions, require the fewest paid components, programs and licences). It's nice that with it I can change my mind later and switch to a completely different type of game category while reusing most code (which is not possible with C/C++ or PHP).BTW, I have dumped Eclipse and installed NetBeans, now I managed to make it work (and the IDE launch faster)
public void mousePressed(MouseEvent e){ //----menu option code----\\ //---first option code---\\ //single player if (main_menu && hovered && menu_option1) { menu_option1 = false; hovered = false; started_opt1 = true; if(started_opt2){ hovered = false; started_opt2 = false; menu_option2 = false; } } //close single player if (main_menu && hovered && menu_opt1_close && started_opt1) { hovered = false; started_opt1 = false; } //---seconed option code---\\ //multiplayer if (main_menu && hovered && menu_option2) { hovered = false; started_opt2 = true; menu_option2 = false; if(started_opt1){ hovered = false; started_opt1 = false; menu_option1 = false; } } //multiplayer_start if (main_menu && hovered && multiplayer_start) { hovered = false; multiplayer_started = true; multiplayer_start = false; main_menu = false; started_opt2 = false; } //close multiplayer if (main_menu && hovered && menu_opt2_close && started_opt2) { hovered = false; started_opt2 = false; menu_opt2_close = false; } //---third option code---\\ //close application if (main_menu && hovered && menu_option3) { menu_option3 = false; hovered = false; if(started_opt1){ hovered = false; started_opt1 = false; menu_option1 = false; } if(started_opt2){ hovered = false; started_opt2 = false; menu_option2 = false; } stop(); } //----end of menu option code----\\
public void mouseMoved(MouseEvent e){//code to make hovering for main menu work if (main_menu) { //----menu option code----\\ if(!started_opt1 || !started_opt2){ if (mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 235 && my <= 255) {//single player menu_option1 = true; hovered = true; }else if (mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 265 && my <= 285) {//multiplayer menu_option2 = true; hovered = true; }else if(mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 295 && my <= 315){//close menu_option3 = true; hovered = true; } else { menu_option1 = false; menu_option2 = false; menu_option3 = false; hovered = false; } } if(started_opt1 || started_opt2){ if (mx >= width / 2 - 95 && mx <= width / 2 + 5 && my >= 235 && my <= 255 && started_opt1) {//close single player menu_opt1_close = true; hovered = true; }else if (mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 235 && my <= 255) {//highlight singleplayer button menu_option1 = true; hovered = true; }else if (mx >= width / 2 - 95 && mx <= width / 2 + 5 && my >= 235 && my <= 255 && started_opt2) {//close multiplayer menu_opt2_close = true; hovered = true; }else if (mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 265 && my <= 285) {//highlight multiplayer button menu_option2 = true; hovered = true; }else if(mx >= width / 2 - 293 && mx <= width / 2 - 187 && my >= 295 && my <= 315){//highlight close button menu_option3 = true; hovered = true; }else if(mx >= width / 2 - 95 && mx <= width / 2 + 5 && my >= 285 && my <= 305 && started_opt2){ multiplayer_start = true; hovered = true; } else { menu_option1 = false; menu_option2 = false; menu_option3 = false; multiplayer_start = false; menu_opt1_close = false; menu_opt2_close = false; hovered = false; } } } //-------end of menu option code-------\\