Squareheads

Not working for me :’(


javaws-1.5.0-beta
Using JRE version 1.5.0-beta Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\Robin Chaddock
----------------------------------------------------
c:   clear console window
f:   finalize objects on finalization queue
g:   garbage collect
h:   display this help message
m:   print memory usage
o:   trigger logging
p:   reload proxy configuration
q:   hide console
r:   reload policy configuration
s:   dump system and deployment properties
t:   dump thread list
0-5: set trace level to <n>
----------------------------------------------------
GuiGlobal init FileLoader
NVIDIA Corporation
GeForce2 GTS/AGP/3DNOW!
1.4.0
GL_ARB_imaging
GL_ARB_multitexture
GL_ARB_point_parameters
GL_ARB_texture_compression
GL_ARB_texture_cube_map
GL_ARB_texture_env_add
GL_ARB_texture_env_combine
GL_ARB_texture_env_dot3
GL_ARB_texture_mirrored_repeat
GL_ARB_transpose_matrix
GL_ARB_vertex_buffer_object
GL_ARB_vertex_program
GL_ARB_window_pos
GL_S3_s3tc
GL_EXT_abgr
GL_EXT_bgra
GL_EXT_blend_color
GL_EXT_blend_minmax
GL_EXT_blend_subtract
GL_EXT_clip_volume_hint
GL_EXT_compiled_vertex_array
GL_EXT_draw_range_elements
GL_EXT_fog_coord
GL_EXT_multi_draw_arrays
GL_EXT_packed_pixels
GL_EXT_paletted_texture
GL_EXT_point_parameters
GL_EXT_rescale_normal
GL_EXT_secondary_color
GL_EXT_separate_specular_color
GL_EXT_shared_texture_palette
GL_EXT_stencil_wrap
GL_EXT_texture_compression_s3tc
GL_EXT_texture_cube_map
GL_EXT_texture_edge_clamp
GL_EXT_texture_env_add
GL_EXT_texture_env_combine
GL_EXT_texture_env_dot3
GL_EXT_texture_filter_anisotropic
GL_EXT_texture_lod
GL_EXT_texture_lod_bias
GL_EXT_texture_object
GL_EXT_vertex_array
GL_IBM_rasterpos_clip
GL_IBM_texture_mirrored_repeat
GL_KTX_buffer_region
GL_NV_blend_square
GL_NV_fence
GL_NV_fog_distance
GL_NV_light_max_exponent
GL_NV_packed_depth_stencil
GL_NV_pixel_data_range
GL_NV_point_sprite
GL_NV_register_combiners
GL_NV_texgen_reflection
GL_NV_texture_env_combine4
GL_NV_texture_rectangle
GL_NV_vertex_array_range
GL_NV_vertex_array_range2
GL_NV_vertex_program
GL_NV_vertex_program1_1
GL_NVX_ycrcb
GL_SGIS_generate_mipmap
GL_SGIS_multitexture
GL_SGIS_texture_lod
GL_WIN_swap_hint
WGL_EXT_swap_control
GL_MAX_TEXTURE_SIZE=2048
GL_MAX_TEXTURE_UNITS=2
GL_MAX_ELEMENTS_VERTICES=4096
GL_MAX_ELEMENTS_INDICES=4096
UdpReader socket bound at /192.168.0.1:5002
Failed to add focus traversal component name mainCreate
Failed to add focus traversal component name mainJoin
Failed to add focus traversal component name setupVbo

There is 1 more ‘Failed to add …’ but the java console disappears before I get a chance to click copy.

Strange i’ve had it working before now…

I wonder if its a 1.5 thing (but I thought webstart dealt with all the version control stuff…)

:edit: btw this was off a fresh download - webstart cache was totally empty.

Hi tom!!!
I’m 2late4u … some time ago … you sent to me youre engine source … i used for copnverting a C++ project to view Doom3 map files … i’ve lost it …!!! Damned … could you resend please!!! … my email is pescetromba@libero.it … do you remember!!!

remember this thread?

http://www.java-gaming.org/cgi-bin/JGNetForums/YaBB.cgi?board=jogl;action=display;num=1077528790;start=2#2

help me please … your source code is a bible

I have had this error:



java.lang.UnsatisfiedLinkError: nglDrawRangeElements
      at org.lwjgl.opengl.GL12.nglDrawRangeElements(Native Method)
      at org.lwjgl.opengl.GL12.glDrawRangeElements(Unknown Source)
      at trb.md3.MD3Surface.render(MD3Surface.java:182)
      at trb.q3.MD3Loader.render(MD3Loader.java:214)
      at trb.md3.MD3Character$Model.render(MD3Character.java:392)
      at sh.Character$Controller.render(Character.java:167)
      at trb.gui.xp.XPViewport.run(XPViewport.java:111)
      at trb.gui.xp.XPViewport.renderComponent(XPViewport.java:68)
      at trb.gui.Component.render(Component.java:131)
      at trb.gui.Component.renderChildren(Component.java:141)
      at trb.gui.Component.render(Component.java:132)
      at trb.gui.Component.renderChildren(Component.java:141)
      at trb.gui.Component.render(Component.java:132)
      at trb.gui.Component.renderChildren(Component.java:141)
      at trb.gui.Component.render(Component.java:132)
      at trb.gui.xp.XPBorder.render(XPBorder.java:77)
      at trb.gui.xp.XPFrame.render(XPFrame.java:56)
      at trb.gui.Component.renderChildren(Component.java:141)
      at trb.gui.Component.render(Component.java:132)
      at trb.gui.lwjgl.LWJGLScreen.render(LWJGLScreen.java:160)
      at sh.Menu.runMenu(Menu.java:278)
      at sh.SquareHeads.runMenu(SquareHeads.java:187)
      at sh.SquareHeads.main(SquareHeads.java:879)


LWJGL compatibility???

Doesn’t work very well…i can play for some seconds and then it bombs out with this (Win XP, Radeon 9700pro, Cat4.4):


org.lwjgl.opengl.OpenGLException: Invalid operation (1282)
at org.lwjgl.opengl.Util.checkGLError(Unknown Source)
at org.lwjgl.opengl.Window.update(Unknown Source)
at sh.SquareHeads.runGame(SquareHeads.java:481)
at sh.Menu.runMenu(Menu.java:333)
at sh.SquareHeads.runMenu(SquareHeads.java:293)
at sh.SquareHeads.main(SquareHeads.java:1271)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
at com.sun.javaws.Launcher.run(Unknown Source)
at java.lang.Thread.run(Thread.java:534)

You can only use glDrawRangeElements if you’ve first checked for OpenGL12. Otherwise you must check for EXT_draw_range_elements and use glDrawRangeElementsEXT.

And it’s broken on ATI 128 powered laptops :wink:

Cas :slight_smile:

1.4.2_04/win98se/gf2mx/38.82 deto/128mb/k7 500

It works and it’s surprisingly fast 40-100fps :slight_smile:

The fov is btw a bit low… around 70 or so instead of the default 90 (or more common 100-120).

Nice work tom, runs really well on my comp (winXPpro Geforce4400Ti), the only problem is that it has a tendency to turn the gamma value up very high, making my desktop a bit too bright, and there was no one to shoot ;), adding bots would be a good idea, and fun to code I imagine :slight_smile:

