Java-Gaming.org Hi !
Featured games (81)
games approved by the League of Dukes
Games in Showcase (513)
Games in Android Showcase (119)
games submitted by our members
Games in WIP (576)
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 6342 times)
0 Members and 1 Guest are viewing this topic.
Offline StumpyStrust
« Reply #60 - Posted 2012-12-18 04: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
« League of Dukes »

JGO Kernel


Medals: 136
Projects: 4
Exp: 3 years



« Reply #61 - Posted 2012-12-18 05:00:49 »

lol sorry my screwed up quotes are screwing up your quotes  Grin
Offline wreed12345

JGO Knight


Medals: 25
Projects: 2
Exp: 2 years


http://linebylinecoding.blogspot.com/


« Reply #62 - Posted 2012-12-18 22: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!
Legends of Yore - The Casual Retro Roguelike
Offline ctomni231

JGO Wizard


Medals: 99
Projects: 1
Exp: 7 years


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


« Reply #63 - Posted 2012-12-18 22: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 22:24:29 »

[applet archive=snows.jar class=com.rorkien.snowflakes.GameApplet width=640 height=480]

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

JGO Knight


Medals: 25
Projects: 2
Exp: 2 years


http://linebylinecoding.blogspot.com/


« Reply #65 - Posted 2012-12-19 22: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  
 
 
You cannot reply to this message, because it is very, very old.

 

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

The first screenshot will be displayed as a thumbnail.

Longarmx (41 views)
2014-10-17 03:59:02

Norakomi (33 views)
2014-10-16 15:22:06

Norakomi (26 views)
2014-10-16 15:20:20

lcass (30 views)
2014-10-15 16:18:58

TehJavaDev (60 views)
2014-10-14 00:39:48

TehJavaDev (60 views)
2014-10-14 00:35:47

TehJavaDev (50 views)
2014-10-14 00:32:37

BurntPizza (66 views)
2014-10-11 23:24:42

BurntPizza (38 views)
2014-10-11 23:10:45

BurntPizza (80 views)
2014-10-11 22:30:10
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
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!