Making multiple lines move

Hello there! (First time poster)

Im currently on my second week of a programming course and as one of our first assignment we were supposed to write our name/gamertag on Processing with different lines and shapes. Easy enough I managed to do this. On the other hand I looked at the “extra” assignment for more experienced programmers where you were supposed to make your name animated aswell. I got the idea that I wanted to make my whole name bounce around the screen but have no idea where to start. I kind off know how to animate single lines and shapes in different directions but when it comes to multiple lines and shapes im completely stuck. I had the idea that maybe I could put all the lines and shapes that my name consist of ijn the code under one class or similar and then code it so it moves all together.

I will link my Github-profile where u can find my code under my “Processing”-repository.

Thanks in advance!

This will help you a lot. At least, it will allow you to move the lines that make up your letters as a group…

1 Like

One resource that you should explore to get some ideas is this:

For instance:

This above might help you as it shows how to manipulate position over time. It can be more in the advanced side if you do not know about classes and OOP.



I’ve read through this tutorial so many times now and Im still stuck. I think I will just wait until I get to class tomorrow and ask my teacher since I have no clue what im doing. But thanks anyways for the link!

Imagine you had your name written on a piece of paper, and there was a checkerboard you wanted to move it around on. If you were yelling instructions to me (draw), and I needed to move your name around the checkerboard, what is the minimum information you would need to tell me so that I could move your name to where you want it?

A nice way to do first-time learning with motion is to start with mouseX, mouseY and make your graphics manually interactive – move them around with your hand by moving the mouse. Then substitute other variables for the mouse, and figure out how to update those variables – for example, a bouncing ball.