LZ: graphical question


[Prev][Next][Index][Thread]

LZ: graphical question



Not sure who out there will answer these questions but here it goes.
Thanks to all out there who sent me ideas on how to dezign an algorithm
for drawing the side of the road in the racing game I'm working on. I
played with the idea
y=(x^2)/(4*p)
and changed it to....


y=((x+b)^2)/(-4*c) 
where b moves the parabola left and right and c stretches or compresses
it. Well i have found depending on the value of b the value of c does not
increase or decrease linearly. I think it might be varying parabolically
as well but am not sure and don't really want to play around with this
equation. Besides, I have found good enough increasing variable to make
this only be off a pixel or too in middle turns and that really won't
effect the game at all.
	My next problem it not a problem at all. I was wondering what the
fastest way to graph the two lines would be. I could go through all x
values and y valeus for one line and then for the other. That would be
under 63+127+127+63 so under 380 numbers. 400 numbers shouldn't take too
long....right? Well any suggestions on methods to graph it would be
appreaciated. I can't acces the graphing functions on the rom anyway can
I?
	Also, I have to determine a way to only draw on one side of the
vertex, not both. I'm not drawing U turns. maybe that could be a variable
(the vertex represented by x=somthing) and the program referes to that
point and the magnitude of the turn (1-5 left, 6-10 right, you get the
idea) to determine which side of the vertex to draw it. Any suggestions
appreciated.
	Finally, I have three pictures drawn of the car. They are small,
under 20 pixels each. I don't think I should have to use sprites for
these. Besdies, I have never used sprites before anyway.
	one more important thing. I plan on incorporating the cource into
a matrix that has been precreated. How do I do this? In other words, could
anybody out there specifically tell me how to:
(a.) put the matrix with all of it's values, simple ones ranging from 1 to
40, at the bottom of the program where one puts .db "junk" strings.
(b.) depending on variable "HERE" access the appropriate value in the one
dimentional matrix.
(c.) alter a value in the matrix but placing the value of "THIS" into
place "HERE"


Help on this last question  is not as important right now since I have to
get the graphical stuff working first but any help on any of this stuff
would be great.
	Thanx,
	Will Stokes
 
**************************************************************************
*                   Will Stokes		         *                 *     *
*        wstokes@vertex.ucls.uchicago.edu      	 *  Comment of the * : ) *
*      						 *  times:         *     *
*              My Personal Homepage		 *                 * : ( *
*     http://www.uic.edu/~hhstokes/will.htm 	 *******************     *
*						 *                 * . | *
*           The TI-85 Calculator Center		 *  Vote Dole and  *     *
* (the website I maintain and update very ofter) *  Kemp in 1996!  * : o *
*          http://www.uic.edu/~hhstokes/	 *                 *     *
*						 *                 *     *
**************************************************************************
*									 *
*  Happy, Sad, missing and eye and supprised. ------------------------^  *
*									 *
**************************************************************************