Java-Gaming.org Hi !
 Featured games (84) games approved by the League of Dukes Games in Showcase (604) Games in Android Showcase (171) games submitted by our members Games in WIP (653) games currently in development
 News: Read the Java Gaming Resources, or peek at the official Java tutorials
 Show Posts Pages: [1]
 1 Game Development / Game Mechanics / Re: Accelerate and slow down a camera move on: 2011-06-10 08:44:17 Thanks for the piece of code!After some more thought, I came out with the following idea: a "standard" sigmoïd method works, but it is not easy to control tune it. Actually I just would like to build a function that looks like a smoothed stair:1       /-        slow stop|   /-/0-/      1       slow startsatisfying f(0)=0, f(0.5)=0.5 and f(1)=1, and any other constraint letting me say "at T I want the cam to have done distance D". Finally, it seems the best is to "build" the function using an interpolation (I will use bernstein, that works well), where each keypoint represent a D=f(T) constraint. One can really "model" the camera behaviour with details.Cheers,Martin
 2 Game Development / Game Mechanics / Re: Accelerate and slow down a camera move on: 2011-06-08 13:26:09 Hi,Thanks for these suggestions. One thing I forgot to tell: I want to control the LENGTH of each animation. Up to now I check the frame rate before starting any animation, to determine the number of necessary key points required to have the choosen duration. Unless I misunderstood your suggestion, it seems to me that your solutions requires little thinking to determine acceleration and other parameters to control the number of steps.I was thinking about using a function to shifts linear steps: (1) compute the linear interpolation of the n intermediate steps. First and last point make distance D.(2) convert each point to polar, to have a distance information from start.(3) then each point Pi should be at distance= D*i/n from start. (4) For this next step, the best is to normalize in [0;1], so consider distance=i/n. We will update each polar point with:      P.radius = f(P.radius)I thus need a function y=f(x) that gives y=0 for x=0 and y=1 for x=1, and that let me "stretch" the animation timing easily:      f(x)=x^2 makes a simple accelerating move, x^3,4,5 will be more "sharp": slower at the beginning and faster at the end.      f(x)=-(x-1)^2+1 makes the contrary acceleration: fast at the beginning, slow at the end. One must have an even pow value.so I better need a normalized sigmoïd function. I will tell you if I find a good candidate for this method It is a little mangled, but allows to customize speed variation easily! Maybe there are some other more straightforward methods.Cheers,Martin
 3 Game Development / Game Mechanics / Re: Bullet Angles on: 2011-06-08 12:42:36 Hi!I have implemented the method that indicates the full polar coordinate (with angle in [0;2*PI]) of an input coordinate, which could be mouse-bob in your case.Search for Coord2d.fullPolar() here: http://code.google.com/p/jzy3d/source/browse/branches/0.8.1/src/api/org/jzy3d/maths/Coord2d.javaI use it a lot and it works as expected.Cheers,Martin
 4 Game Development / Game Mechanics / Accelerate and slow down a camera move on: 2011-06-08 00:39:34 Hi folks,I have a 2d scene, and do camera moves between two given points by simply defining N equal intermediate steps along the line formed by the start and stop point.I'd like to accelerate at the beginning and slow down at the end. Do you have any suggestions to do that smartly?Cheers,Martin
 5 Java Game APIs & Engines / Engines, Libraries and Tools / A complete 3d API for plotting surfaces, scatters, etc on: 2011-06-08 00:21:07 Hi all,I guess this place is better to advertise than the "shared code" section of this forum:Jzy3d is an open source library that let you easily plot simple 3d for reviewing scientifical data:http://code.google.com/p/jzy3d/Cheers,Martin
 6 Game Development / Shared Code / Re: A complete 3d API for plotting surfaces, scatters, etc on: 2011-06-08 00:16:12 Quote from: gouessej on 2011-04-19 13:25:26jzy3d is an excellent library, it is already used in commercial products. It uses JOGL as a Java binding for OpenGL. It is quite complete and it is not very complicated to use. I hope it will go further in graph rendering and 2D/3D mixing.Thanks for your support! Yes Jzy3d goes further with great new features still under development. Feel free to follow http://twitter.com/#!/jzy3d to get notified on new features.Cheers,Martin
 7 Game Development / Shared Code / Re: A complete 3d API for plotting surfaces, scatters, etc on: 2011-04-19 12:51:38 Mm, I thought it was for graphics, but you're right, we're not on java-graphics.org Cheers,Martin
 8 Game Development / Shared Code / Re: Astar Pathfinding on: 2011-04-19 12:44:16 That's what I did :/I will tell you if I find the reason.Cheers,Martin
 9 Game Development / Shared Code / A complete 3d API for plotting surfaces, scatters, etc on: 2011-04-10 14:58:36 Hi all,First time I see this forum, and I guess it's worth sharing a project with all of you http://code.google.com/p/jzy3d/Cheers,Martin
 10 Game Development / Shared Code / Re: Astar Pathfinding on: 2011-04-10 13:37:16 Hi,When running the applet from the browser, the path does not start after the two clicks.When building and running from sources, the pathfind returns a null path at the following call GridPath aPath = pathfinding.getPath(mouse.getStart(), mouse.getEnd(), draw.getMap());Any suggestion to have the demo running?! It seems great!Cheers Martin
 Pages: [1]
 SHC (27 views) 2015-08-01 03:58:20 Jesse (19 views) 2015-07-29 04:35:27 Riven (40 views) 2015-07-27 16:38:00 Riven (21 views) 2015-07-27 15:35:20 Riven (24 views) 2015-07-27 12:26:13 Riven (14 views) 2015-07-27 12:23:39 BurntPizza (36 views) 2015-07-25 00:14:37 BurntPizza (46 views) 2015-07-24 22:06:39 BurntPizza (30 views) 2015-07-24 06:06:53 NoxInc (37 views) 2015-07-22 22:16:53
 theagentd 52x wessles 49x basil_ 35x KaiHH 26x orangepascal 25x Riven 20x ags1 20x mooman219 17x bornander 15x KudoDEV 13x princec 11x Jesse 11x CelestialCreator 11x klaus 10x pquiring 10x Spasi 8x
 List of Learning Resourcesby gouessej2015-07-09 11:29:36How Do I Expand My Game?by bashfrog2015-06-14 11:34:43List of Learning Resources2015-05-31 05:37:30Intersection Methodsby Roquen2015-05-29 08:19:33List of Learning Resources2015-05-05 10:20:32How to: JGO Wikiby Mac702015-02-17 20:56:162D Dynamic Lighting2015-01-01 20:25:42How do I start Java Game Development?by gouessej2014-12-27 19:41:21
 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