how can i make an image follow an intricate path. This is for a video game just saying. Currently i am using this code but it only makes it go right for about 200 pixels then back left for 200 and this goes in a loop. How can I make this more intricate?
homelessX is the x position of the image
if(go == true){
homelessX += .04f;
if(homelessX > 800){
go = false;
}
}
if(go == false){
homelessX -= .04f;
if(homelessX < 600){
go = true;
}
}