Good stuff though, if you are loading in the BSP or map format for your environments I’d love to make a map for the game. I’ve probably got a dozen or so half finished maps on a HD somewhere, and I’d love to finish them.

Ahh, q3 maps :wink:

Lots of response this time :slight_smile:

[quote]There is 1 more ‘Failed to add …’ but the java console disappears before I get a chance to click copy.
[/quote]
Don’t know what went wrong here. Looks like your drivers is up to date. Maybe a native crash. Maybe I got a System.exit() hidden somewhere. I’ll investigate.

[quote]java.lang.UnsatisfiedLinkError: nglDrawRangeElements
[/quote]
As cas mentioned, your card don’t support opengl 1.2. Next time I will check opengl version needed, and possible rewrite parts to use extensions instead.

[quote]org.lwjgl.opengl.OpenGLException: Invalid operation (1282)
at org.lwjgl.opengl.Util.checkGLError(Unknown Source)
at org.lwjgl.opengl.Window.update(Unknown Source)
[/quote]
Another difficult one. Something caused an opengl error before the update call.

[quote]The fov is btw a bit low… around 70 or so instead of the default 90 (or more common 100-120).
[/quote]
Good observation. I set the fovy to 90 wich at a 4:3 aspect ratio would give a fovx of 67.5. In the next update I’ll use fovx 90 deg.

