How to draw the way between two points?

  • 2 Replies
  • 2355 Views
How to draw the way between two points?
« on: February 10, 2011, 21:32:36 »
Hello guys, I just encountered a problem about "drawing the way from Point A to Point B".

I tried many ways to do that, changing the angle of a 1 pixel thick bar, looping and drawing 1 pixel until it reaches Point B...

But it doesn't give me the best look / graphics.  :(


Sorry about my English, it is not so good C)

*

Offline AA

  • 510
  • 23
  • Was ITA84
    • View Profile
    • Insight on Videogames
Re: How to draw the way between two points?
« Reply #1 on: February 11, 2011, 08:34:17 »
I assume you're talking about programming: in this case you should mention the programming language (and eventually graphics libraries) you're using.

If by 'it doesn't give me the best look' you mean the line looks jagged, then you should add anti-aliasing. Implementing anti-aliasing from scratch can be hard, depending on the context, which is why you usually rely on external libraries for that (again, these depend on the programming language you chose).
Videogames are for everyone, by everyone

Re: How to draw the way between two points?
« Reply #2 on: March 02, 2011, 00:46:34 »
I am using MMF / Lua with the game right now. Actually I am trying to make the similiar effect with the star system selection in Saira. Now I have the line but cannot animate it...