r/processing • • Jan 01 '16

Help plz

Hello processing,

If some one could help that would be nice.

I am currently trying to make a program that does this but at random positions after a set number of turns.

[This is currently my try at creating it but.....] (http://www.openprocessing.org/sketch/285819)

as you can see its not doing what the original was.

0 Upvotes

12 comments sorted by

1

u/forgotmyusernamedamm Jan 02 '16

I would create two global variable for the x and y location of the center of the spiral. Then replace the line
translate(random(500), random(500)); with
translate(x,y);
After 50 cycles set the x and y values to a random number.

1

u/gmantsang Jan 02 '16

THANKS :D

I figured it out with your tips.

also since processing.org is down right now I wanted to ask you.

How would I make the program full screen

2

u/forgotmyusernamedamm Jan 02 '16

size(displayWidth, displayHeight);
Then either export as an application, or "present" instead of play.

1

u/gmantsang Jan 02 '16

thanks for trying but another gave a better command :D.

up voted anyways

1

u/otterfamily Jan 03 '16

displayWidth and displayHeight are deprecated in Processing 3.0

use fullScreen();

1

u/forgotmyusernamedamm Jan 03 '16

You're right that fullScreen is the future, but technically displayWidth, displayHeight still works.

1

u/otterfamily Jan 03 '16

Oh does it still? I know it doesn't accept variables for width and height. I tried to use a PImages dimensions the other day and it wasn't having it. Though I guess displayHeight at the very least is static

2

u/otterfamily Jan 02 '16

Processing 3.0 added fullScreen();

Also use the reference. You don't need an internet connection to check it. Help->reference in processing ide opens from local.

1

u/gmantsang Jan 02 '16

THANKS

also that is another helpful tip..

1

u/gmantsang Jan 03 '16

does it matter that im on mac?

1

u/otterfamily Jan 03 '16 edited Jan 03 '16

Html is html independent of OS

1

u/gmantsang Jan 03 '16

thanks im dumb :P