[quote]the only problem is that it has a tendency to turn the gamma value up very high, making my desktop a bit too bright
[/quote]
Yes the gamma is probably set too high. I’ve got plans to make it possible to change the gamma, brightness and contrast from the menu.

[quote]and there was no one to shoot , adding bots would be a good idea, and fun to code I imagine
[/quote]
And bloody difficult :wink: I did some experimental pathfinding, but the ai’s got stuck all the time, so I gave up. Hopefully the game will be popular enough when it’s finished, that it will be possible to find someone to play with online.

[quote]Good stuff though, if you are loading in the BSP or map format for your environments I’d love to make a map for the game. I’ve probably got a dozen or so half finished maps on a HD somewhere, and I’d love to finish them.
[/quote]
That’s terrific. I really need content so any contribution is welcome. Do you create your own textures or do you use the one from q3? In the finished game I can not use any content from q3. I’ve got a friend who is going to make a level with original textures. You could possible use his textures when he is finished.

There are a bunch of texturesets made for q3. The evil lair sets are kinda popular and are generally high quality :slight_smile:

I just tried it. I’m running 1.4.2_04 on XP. Works great in windowed mode but I get the following when I try to go into fullscreen.


java.lang.IllegalStateException: Mouse must be created before you can read events
      at org.lwjgl.input.Mouse.next(Unknown Source)
      at trb.gui.lwjgl.LWJGLScreen.handleMouse(LWJGLScreen.java:116)
      at trb.gui.lwjgl.LWJGLScreen.processInput(LWJGLScreen.java:70)
      at sh.Menu.runMenu(Menu.java:315)
      at sh.SquareHeads.runMenu(SquareHeads.java:293)
      at sh.SquareHeads.main(SquareHeads.java:1271)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at com.sun.javaws.Launcher.executeApplication(Unknown Source)
      at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
      at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
      at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
      at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
      at com.sun.javaws.Launcher.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)


Another little problem!!
During my game session, without a reason, the game return to the menù screen. So I have to reJoin! … what’s the matter!!!

Works fantastic on my laptop. I also get the same mouse error (java.lang.IllegalStateException: Mouse must be created before you can read events), but I get this error also when I just change the resolution.

I’m really amazed by the speed and smoothness of it all. I’m getting ~60-130 fps with a crap video card.

Sure, if you want me to use your own textures that’s not a problem, I’m rubbish at creating my own textures anyway and would have probably used some of the evil lair textures, as oNyx mentioned, they are pretty cool.

Just send me a message with a link to the textures when they’re ready and any other relevant information, I doubt I’ll have time to make a huge map but I should be able to knock something up. Been a long time since I last made a map and it’ll be a nice distraction from trundling through the red book :wink:

Trying this on the Mac:

java.lang.IllegalArgumentException: InputStream cannot be null
at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:72)
at trb.util.XMLDocument.(XMLDocument.java:28)
at sh.Menu.createMenuGui(Menu.java:126)
at sh.Menu.init(Menu.java:84)
at sh.SquareHeads.runMenu(SquareHeads.java:291)
at sh.SquareHeads.main(SquareHeads.java:1271)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.sun.javaws.Launcher.executeApplication(Launcher.java:844)
at com.sun.javaws.Launcher.executeMainClass(Launcher.java:804)
at com.sun.javaws.Launcher.continueLaunch(Launcher.java:682)
at com.sun.javaws.Launcher.handleApplicationDesc(Launcher.java:397)
at com.sun.javaws.Launcher.handleLaunchFile(Launcher.java:199)
at com.sun.javaws.Launcher.run(Launcher.java:167)
at java.lang.Thread.run(Thread.java:552)

It shouldn’t work on the Mac.

Cas :slight_smile:

Everything SHOULD work on the Mac :slight_smile:

I get as far as the opening screen then it bombs (WinXP Pro, GEforce Ti4200 with 45.23 drivers, 512MB RAM) :

An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x697451E2
Function=[Unknown.]
Library=J:\WINDOWS\System32\nvoglnt.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.

