Java-Gaming.org Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (687)
Games in Android Showcase (198)
games submitted by our members
Games in WIP (758)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: 1 ... 5 6 [7] 8 9 10
 61 
 on: 2016-08-28 14:34:04 
Started by vbrain - Last post by CaptainJester
Not a bad little game. Upgrade the graphics some and it could become pretty popular.

 62 
 on: 2016-08-28 14:33:02 
Started by DopplerFrog - Last post by DopplerFrog
Hi, I have an issue with scrollpanes.
After I click on the scrollpane and scroll around a bit, the mouse gets locked to the Scrollpane.
After its locked scrolling the mouse wheel makes the scrollpane scroll but I can no longer use scroll for other events.
I would like to either be able to somehow break the connection between the scrollwheel and the scrollPane.
Is this possible?

 63 
 on: 2016-08-28 14:28:09 
Started by Ecumene - Last post by Riven
The theory behind applets was exactly that - lock the java code in a sandbox
that protects the user from harm.  Sadly, Oracle gave up trying to maintain that
model.
The sandbox model blacklists (locks and barriers), it doesn't whitelist.

Furthermore, the sandbox did checks at runtime, instead of whitelisting code at compile/load-time.

 64 
 on: 2016-08-28 14:18:03 
Started by mike_bike_kite - Last post by basil_
you might have the "zip" file open somewhere else.

 65 
 on: 2016-08-28 11:40:48 
Started by mike_bike_kite - Last post by mike_bike_kite
Background: I've had a stressfull 24 hours. PC get shutting down which turned out to be thermal paste causing CPU to overheat. Decided to treat myself to closed loop water cooler and had the devil's job installing it. I've seen watches with fewer parts than what came with the cooler, the instructions are tiny and written in umpteen languages, diagrams refer to part numbers which are actually letters on the parts, all writing on the parts is tiny black writing on a black background - I nearly lost the will to live. Finally got it installed and the damn PC wouldn't start at all. Eventually took the whole PC apart and rebuilt it piece by piece, testing as I went. Finally it works again...

Problem : Sadly when I came to compile my projects I ended up with the same bizarre error occurring each time. The code was running fine. The various projects compile fine but just stop immediately on running. Oddly, I have one project without sound and that runs fine. I use the tinysound jar and have a separate copy of the jar in each of my different game directories. This is the error I'm shown:

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  
39  
40  
41  
42  
43  
E:\Dropbox\Projects\CloudMiner>javac -cp ".;tinysound-1.1.1.jar" CloudMiner.java

E:\Dropbox\Projects\CloudMiner>jar -cfm CloudMiner.jar Manifest.txt *.class *.png *.wav

E:\Dropbox\Projects\CloudMiner>java -cp ".;CloudMiner.jar;tinysound-1.1.1.jar" -Dsun.java2d.noddraw=true CloudMiner
Exception in thread "main" java.lang.InternalError: java.util.zip.ZipException: error in opening zip file
        at sun.misc.URLClassPath$JarLoader.getResource(Unknown Source)
        at sun.misc.URLClassPath$2.next(Unknown Source)
        at sun.misc.URLClassPath$2.hasMoreElements(Unknown Source)
        at java.lang.ClassLoader$2.hasMoreElements(Unknown Source)
        at sun.misc.CompoundEnumeration.next(Unknown Source)
        at sun.misc.CompoundEnumeration.hasMoreElements(Unknown Source)
        at sun.misc.CompoundEnumeration.next(Unknown Source)
        at sun.misc.CompoundEnumeration.hasMoreElements(Unknown Source)
        at java.util.ServiceLoader$LazyIterator.hasNextService(Unknown Source)
        at java.util.ServiceLoader$LazyIterator.hasNext(Unknown Source)
        at java.util.ServiceLoader$1.hasNext(Unknown Source)
        at com.sun.media.sound.JSSecurityManager$4.run(Unknown Source)
        at com.sun.media.sound.JSSecurityManager$4.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at com.sun.media.sound.JSSecurityManager.getProviders(Unknown Source)
        at com.sun.media.sound.JDK13Services.getProviders(Unknown Source)
        at javax.sound.sampled.AudioSystem.getProviders(Unknown Source)
        at javax.sound.sampled.AudioSystem.getMixerProviders(Unknown Source)
        at javax.sound.sampled.AudioSystem.getMixerInfoList(Unknown Source)
        at javax.sound.sampled.AudioSystem.getMixerInfo(Unknown Source)
        at javax.sound.sampled.AudioSystem.isLineSupported(Unknown Source)
        at kuusisto.tinysound.TinySound.init(TinySound.java:102)
        at CloudMiner.init(CloudMiner.java:1129)
        at CloudMiner.main(CloudMiner.java:1015)
Caused by: java.util.zip.ZipException: error in opening zip file
        at java.util.zip.ZipFile.open(Native Method)
        at java.util.zip.ZipFile.<init>(Unknown Source)
        at java.util.zip.ZipFile.<init>(Unknown Source)
        at java.util.jar.JarFile.<init>(Unknown Source)
        at java.util.jar.JarFile.<init>(Unknown Source)
        at sun.misc.URLClassPath$JarLoader.getJarFile(Unknown Source)
        at sun.misc.URLClassPath$JarLoader.access$600(Unknown Source)
        at sun.misc.URLClassPath$JarLoader$1.run(Unknown Source)
        at sun.misc.URLClassPath$JarLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.misc.URLClassPath$JarLoader.ensureOpen(Unknown Source)
        ... 24 more

