Qbasicnews.com
Challenge.... - Printable Version

+- Qbasicnews.com (http://qbasicnews.com/newforum)
+-- Forum: QbasicNews.Com (http://qbasicnews.com/newforum/forum-3.html)
+--- Forum: Challenges (http://qbasicnews.com/newforum/forum-10.html)
+--- Thread: Challenge.... (/thread-93.html)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22


Challenge.... - Mango - 05-27-2003

try this one...I lifted the idea...from a 27 line prog I found on the net...

Code:
1 if g = 0 then SCREEN 12 else rot = rot + .1
2 rot2 = rot2 + .1 + .2 * p
3 FOR g = -8 TO 8
4 IF rot2 > 25.1 OR rot2 < 0 THEN p = NOT p ELSE CIRCLE ((320 + 10 * rot2 * SIN(1 * rot)) + ((9 - ABS(g)) * SGN(g) * 6) * SIN(rot), (350 + 10 * SIN(1 * rot)) + (((9 - ABS(g)) * SGN(g) * 2) + 4) * SIN(rot)), 9 - ABS(g), ABS(14 - 4 * ABS(g))
5 CIRCLE ((160) + ((9 - ABS(g)) * SGN(g) * 10) * COS(rot), (400 + -30 * SIN(1 * rot)) + (((9 - ABS(g)) * SGN(g) * 2) + 4) * SIN(rot)), 9 - ABS(g), 1 + ABS(g)
6 CIRCLE ((480) + ((9 - ABS(g)) * SGN(g) * 10) * COS(rot), (400 + 30 * SIN(1 * rot)) + (((9 - ABS(g)) * SGN(g) * 2) + 4) * SIN(rot)), 9 - ABS(g), 1 + ABS(g)
7 NEXT g
8 IF INKEY$ = "" THEN PRINT  ELSE END
9 GOTO 1



Challenge.... - toonski84 - 05-27-2003

hey mango, no problem. change the first line to this

Code:
1 if g = 0 then screen 12 else rot = rot + .1



Challenge.... - Mango - 05-27-2003

Quote:hey mango, no problem. change the first line to this

Code:
1 if g = 0 then screen 12 else rot = rot + .1

Thanks toonski...I couldn't figure it out...the solution was so obvious. I didn't want to lose a 3d thingie and couldn't see a way to keep all 3 plus have the center one wobble without getting rid of the screen line.

What'd you think of the graphic?

There's a bug that I can't fix as a 9-liner...at the min and max of the wobble (where (p) goes to (NOT p)) the center rotor doesn't show...it only shows up as 1/250 cycles, so it's not that distracting...do you see a way to do line 4 so that I can still do the comparison while and still printing the circle?


Challenge.... - toonski84 - 05-27-2003

it looked fine to me, it was pretty cool, reminded me of a dna pattern.


Challenge.... - oracle - 05-27-2003

Yeah, the DNA was cool.

Toonski: Line 8:
Code:
WAIT &H3DA, 8
is a little better than your count-delay :wink:


Challenge.... - toonski84 - 05-27-2003

i was afraid to test it in text mode *tests* yeah, it's too fast on mine.


Challenge.... - relsoft - 05-27-2003

Quote:
relsoft Wrote:*Tries to think of new gfx fx.......

Please, Mr. Rel. Please use your valuable time in those people who're still waiting for your slice of the cake. Quite a few. You know.[Image: eviltongue.gif]

*muffled voice* Joe! It's your turn now!

Okay, okay... I won't enter any fx here until I put sumthing in the bunker.

These 9 liners nearly killed RelLib. :*)