Current Java thread:
at org.lwjgl.opengl.GL12.nglDrawRangeElements(Native Method)
at org.lwjgl.opengl.GL12.glDrawRangeElements(Unknown Source)
at trb.md3.MD3Surface.render(MD3Surface.java:182)
at trb.q3.MD3Loader.render(MD3Loader.java:214)
at trb.md3.MD3Character$Model.render(MD3Character.java:392)
at sh.Character$Controller.render(Character.java:167)
at trb.gui.xp.XPViewport.run(XPViewport.java:111)
at trb.gui.xp.XPViewport.renderComponent(XPViewport.java:68)
at trb.gui.Component.render(Component.java:131)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.xp.XPBorder.render(XPBorder.java:77)
at trb.gui.xp.XPFrame.render(XPFrame.java:56)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.lwjgl.LWJGLScreen.render(LWJGLScreen.java:160)
at sh.Menu.runMenu(Menu.java:316)
at sh.SquareHeads.runMenu(SquareHeads.java:293)
at sh.SquareHeads.main(SquareHeads.java:1271)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
at com.sun.javaws.Launcher.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

It works on my Ti4200 on WinXP Pro (and it works pretty great too, getting up to >500fps)
Maybe it’s a driver issue. You could update your driver, but whatever you do, DON’T use the latest; they (56.72) totally screwed my PC. NVidia and their damn drivers…
(I rolled back to 53.03 which seems stable, if not trouble free).

A new version is up with a fix for the DrawRangeElements bug, and the window resizing bug.

Erikd - I’ll try Tom’s new version before updating my drivers.

Tom - just tried the latest version, unfortunately still not working for me. In my webstart log I get:

GuiGlobal init FileLoader
Unable to add zip D:\compaq\spill\Quake 3 Arena\baseq3\pak0.pk3
java.util.zip.ZipException: The system cannot find the path specified
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.(Unknown Source)
at java.util.zip.ZipFile.(Unknown Source)
at trb.io.FileLoader.addZipFile(FileLoader.java:48)
at sh.Global.init(Global.java:26)
at sh.SquareHeads.initLwjgl(SquareHeads.java:169)
at sh.SquareHeads.main(SquareHeads.java:1294)

Unable to add zip C:\java\sh\src\quartzdm1.jar
java.util.zip.ZipException: The system cannot find the path specified
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.(Unknown Source)
at java.util.zip.ZipFile.(Unknown Source)
at trb.io.FileLoader.addZipFile(FileLoader.java:48)
at sh.Global.init(Global.java:27)
at sh.SquareHeads.initLwjgl(SquareHeads.java:169)
at sh.SquareHeads.main(SquareHeads.java:1294)

Is this a problem with one of the jars?

Also, I still get the NVidia error:

An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_GUARD_PAGE (0x80000001) occurred at PC=0x697451E2
Function=[Unknown.]
Library=J:\WINDOWS\System32\nvoglnt.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.

Current Java thread:
at org.lwjgl.opengl.EXTDrawRangeElements.nglDrawRangeElementsEXT(Native Method)
at org.lwjgl.opengl.EXTDrawRangeElements.glDrawRangeElementsEXT(Unknown Source)
at trb.md3.MD3Surface.render(MD3Surface.java:183)
at trb.q3.MD3Loader.render(MD3Loader.java:213)
at trb.md3.MD3Character$Model.render(MD3Character.java:391)
at sh.Character$Controller.render(Character.java:166)
at trb.gui.xp.XPViewport.run(XPViewport.java:110)
at trb.gui.xp.XPViewport.renderComponent(XPViewport.java:67)
at trb.gui.Component.render(Component.java:131)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.xp.XPBorder.render(XPBorder.java:77)
at trb.gui.xp.XPFrame.render(XPFrame.java:56)
at trb.gui.Component.renderChildren(Component.java:141)
at trb.gui.Component.render(Component.java:132)
at trb.gui.lwjgl.LWJGLScreen.render(LWJGLScreen.java:159)
at sh.Menu.runMenu(Menu.java:321)
at sh.SquareHeads.runMenu(SquareHeads.java:321)
at sh.SquareHeads.main(SquareHeads.java:1295)

But, it still manages to whack my gamma up to ultra-bright
:-/

I’ll try newer drivers now and report back…,