Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (498)
Games in Android Showcase (116)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Java Game APIs & Engines / OpenGL Development / Re: Installing on: 2005-09-13 06:14:51
Aha! I found the problem. When I copy and pasted to took your command as 2 seperate commands. Ok it works. Thankyou!

EDIT: Okay, I copy and paste the sourcecode from oen of the demos on LWJGL's demo page on the website. The "PlayTest" source. So I download it, and when I compile it, I get this error

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
34  
35  
36  
37  
38  
C:\lwjgl-win32-0.98>javac -cp .;res;jar\lwjgl.jar;jar\lwjgl_test.jar;jar\lwjgl_u
til.jar PlayTest.java
PlayTest.java:1: 'class' or 'interface' expected
*
^
PlayTest.java:16: unclosed character literal
 * * Neither the name of 'LWJGL' nor the names of
                         ^
PlayTest.java:16: unclosed character literal
 * * Neither the name of 'LWJGL' nor the names of
                               ^
PlayTest.java:34: 'class' or 'interface' expected
import java.io.BufferedInputStream;
^
PlayTest.java:35: 'class' or 'interface' expected
import java.io.ByteArrayOutputStream;
^
PlayTest.java:36: 'class' or 'interface' expected
import java.nio.ByteBuffer;
^
PlayTest.java:37: 'class' or 'interface' expected
import java.nio.ByteOrder;
^
PlayTest.java:38: 'class' or 'interface' expected
import java.nio.IntBuffer;
^
PlayTest.java:40: 'class' or 'interface' expected
import org.lwjgl.BufferUtils;
^
PlayTest.java:41: 'class' or 'interface' expected
import org.lwjgl.openal.AL10;
^
PlayTest.java:42: 'class' or 'interface' expected
import org.lwjgl.util.WaveData;
^
11 errors

C:\lwjgl-win32-0.98>


EDIT:EDIT: Ok so I try a OPENGL test this time, the WindowedFullscreen test one. It compiles fine but I get this error.

Quote

C:\lwjgl-win32-0.98>java FullScreenWindowedTest
Exception in thread "main" java.lang.NoClassDefFoundError: FullScreenWindowedTes
t (wrong name: org/lwjgl/test/opengl/FullScreenWindowedTest)
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$100(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClassInternal(Unknown Source)

C:\lwjgl-win32-0.98>
2  Java Game APIs & Engines / OpenGL Development / Installing on: 2005-09-13 04:53:57
Befor I get flamed, I did do a search, on variouse forums and sites.


I have LWJGL in c:\lwjgl-win32-0.98\

When I go to that directory and do
1  
2  
java -cp lwjgl.jar;lwjgl_test.jar;lwjgl_util.jar; org.lwjgl.test.WindowCreationTest
pause


I get this error
1  
2  
3  
4  
5  
6  
7  
C:\lwjgl-win32-0.98>java -cp lwjgl.jar;lwjgl_test.jar;lwjgl_util.jar; org.lwjgl.
test.WindowCreationTest
Exception in thread "main" java.lang.NoClassDefFoundError: org/lwjgl/test/Window
CreationTest

C:\lwjgl-win32-0.98>pause
Press any key to continue . . .


So I figured I need to set the class path. So I enter
1  
java -cp c:\lwjgl-win32-0.98\jar\lwjgl.jar


And all it returns is how to use the java command. Any ideas?
3  Game Development / Game Mechanics / Re: Pong Colision on: 2005-09-11 01:00:17
 Shocked Finaly someone replys after to days  Angry

Anyway, this is how I assing the X and Y positions for the bars....

1  
2  
3  
4  
5  
6  
   public void mouseMoved(MouseEvent m){
      if(gameState != 2 && gameState != 1){
         vBarY = m.getY();
         hBarX = m.getX();
      }
   }


It works becuase the bars move. and vBarH is the height of the bar which is 75. NEW DISCOVORY! The ball only goes wacko if the ball is within the two verticle bars. if the two verticle bars are at the opposit side of the screen, it works fine.
4  Game Development / Game Mechanics / Pong Colision on: 2005-09-08 23:09:26
Ok I have this code to test colision of 4 "bars" to the ball.
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
public void checkHBarColision1(){
      if(ballX <= hBarX+hBarW && ballX >= hBarX && ballY <= hBar1Y+hBarH){
         //if(ballDir==3 || ballDir==0)
           bounceDown();
      }  
   }
   
   public void checkHBarColision2(){
      if(ballX <= hBarX+hBarW && ballX >= hBarX && ballY+16 >= hBar2Y-hBarH){
         ////if(ballDir==5 || ballDir==2)
           bounceUp();

      }  
   }

   public void checkVBarColision1(){
      if(ballY <= vBarY+vBarH && ballY >= vBarY && ballX <= vBarY+vBarW){
         //if(ballDir >= 3)
           bounceRight();

      }
   }
   
   public void checkVBarColision2(){
      if(ballY <= vBarY+vBarH && ballY >= vBarY && ballX+16 >= vBarY-vBarW){
         //if(ballDir <= 2)
           bounceRight();

      }
   }


Now what controles all four bars(2 on the top and bottom of the screen,2 on left and right.) is the mouse. mouse Y position dictates the Y position of the Verticle(sides) and the X position of the mouse dictates the x position of the horizontal bars(top and bottom). Now the ball only bounces when the mouse has touchted the ball. Any idea why the ball bounces when it touches the location of the mouse, and not the bars?
5  Java Game APIs & Engines / Java 3D / 3D Model tips in Java3D on: 2005-09-08 06:01:15
Ok here is my situation. I have milkshape. I want to make 3D java **applets** using java3d(since that doesn't requier any downloading. I need a way to load and display models in my game. I would like to have the ability to bable to easily to place my characters weapon in his hand with out having to do math(I am the worst at math) I know I need a loader, but hwat is involed in displaying the model? And getting all the rotations working(I have worked with 3d engines in c++, so java should be a breeze)

EDIT: Or is there a way to use a engine like JME in a applet with out library downloads?
6  Game Development / Newbie & Debugging Questions / Re: MouseMotionListener on: 2005-09-06 00:11:38
Aha! Thatwas the problem. Forgot to addmousemotionlistener() Thankyou!
7  Game Development / Newbie & Debugging Questions / MouseMotionListener on: 2005-09-05 23:02:02
Ok in my simple pong game, I want the paddle to follow the postion of the mouse. So I have "implements MouseMotionListener" with the two methods mouseDragged and mouseMoved. In mouseMoved I have...

1  
2  
3  
4  
   public void mouseMoved(MouseEvent m){
      vBarY = m.getY();
      hBarX = m.getX();
   }


But the bars aren't moving. Is there something I'm missing?
Pages: [1]
 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

radar3301 (12 views)
2014-09-21 23:33:17

BurntPizza (30 views)
2014-09-21 02:42:18

BurntPizza (22 views)
2014-09-21 01:30:30

moogie (20 views)
2014-09-21 00:26:15

UprightPath (28 views)
2014-09-20 20:14:06

BurntPizza (32 views)
2014-09-19 03:14:18

Dwinin (48 views)
2014-09-12 09:08:26

Norakomi (74 views)
2014-09-10 13:57:51

TehJavaDev (102 views)
2014-09-10 06:39:09

Tekkerue (50 views)
2014-09-09 02:24:56
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!