Copper Bars

Do you have something to share with us? A tip for newbies, perhaps? Post it here.
Post Reply
peter
Active Member
Posts: 123
Joined: Mon Oct 22, 2007 2:31 pm

Copper Bars

Post by peter » Mon Aug 04, 2014 8:15 pm

Hello,

It's very slow. :evil:

Code: Select all

SCREEN 640,480

Global yr
yg=40
yb=80

While keydown(27)=0
For i=0 to 240
    Color i+15,0,0 
    Line 0,i,640,i
    Color 255-i,0,0 
    Line 0,i+240,640,i+240
Next i

Color 255,255,255
Text 240,200,"AMIGA COPPER BAR ?"

RedCopper(yr)
GreenCopper(yg)
BlueCopper(yb)

yr = yr+1
yg = yg-1
yb = yb+1
If yr >=480 Then yr=-64
If yg <=-64 Then yg=480
If yb >=480 Then yb=-64

DrawScreen OFF
Wend
End 

Function RedCopper(y)
For i=64 to 255 Step 10 
    Color i,0,0
    Line 0,y,639,y
    y = y+1
Next i    
For i=255 to 64 Step -10
    Color i,0,0
    Line 0,y,639,y
    y = y+1
Next i
End Function

Function GreenCopper(y)
For i=64 to 255 Step 10 
    Color 0,i,0
    Line 0,y,639,y
    y = y+1
Next i    
For i=255 to 64 Step -10
    Color 0,i,0
    Line 0,y,639,y
    y = y+1
Next i 
End Function

Function BlueCopper(y)
For i=64 to 255 Step 10 
    Color 0,i,i
    Line 0,y,639,y
    y = y+1
Next i   
For i=255 to 64 step -10
    Color 0,i,i
    Line 0,y,639,y
    y = y+1
Next i
End Function

User avatar
CCE
Artist
Artist
Posts: 650
Joined: Mon Aug 27, 2007 9:53 pm

Re: Copper Bars

Post by CCE » Wed Aug 06, 2014 7:21 pm

It isn't too slow here. In any case, you could make it faster by precalculating the bars as images and then just blitting them in correct places.

Nattakiha
Newcomer
Posts: 2
Joined: Fri Apr 10, 2015 7:30 am

Re: Copper Bars

Post by Nattakiha » Fri Apr 10, 2015 7:33 am

The Web site is updated or not.

addseo1118
Newcomer
Posts: 1
Joined: Sat Apr 25, 2015 10:30 am

Re: Copper Bars

Post by addseo1118 » Sat May 16, 2015 6:53 am

;) how about now? Did you update some?

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests