Java-Gaming.org
Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
Featured games (78)
games approved by the League of Dukes
Games in Showcase (406)
games submitted by our members
Games in WIP (293)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: 1 2 [3]
  ignore  |  Print  
  Wavy lines in java?  (Read 3005 times)
0 Members and 1 Guest are viewing this topic.
Offline StumpyStrust
« Reply #60 - Posted 2012-12-18 05:50:01 »


He's using parallax (I think) which you probably shouldn't be worrying about.
Quote from: wreed12345
[/quote

Not parallax. Basically, take the snowflake class and drop the sine and spawn a bunch of them with random velocities. And all with a random small gravity pulling them down. That is the basic idea of particles which are simply to start with but hard to get looking good.

If you would like I can give you the source but it might be a bit much.
Offline Jimmt
« Reply #61 - Posted 2012-12-18 06:00:49 »

lol sorry my screwed up quotes are screwing up your quotes  Grin
Offline wreed12345
« Reply #62 - Posted 2012-12-18 23:05:05 »

Oops... my mistake. Let me fix all the errors in that post. I didn't actually test it out as I meant it for an example, but since you want to use it, I'll be more thorough.
Hey thanks for fixing it but I think there might be a problem or Im not understanding something correctly. After I call the snowflake method, do I also have to call the fall and fall random, etc methods with it? I dont see how else this could work, and I know I sound like a newb cause I am one lol
Games published by our own members! Check 'em out!
Try the Free Demo of Titan Attacks
Offline ctomni231

JGO Knight


Medals: 28
Projects: 1


Not a glitch. Just have a lil' pixelexia...


« Reply #63 - Posted 2012-12-18 23:14:34 »

Yup, each method will cause the snowflake to fall in a certain pattern if called repetitively. If you want to have your snowflake follow random movements, you'll need to randomize how you call each of those functions. Each snowflake you make can follow different patterns depending on how you call the functions.
Offline Rorkien
« Reply #64 - Posted 2012-12-19 23:24:29 »

Warning! Untrusted content: Rorkien submitted an applet to JGO.


 
If the applet asks for permissions, it will have full access to your system. (read more)
JGO cannot be held responsible for the contents and/or behavior of the hosted applets.


Ok, here's the code i have shown earlier, with some art added  Stare

EDIT: And here's the source: http://www.mediafire.com/?305bspdv3ybj548
Offline wreed12345
« Reply #65 - Posted 2012-12-19 23:34:44 »

If you dont mind could I have the source code for that? Smiley i learn better with examples
Pages: 1 2 [3]
  ignore  |  Print  
 
 

Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
 
Get high quality music tracks for your game!

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

The first screenshot will be displayed as a thumbnail.

The invasion has landed! On Mars! And you're there to beat 'em!
cubemaster21 (72 views)
2013-05-17 21:29:12

alaslipknot (83 views)
2013-05-16 21:24:48

gouessej (113 views)
2013-05-16 00:53:38

gouessej (108 views)
2013-05-16 00:17:58

theagentd (119 views)
2013-05-15 15:01:13

theagentd (108 views)
2013-05-15 15:00:54

StreetDoggy (153 views)
2013-05-14 15:56:26

kutucuk (176 views)
2013-05-12 17:10:36

kutucuk (173 views)
2013-05-12 15:36:09

UnluckyDevil (182 views)
2013-05-12 05:09:57
Complex number cookbook
by Roquen
2013-04-24 12:47:31

2D Dynamic Lighting
by Oskuro
2013-04-17 16:46:12

2D Dynamic Lighting
by Oskuro
2013-04-17 16:45:57

2D Dynamic Lighting
by Oskuro
2013-04-17 16:23:20

Noise (bandpassed white)
by Roquen
2013-04-05 17:36:01

Noise (bandpassed white)
by Roquen
2013-04-03 16:17:38

Java Data structures
by Roquen
2013-03-29 13:21:12

Topic Request
by kutucuk
2013-03-22 21:42:01
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!
Page created in 0.084 seconds with 20 queries.