TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
jawad
NA
9
8.8k
Car on a track
Aug 18 2011 8:28 PM
Hello everyone,
i was searching in a lot of places and pages for how to make a texture follow a track in XNA gaming studio, i found some articles about making points on the screen and make the texture pass between them using the "Vector2.lerp(start, end, speed)" ;
i made those points, wrote down the functions, and putted nested loop.
i.e.
player.lerp(pointA,pointB,speed);
if(//player get to the pointB)
// set pointB as starting point and pointC as end point
// and so on...
but the result that i got is that the texture doesn't stop moving or change direction, it continue moving according to the first given values, in another words, if in the first outer loop i was incrementing the value of "Y" and incrementing the value of "X" in the second loop, the texture's "Y" keep changing but nothing for the "X".
if somebody can help me with that, i would be more than thankful and happy
thanks in advance
Reply
Answers (
2
)
XACT - Play, Stop then Play a Cue
Reducing repetitive asset loading