123
-=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- (c) WidthPadding Industries 1987 0|633|0 -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=-
Socoder -> On Topic -> Speedometer.

Mon, 28 Apr 2008, 12:00
DrOnuki
How do I implement a graphical speedometer into my game? I don't have a problem with making it, but the problem is I don't know how to implement it, do I need a sprite sheet?

Thanks!

-=-=-
zzzzzzzzzzzzzzz
Mon, 28 Apr 2008, 12:52
Jayenkai
Tricky if you're using Blitz, and a wide variety of difficulties in other languages, too.

If you want a circular one, it's going to be hard.
The easiest thing I can think of is to draw a background circular image, then draw a few lines over the top, which start thick in the middle, and end up at a point at the edge..


At work, so can't double check, but it should be something to that effect!!


-=-=-
''Load, Next List!''
Mon, 28 Apr 2008, 14:36
Forklift_Fred
Very crude but demonstrative...



Replace the Oval with your own background image, scale the speed as necessary, etc. The 120 is added to the Cos() and Sin() to start the zero speed at the 7 o'clock position rather than 3 o'clock. If you want to use a semicircle display then set it to 180.

It's a starting point at least

-=-=-
Come rain or shine...