Java-Gaming.org Hi !
Featured games (87)
games approved by the League of Dukes
Games in Showcase (649)
Games in Android Showcase (181)
games submitted by our members
Games in WIP (700)
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] 2 3 ... 302
1  Game Development / Game Mechanics / Re: Calculating dFdx and dFdy of texture coordinates in 2D manually on: 2016-02-09 17:32:58
You'd have to split the triangle in two, along the X-axis (' scanline') of the point that is between the other two points (when projected on the Y axis). Then use the typical scanline approach on the two triangles.

Basically just what the GPU does (unless it changed in the last 10 years).

Also, don't you need to take depth (in screenspace) into consideration? Or don't you need perspective when sampling? It affects dfdx and dfdy significantly.


Calculating dfdx and dfdy without the split seems quite complex.

2  Games Center / Featured Games / Re: Naroth - 3D open world RPG on: 2016-02-07 22:46:53
Featured Pointing
3  Games Center / WIP games, tools & toy projects / Re: Vangard on: 2016-01-31 21:35:06
Rannveig found a deer 99.76412331822027m away.
Unn found a deer 386.84841314152357m away.
Gudfinna found a deer 399.05202528122174m away.
Gunnhild found a deer 483.4492922292207m away.
Rannveig found a deer 394.834353239086m away.
Hlodvir found a deer 481.8736082024527m away.
Might as well have (int)'ed those values before printing them persecutioncomplex
Hey, if he calculated the distance between a peasant and a deer, with an accuracy that is a fraction of the radius of a proton, he should be showing it off. Hat's off to you, sir!
4  Discussions / General Discussions / Re: Oracle kills webstart on: 2016-01-29 07:51:33
Oracle kills applets and suggests developers switch over to Web Start Pointing
5  Game Development / Newbie & Debugging Questions / Re: design pattern to avoid exponential number of extensions on: 2016-01-24 22:45:09
Could you be a little less abstract in the goal you are trying to achieve?

When you get more specific, our answers will be too Wink
6  Game Development / Newbie & Debugging Questions / Re: design pattern to avoid exponential number of extensions on: 2016-01-23 13:17:06
Extract the implementation of various subclasses as interfaces with their implementing classes. The base class now has 5 fields, containing references to the appropriate implementations. If you need data from the base class in your implementation, pass the base class as an argument to the method implementing the business logic, or pass it in the constructor.

The decorator pattern seems like a poor fit for the base class. You can use it, however, for the 5 interfaces.
7  Games Center / WIP games, tools & toy projects / Re: Pong in Java on: 2016-01-22 20:11:14
Having the ball bounce in the same direction regardless of the point of contact (on a specific face) is actually physically correct behavior, as long as the face is perfectly flat. You can change the outbound angle by moving the paddle during the collision. This means that the ball actually has to intersect the paddle for a tiny (non-zero) period of time. Things get surprisingly complex fast, which is why everybody cheats by working the relative position to the paddle into some blatantly wrong algorithm that 'feels fun' - it is a game after all...

You can lookup some YouTube videos of the First pong ever, it was mostly analog logic, the ball didn't even have a straight trajectory, you could move the paddle along 2 axis, it would bounce off the net in the middel - way better than any pong clone since.

<a href="http://www.youtube.com/v/XNRx5hc4gYc?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/XNRx5hc4gYc?version=3&amp;hl=en_US&amp;start=</a>

<a href="http://www.youtube.com/v/-I73oK9q-jk?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/-I73oK9q-jk?version=3&amp;hl=en_US&amp;start=</a>
8  Discussions / Miscellaneous Topics / Re: What I did today on: 2016-01-22 19:02:43
Because of the
1  
2  
3  
   else {
      return false;
   }


J0 Smiley

