Bouncing Text
in
Programming Questions
•
7 months ago
Trying to create a small animation within processing where the tweets will bounce across the page in a walking manner. Anyone know how to achieve this? Here's what I have so far...
class WalkingTweet {
String tweetText;
float x = -50;
int speed = 3;
WalkingTweet(String tempTweetText)
{
//store the tweet text
tweetText = tempTweetText;
println("This is a class speaking: "+ tweetText);
}
void move(){
fill(71, 72, 104);
rect(0, 0, width, height);
fill(255, 255, 255);
textSize(20);
text(tweetText, x, 470);
x += speed;
}
}
1