Any thoughts would be welcome
It's probably something stupid as I'm feeling just a little burnt out at the moment.
 Huh

 66 
 on: 2016-08-28 11:25:25 
Started by Exonto - Last post by VaTTeRGeR
Quote
chunks work well with this, you can build a graph from these chunks:
-every connected walkable area in a chunk is a distinct node
-if node B can be reached (with A*) from node A => connect nodes with an edge
-do this only for chunks that are touching on the edge/corner to limit graph complexity
Not the whole chunk is getting one node, but every connected part of the chunk does.
You can find this out by doing flood-fill or whatever until every walkable tile inside the chunk has been visited. This should work nicely.
node!=chunk

 67 
 on: 2016-08-28 09:23:05 
Started by Exonto - Last post by theagentd
Depending on how your map looks, hierarchical pathfinding may have problems. Consider a chunk where the a river crosses it horizontally. In this case, the chunk is "enterable" from all four sides, but it's not possible to go from the top to the bottom and vice versa, and if you enter on the top right you can only exit at the top and top left. The chunk is essentially two completely separated areas in this case. Another funny case is if you have a chunk which only the corners are walkable. Again, all 4 directions are technically enterable, but you can't really go anywhere from there. Handling cases like that is the most complex part of implementing hierarchical pathfinding.

 68 
 on: 2016-08-28 08:53:35 
Started by Exonto - Last post by VaTTeRGeR
Search for hierarchical pathfinding.
You basically create graph(s) with different levels of detail so that you only need to use full pathfinding for the nearest tiles.

chunks work well with this, you can build a graph from these chunks:
-every connected walkable area in a chunk is a distinct node
-if node B can be reached (with A*) from node A => connect nodes with an edge
-do this only for chunks that are touching on the edge/corner to limit graph complexity

this graph should be much faster to navigate in, just do it in real-time
You can do this simplification multiple times for even more optimization.

http://aigamedev.com/open/review/near-optimal-hierarchical-pathfinding/

 69 
 on: 2016-08-28 06:30:18 
Started by Exonto - Last post by Exonto
I have a situation where I am using the A* pathfinding method to move a creature across a tile based world.
This particular world can be extremely large and has many obstacles obstructing a creature's path (trees in this case).
When calculating paths over semi-short distances there is not a problem. However, there are huge freezes which take
place when I try to calculate a path over three hundred tiles away (or so). And yes this is because I haven't multi threaded
pathfinding yet, but I feel it would still be too slow even after threading it.

Anyways, here's a picture to give you a sense of the scale.



That isn't even the whole world, the minimap only shows 200 x 200 tiles whereas the full world may be infinite in size depending on the world generation rules.

I have heard that certain games, such as dwarf fortress I think? Split up their worlds into regions and somehow use those regions to improve the performance
of the pathfinding. Conveniently, I already have every world split up into 16 x 16 chunks which are currently acting as a method to define biomes, but I'm thinking
I can also use them for the purpose of quicker pathfinding.

I am not sure how this mechanically works. I am thinking the way this functions is that a path from the center of each region to all adjacent regions is calculated
and then cached, but I'm not sure. Not to mention that would significantly decrease shortest path accuracy.

So how can I use world regions to help improve long distance pathfinding? Or if there's a better way in general, please let me know Smiley.

Edit
I now realize this probably belongs in the artificial intelligence section.

 70 
 on: 2016-08-28 00:10:05 
Started by DayTripperID - Last post by gouessej
Hi

Maybe my schema and my short explanation can help you:
https://gouessej.wordpress.com/2013/10/22/tuer-7-ans-deja-tuer-already-7-years/#themanagementofapplicativestates

I use the Fettle API, it's used in Candy Crush too.

Pages: 1 ... 5 6 [7] 8 9 10
 
roseslayer (602 views)
2016-08-06 11:43:29

roseslayer (556 views)
2016-08-06 09:43:11

xTheGamerCodes (628 views)
2016-08-04 15:40:59

xTheGamerCodes (622 views)
2016-08-04 15:40:24

orrenravid (969 views)
2016-07-16 03:57:23

theagentd (1047 views)
2016-07-11 14:28:54

Hydroque (1159 views)
2016-07-06 05:56:57

Hydroque (1087 views)
2016-07-03 08:52:54

GrandCastle (903 views)
2016-07-01 09:13:47

GrandCastle (649 views)
2016-07-01 09:09:45
Rendering resources
by Roquen
2016-08-08 05:55:21

Rendering resources
by Roquen
2016-08-08 05:52:42

Rendering resources
by Roquen
2016-08-08 05:50:38

Rendering resources
by Roquen
2016-08-08 05:49:53

Rendering resources
by Roquen
2016-08-08 05:32:39

Making a Dynamic Plugin System
by Hydroque
2016-06-25 00:13:25

Java Data structures
by BinaryMonkL
2016-06-13 21:22:09

Java Data structures
by BinaryMonkL
2016-06-13 21:20:42
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!