Ooops, my fault. Thanks for pointing that out.
I pointed it out in my earlier reply. (not that I insist to get the credit, but... wasn't my diff clear? persecutioncomplex)
9  Discussions / Miscellaneous Topics / Re: What I did today on: 2016-01-22 16:13:55
It doesn't matter really, write unit-tests to validate your assumptions Pointing
10  Discussions / Miscellaneous Topics / Re: What I did today on: 2016-01-22 15:41:44
Oooh, so many bugs Pointing

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  
44  
45  
46  
47  
var internalArray = [];

var ArrayList = {
   add : function(o) {
      internalArray.push(o);
   },
   get : function(i) {
      return internalArray[i];
   },
   isEmpty : function() {
      if (internalArray.length == 0) {
         return true;
      } else {
         return false;
      }
   },
   size : function() {
      return internalArray.length;
   },
   clear : function() {
      for (var i = 0; i < internalArray.length; i++) {
         internalArray[i] = null;
      }
+      internalArray.length = 0;
   },
   contains : function(o) {
      for (var i = 0; i < internalArray.length; i++) {
         if (internalArray[i] == o) {
            return true;
         } else {
-            return false;
         }
      }
+      return false;
   },
   remove : function(i) {
-      internalArray[i] = null;
+      internalArray.splice(i, 1);
   },
   set : function(i, o) {
      internalArray[i] = o;
   },
   clone: function() {
      var arr = internalArray.splice(0);
      return arr;
   }
};
11  Discussions / General Discussions / Re: JGO server folded in on itself on: 2016-01-20 16:22:30
JGO became unreachable for about 2 hours because my ISPs nameserver stopped responding to queries.

I have created a spiffy twitter account, @JavaGamingOrg, which you guys can monitor in case the regular means of communication fail.

12  Game Development / Newbie & Debugging Questions / Re: 3D AABB Collision on: 2016-01-20 08:27:19
Physically correct collision of two axis aligned boxes rarely results in two axis aligned boxes. This basically boils down to how realistic you want your collision response to be.
13  Games Center / WIP games, tools & toy projects / Re: Vangard on: 2016-01-19 18:52:44
In the real world, no-one has ever balanced an economy. So, good luck to me!
I'd argue the opposite: 7 billion minds (and the forces of nature) are constantly balancing the economy. Good luck to you indeed!
14  Games Center / WIP games, tools & toy projects / Re: Pong in Java on: 2016-01-19 15:07:47
Welcome on the forums! Pointing

 - You double-posted your entry on the forum. This is a bit frowned upon Smiley
 - Please don't create topics in 'featured games' as mods will handpick game topics and move them to that board.
 - I moved your 2nd topic to the 'work in progress / toy projects' board, which was more suited.

Could you please add a screenshot of your game to the first message in the topic, so we can get a feel for the game you published?
15  Game Development / Game Play & Game Design / Re: Risk design on: 2016-01-18 08:17:05
I am assuming you are referring to the board game "Risk". Is that correct? If so are there licensing issues?

Yes, I mean Risk board game! About licensing issues, there is already another implementation in java here: http://domination.sourceforge.net/ they just call it domination, so there is no copyright issue
There certainly is a copyright issue with that game. It's the reason not a single world-map (predefined or provided by the community) may have the exact same countries per continent as the original game.
16  Game Development / Newbie & Debugging Questions / Re: What type of rendering should I use? on: 2016-01-18 06:44:52
I think KaiHHs point is exactly your point, but simply one level of abstraction higher:

Quote
Vulkan Shader-based rendering is far from a replacement to OpenGL the fixed-function-pipeline. It is an alternative that trades complexity for CPU performance, and OpenGL the fixed-function-pipeline will keep on getting updates and live on. I wouldn't recommend people who aren't seriously interested in graphics programming to dive into Vulkan shader-based rendering,

Just like fixed-function-pipelines piggybacks on shaders, so will OpenGL on Vulkan, eventually.

You can reiterate the above statement with increasing abstraction, until you arrive at libraries like Slick and LibGDX and engines like Unity, or (browser based) environments like Processing, to digital images, and finally to Polaroid. Wink
17  Game Development / Newbie & Debugging Questions / Re: Can't get a simple Vertex Array to work! on: 2016-01-17 22:10:38
@KaiHH: I prefer <<2 over *4, as it immediately shows we are bitshifting from ints/floats to bytes, whereas *4 can have any meaning (are we working with an attribute with 4 elements?). IMHO it helps to create this convention of using bit shifts to go from one primitive width to another.
18  Game Development / Newbie & Debugging Questions / Re: What type of rendering should I use? on: 2016-01-17 18:13:05
And that, kids, is why you should use a game-engine, not write one.
19  Discussions / General Discussions / Re: JGO server folded in on itself on: 2016-01-15 08:40:46
07:52 AM: Cloning JGO instance to new VM.
...
08:08 AM: java-gaming.org does not work, www.java-gaming.org does work - there seems to be some virtualhost issue
...
11:55 AM: solved virtualhost issue: despite the configuration being explicit and correct, apache2 decided that the java-gaming.org hostname became the default, and hence was routed to /var/www, which contained only an index.html with: '<h1>It works!</h1>'.

Open issues:
 - why did apache2 change its interpretation of defined virtualhosts

Just to be sure:
Are you sure you enabled the apache config before you changed it? You moved to a new VM, so you would have to (re-)enable the config before (re)starting apache.

The config was alright. It had survived a handful of reboots already. To be honest, I'm not sure what 're-enable the config' means. Without a config, not a single virtualhost would have been loaded, and none of the websites would have worked. Anyhoo, I went through quite a bit trial and error, and determined that basically every single change worked (even changing the main ServerName to xyz.java-gaming.org), except... java-gaming.org. Then I ran
apachectl -S
and noticed java-gaming.org was picked up as default (whether it was the first or last virtualhost defined in apache2.conf...), and (as said) rerouted to /var/www/.
20  Discussions / General Discussions / Re: JGO server folded in on itself on: 2016-01-14 19:55:32
#1 complaint after downtime of any website is lack of details Pointing
21  Java Game APIs & Engines / OpenGL Development / Re: Global Illumination via Voxel Cone Tracing in LWJGL on: 2016-01-14 05:53:59
postimg.org is quite insidious. every direct link to an image eventually turns into an HTML page with a new direct link to the image... Please use imgur.com instead.
22  Discussions / General Discussions / Re: JGO server folded in on itself on: 2016-01-13 21:52:18
Heh, that's the first place I looked. Nothing suspicious, just the usual jibber jabber. Emo
23  Discussions / General Discussions / Re: JGO server folded in on itself on: 2016-01-13 18:22:37
Is there some (reliable!) app that scans through your text-messages and triggers an alarm upon a pattern match?

This one seems pretty decent...
   https://play.google.com/store/apps/details?id=ax.ha.it.smsalarm

So far it seems to work, survives a reboot, ignores audio-levels/mutes. It's a shame the Pingdom app (which had an alarm set) didn't trigger... yet the text-message from Pingdom was received.
Anybody any experience with the above app (or similar apps)?
24  Discussions / Miscellaneous Topics / Re: What I did today on: 2016-01-13 11:50:22
Tried an experiment last night - I'm seeing how advertising on JGO will affect my Headline Benchmark site traffic. So far I'm winning bids on EU and US airtime.
It's dirty cheap! $0.05 / day for an exclusive slot!
25  Discussions / General Discussions / JGO server folded in on itself on: 2016-01-13 11:23:52
In the eternal quest of figuring out why the JGO server keeps pulling the rug from under itself, the VM managed to hide its tracks surprisingly well, in an unforeseen self-inflicted denial of service attack.

10.30 PM: Arrived home from work in Belgium.
11.00 PM: I went to bed.
11.30 PM: The daily backup was made.
11.55 PM: VM instance collapsed, unreachable (no ping, no http, no ssh), constant 100% CPU usage, no disk I/O, no network I/O.
11:56 PM: Pingdom sends me down-notification texts
07:30 AM: alarm clock wakes me from my slumber
07:31 AM: I see 2 texts from Pingdom... I notice JGO is actually down
07:33 AM: VM is in lockdown, cannot even login with KVM
07:40 AM: Ensure we have backups, reboot into rescue mode.
07:42 AM: Trying to mount virtual disk, turns out to be corrupted, repairable though.
07:52 AM: Cloning JGO instance to new VM.
07:53 AM: Cloned instance has mountable disk, at least last-minute data is safe.
07:55 AM: Rolling back backup on original instance.
08:00 AM: Jumped in the shower, f**king cold - boiler gave up due to low water pressure... is there a leak? Who gives a shit! No time!
08:07 AM: (short shower...) JGO backup restored, live.
08:08 AM: java-gaming.org does not work, www.java-gaming.org does work - there seems to be some virtualhost issue
08:25 AM: off to work.
09:25 AM: working... (arrived damn late)
11:55 AM: solved virtualhost issue: despite the configuration being explicit and correct, apache2 decided that the java-gaming.org hostname became the default, and hence was routed to /var/www, which contained only an index.html with: '<h1>It works!</h1>'.

1  
2  
3  
4  
5  
6  
7  
8  
<VirtualHost *:80>
    ServerAdmin webmaster@java-gaming.org
    DocumentRoot "/home/jgo/public_html/"
   ServerName java-gaming.org // ignored
    ServerAlias pastebin.java-gaming.org www.java-gaming.org
    ErrorLog "/home/jgo/log/apache2/java-gaming.org-error_log"
    CustomLog "/home/jgo/log/apache2/java-gaming.org-access_log" common
</VirtualHost>


1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
// added dummy domain to trigger apache2 to use as 000-default
+ ServerAdmin default@default.com
+ DocumentRoot /home/websites/domains/default/
+ ServerName default

<VirtualHost *:80>
    ServerAdmin webmaster@java-gaming.org
    DocumentRoot "/home/jgo/public_html/"
    ServerName java-gaming.org
    ServerAlias pastebin.java-gaming.org www.java-gaming.org
    ErrorLog "/home/jgo/log/apache2/java-gaming.org-error_log"
    CustomLog "/home/jgo/log/apache2/java-gaming.org-access_log" common
</VirtualHost>



Open issues:
 - what happened at: 11.55 PM
 - why did apache2 change its interpretation of defined virtualhosts
26  Java Game APIs & Engines / OpenGL Development / Re: Global Illumination via Voxel Cone Tracing in LWJGL on: 2016-01-12 19:40:43
The second image isn't loading, but... Damn! Looks good!
What's strange for me is that none of these pictures are showing up and there isn't even any indication that there's anything I'm missing (no empty box or anything...just whitespace like a text only post)
It's because even though the URL ends with .jpg, the http-response is actually HTML, which contains an img-tag to http://s14.postimg.org/azy70ypnz/vct_arealight.jpg

27  Discussions / Miscellaneous Topics / Re: Starcraft 2 on an Atom Z3775 or Celeron N3150? on: 2016-01-07 20:25:24
Consider buying a 2nd hand laptop. It will be much faster and much cheaper. Why buy new when you are basically aiming for old tech. The only thing left to do would be to replace the HDD with an SSD, and to buy a new battery.
28  Discussions / Miscellaneous Topics / Re: Realistic graphics -- how can it be achieved? on: 2016-01-02 17:47:50
Roquen != Riven persecutioncomplex
29  Discussions / Miscellaneous Topics / Re: Linode has been getting rekt the past few days on: 2016-01-02 01:45:01
JGO is hosted in London, but stability has been pretty spotty this week. It seems to be the network infrastructure though, as I get down reports (downtime being 2-4 hours!) from the USA, while I can still browse JGO from Europe.
30  Discussions / Miscellaneous Topics / Re: What I did today on: 2016-01-01 20:42:29
Safety Third. Pointing

I was never in any danger guys. I am so careful with these things that even if I'd suddenly lost consciousness whilst on the roof, and dropped like a ragdoll, nothing would have happened, as I had myself tied to a 1920 era solid chimney, with only a few loose bricks, mostly held together by gravity, crumbly when leaned against, impervious to anything but water since the early 1960's. So only if my supposedly unconscious zombie mind would have decided to actively leap off the roof, no longer capable of suppressing the urge for brainz - taking with me the glorious masonry - I would've been in serious trouble.
Pages: [1] 2 3 ... 302
 
KaiHH (154 views)
2016-01-31 23:15:29

sci4me (156 views)
2016-01-23 21:47:05

sci4me (139 views)
2016-01-23 21:46:58

KaiHH (173 views)
2016-01-19 13:26:42

theagentd (258 views)
2016-01-05 17:10:00

ClaasJG (275 views)
2016-01-03 16:58:36

chrisdalke (263 views)
2015-12-28 06:31:21

Guerra2442 (273 views)
2015-12-25 03:42:55

Guerra2442 (273 views)
2015-12-25 03:27:21

theagentd (298 views)
2015-12-21 14:43:24
List of Learning Resources
by SilverTiger
2016-02-05 09:39:47

List of Learning Resources
by SilverTiger
2016-02-05 09:38:38

List of Learning Resources
by SilverTiger
2016-02-05 09:35:50

Rendering resources
by Roquen
2015-11-13 14:37:59

Rendering resources
by Roquen
2015-11-13 14:36:58

Math: Resources
by Roquen
2015-10-22 07:46:10

Networking Resources
by Roquen
2015-10-16 07:12:30

Rendering resources
by Roquen
2015-10-15 07:40:48
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!