This site requires JavaScript, please enable it in your browser!
Greenfoot back
Dudeson
Dudeson wrote ...

2015/4/27

How to make camera slowly fallow actor

Dudeson Dudeson

2015/4/27

#
Hello so I have another question . So as you see in the picture, star has it's own coordinates same as camera. All I want to know is to find out how to make camera move toward star new location , but not rapidly slowly as 5px/s. I would really appreciate if some one could show me how to do it.Plus i would like to have code for camera moving code . I have tried to do so with "scrolling world" scenario that has degrees and other stuff that i can't me it work as i want to . I need camera to fallow up , left and right. waiting for answer, thanks!
Super_Hippo Super_Hippo

2015/4/27

#
You will compare the star coordinates with the camera coordinates and if they aren't same, the camera will move towards the star.
Dudeson Dudeson

2015/4/27

#
Super_Hippo wrote...
You will compare the star coordinates with the camera coordinates and if they aren't same, the camera will move towards the star.
I under stand that my self , but can get code to work , I mean camera code don't work as I want to.
Super_Hippo Super_Hippo

2015/4/27

#
I can't correct your code without seeing what you tried.
You need to login to post a reply.