[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/db/driver/mysqli.php on line 264: mysqli_fetch_assoc(): Couldn't fetch mysqli_result [phpBB Debug] PHP Warning: in file [ROOT]/phpbb/db/driver/mysqli.php on line 326: mysqli_free_result(): Couldn't fetch mysqli_result [phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4149: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3027) [phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4149: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3027) [phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4149: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3027) [phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4149: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3027) How do you make a line without the line command? - Pete's QBASIC Site
I've been trying to figure out how to recreate the line command in Qbasic for a while now but I've been failing at it. I've also googled for this too but it turns up useless results that all use a line command of some sort.
how do you make a line from point(x,y) to point(x2,y2) with out the line command?
dim x,y,tilt as double
dim i as integer
randomize timer
screen 13
const Xres=320 'Setup the resolution for 13h
const Yres=200
x=Xres/2 'Set up the line so
y=Yres/2 ' it is in the center
tilt=rnd*6.2899 'random tilt (6.2899 is the max tilt it seems)
for i=0 to 100 'plot outward 100 steps
x=x+cos(tilt) 'The math for X
y=y+sin(tilt) 'The math for Y
pset(x,y),15 'dot
next
sleep -1