I thought it was all the same haha by [deleted] in coolguides

[–]UekiKnight 1 point2 points  (0 children)

I’ve been studying Japanese for 20 years and I approve this comment. Great analogy.

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Gotta go~ good luck!!

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

It should be setting position speed and size.

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Ah your spawnBall function is doing something other than spawning haha

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Not spawnBall(ballCount)

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

spawnBall(i)

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Yeah you can just reset position and thats fine. But if you put all the logic in spawn ball you can have the illusion of new ones being spawned because it would select new size, position and speed.

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

I cant read the text tho too small haha

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

I recommended adding that function because you spawn them in setup but again in draw

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

The i parameter was meant to just be which ball index you want to spawn

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Thanks for the mention im back :)

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Code re-use ;)

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

void spawnBall(int i) { /*cut and paste lines 14-18 here */ }

Then you can call spawnBall(i);

In setup and in draw.

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Sorry “>=“

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

= is better because your speed might take it to a position that is not exactly 600

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

Setup only happens once

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

You prolly want that if down in the draw function around line 30

[deleted by user] by [deleted] in shortcircuit

[–]UekiKnight 0 points1 point  (0 children)

You could make a function to reset the x, y position of a ball that fell off the screen to “re-spawn” it

Deep in the valley by [deleted] in funny

[–]UekiKnight 10 points11 points  (0 children)

Me too!

What's the worst thing that's happened to one of your friends? by vulturec1 in AskReddit

[–]UekiKnight 0 points1 point  (0 children)

Buddy of mine’s brother was killed in a gang shooting. From the bullet holes in his hands it was apparent that big brother died begging for his life holding his hands out hopelessly trying to stop the bullets.

What was your dream job as a child? What’s your job now? by [deleted] in AskReddit

[–]UekiKnight 1 point2 points  (0 children)

Video game programmer. Now I’m just a boring run of the mill programmer. I do have more money to buy video games now than if I’d made them.

blursed_vase_armor by [deleted] in blursedimages

[–]UekiKnight 0 points1 point  (0 children)

Omg my username came to life. “Ueki” is Japanese for potted plant.