### Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Pages: [1] 2 3 4 5 6 7 8
1
##### Yabasic / scrolling title display
« on: March 05, 2019 »
Simple stand-alone scroll.

Code: [Select]
`open window 640,512restore bodypartsread bodiesdim parts\$(bodies)dim prices(bodies)dim listed(bodies)for a=1 to bodiesread parts\$(a)read prices(a)read listed(a)next arow=1repeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowc=peek("port1")row1=0if and(c,16)<>0 up=1if up=1 u=u+1if u>2 u=2if u=2 up=0if and(c,16)=0 u=0if and(c,64)<>0 down=1if down=1 d=d+1if d>2 d=2if d=2 down=0if and(c,64)=0 d=0if up=1 row=row-1if down=1 row=row+1if row<1 row=1if row>bodies row=bodiesfor a=1 to bodiesif row=a text 20,180,parts\$(a)if row=a thensetrgb 1,0,256,0elsesetrgb 1,256,256,256endiftext 100,a*15-(row*15-15)+165,parts\$(a)text 180,a*15+165,parts\$(a)next asetrgb 1,256,256,256for a=1 to bodiesif row=a thenspace=20elsespace=0endiftext 260+space,a*15+165,parts\$(a)next afor a=1 to bodiesif row=a text 340,a*15+165,">"text 350,a*15+165,parts\$(a)next afor a=1 to bodiesif row=a thentext 430,180,parts\$(a)elserow1=row1+1text 430,row1*15+200,parts\$(a)endifnext auntil (1=0)label bodypartsdata 10data "hand",7,1data "mouth",10,1data "ear",4,1data "leg",9,1data "arm",2,1data "chest",3,0data "elbow",5,0data "knee",8,0data "ankle",1,0data "eye",6,0`
have a yahappy day[/code]

2
##### Yabasic / Letter Colour Assign
« on: July 08, 2018 »
Just something I've wanted to achieve.
An idea I wanted to apply to another program here.

Code: [Select]
`restore wishlistread listdim wish\$(list)for a=1 to listread wish\$(a)next arestore highlightread colsdim letters\$(cols)dim R(cols)dim G(cols)dim B(cols)for c=1 to colsread letters\$(c)read R(c)read G(c)read B(c)next csel=1open window 640,512repeatsetdispbuf vmvm=1-vmsetdrawbuf vmclear windowletter=0row=0c=peek("port1")if and(c,16)>0 scroll=scroll+15if and(c,64)>0 scroll=scroll-15if scroll>0 scroll=0if and(c,128)<>0 left=1if left=1 L=L+1if L>2 L=2if L=2 left=0if and(c,128)=0 L=0if left=1 sel=sel-1if sel<1 sel=3for a=1 to listspace=260/len(wish\$(a))if instr(wish\$(a),"*",0)=0 thenrow=row+1for b=1 to len(wish\$(a))for c=1 to colsif mid\$(wish\$(a),b,1)=letters\$(c) thenletter=letter+1setrgb 1,R(c),G(c),B(c)endifnext cif sel=1 text b*10+10,row*15+scroll,mid\$(wish\$(a),b,1)if sel=2 text b*10-(len(wish\$(a))*10)+260,row*15+scroll,mid\$(wish\$(a),b,1)if sel=3 text b*space,row*15+scroll,mid\$(wish\$(a),b,1)next bendifnext asetrgb 1,256,256,256text 10,(row+1)*15+scroll,"The "+str\$(row)+" listed are the ones I"text 10,(row+2)*15+scroll,"have of the "+str\$(maxnum)+" in my wishlist"text 10,(row+3)*15+scroll,str\$(letter)until (1=0)label wishlistdata 94data "A QUIET PLACE"data "*ACTS OF VIOLENCE"data "AMERICAN PASTORAL"data "ATLANTIC RIM RESURRECTION"data "AVENGERS INFINITY WAR"data "*BALLAD OF LEFTY BROWN. THE"data "*BEAST OF BURDEN"data "*BLACK PANTHER"data "*BRAVEN"data "*BREATHE"data "BROKEN"data "*BUTTERFLIES ARE FREE"data "BUTTERFLY TREE"data "CALL ME BY YOUR NAME"data "CHAOS"data "CHAPPAQUIDDICK"data "CIRCLE OF TWO"data "CITY OF GHOSTS"data "COCAINE GODMOTHER"data "COLD MOON"data "COMMANDO"data "*COMMUTOR. THE"data "DEVIL IN A BLUE DRESS"data "*DOCTOR DETROIT"data "ENDLESS. THE"data "EVERY DAY"data "EXCEPTION. THE"data "*FORGOTTEN. THE"data "FUNHOUSE. THE"data "GAME NIGHT"data "GARAGE SALE MYSTERY"data "GHOSTHOUSE"data "GORGEOUS"data "GRAVE OF THE FIREFLIES"data "GUARDIAN. THE"data "GUERNSEY. THE"data "*GUN SHY"data "HANGMAN"data "HERO. THE"data "HOWARDS END"data "HUMANITY BUREAU. THE"data "*HUNTERS PRAYER"data "I KILL GIANTS"data "*INSIDIOUS THE LAST KEY"data "JOURNEY. THE"data "KNIGHTS OF THE DAMNED"data "LADY BIRD"data "LAST FLAG FLYING"data "LITTLE VAMPIRE. THE"data "LONDON"data "*LOOKING GLASS"data "MARY AND THE WITCHS FLOWER"data "MARY MAGDALENE"data "MEAN MACHINE"data "MECHANIC RESURRECTION"data "MENASHE"data "MERCY. THE"data "MOLLYS GAME"data "MOM AND DAD"data "*MONEY TRAIN"data "*MONSTER FAMILY"data "MOUNTAIN"data "MY LIFE WITHOUT ME"data "*NINE"data "PACIFIC RIM UPRISING"data "PETER RABBIT"data "*PHANTOM THREAD"data "*PRESSURE"data "PROUD MARY"data "RAISING CAIN"data "RAMPAGE"data "READY PLAYER ONE"data "REANIMATOR TRILOGY"data "RECALL. THE"data "*RED SPARROW"data "RENEGADES"data "RETURN TO MONTAUK"data "REVOLVER"data "RUROUNI KENSHIN"data "RWBY"data "SAM I BLOOD"data "SECRET WINDOW"data "SILENT RUNNING"data "SINGULARITY"data "SNOWWHITE A TALE OF TERROR"data "STOP MAKING SENSE"data "STRANGERS PREY AT NIGHT. THE"data "SUICIDE SQUAD HELL TO PAY"data "TEACHER. THE"data "TOP GUN"data "TURN IT UP"data "TWELVE STRONG"data "VIEW FROM THE TOP"data "WEST AND THE RUTHLESS. THE"data "WILD CARD"data "WINCHESTER"label highlightdata 26data "A",255,125,5data "B",50,150,50data "C",175,75,145data "D",95,30,210data "E",255,255,5data "F",150,175,185data "G",210,115,30data "H",180,240,165data "I",255,5,5data "J",250,70,10data "K",195,40,10data "L",100,75,30data "M",180,180,180data "N",85,170,225data "O",5,255,5data "P",165,105,105data "Q",230,230,130data "R",255,200,200data "S",255,5,255data "T",80,80,205data "U",5,5,255data "V",200,150,35data "W",240,15,70data "X",15,15,90data "Y",65,140,250data "Z",45,160,85`
Have A Yahappy Day.

3
##### Yabasic / Another Colour Select/Randomizer
« on: April 24, 2018 »
D-Pad to select, Page Up to Randomize.

Instead of a 1+1/1-1 count, data has been used for chosen numbers.
In this program, there is 32, 16 and 8 counts, changed by the line - restore value*. * is 1, 2 or 3.

Code: [Select]
`restore RGBread setsdim Rset\$(sets)dim Rnos(sets)for a=1 to setsread Rset\$(a)read Rnos(a)next arestore values3read colsdim Rv(cols)dim R(cols)for a=1 to colsread Rv(a)next asel=3for a=1 to selR(a)=int(cols/2)next aopen window 640,512repeatsetdispbuf vmvm=1-vmsetdrawbuf vmclear windowc=peek("port1")if and(c,128)<>0 left=1if left=1 L=L+1if L>2 L=2if L=2 left=0if and(c,128)=0 L=0if and(c,32)<>0 right=1if right=1 R=R+1if R>2 R=2if R=2 right=0if and(c,32)=0 R=0if left=1 sel=sel-1if right=1 sel=sel+1if sel<1 sel=1if sel>sets sel=setsif and(c,16)<>0 up=1if up=1 U=U+1if U>2 U=2if U=2 up=0if and(c,16)=0 U=0if and(c,64)<>0 down=1if down=1 D=D+1if D>2 D=2if D=2 down=0if and(c,64)=0 D=0if and(c,1)<>0 slide=1if slide=1 S=S+1if S>2 S=2if S=2 slide=0if and(c,1)=0 S=0for a=1 to setsif sel=a then setrgb 1,256,128,0fill rectangle 75*a+150,138 to 75*a+(len(Rset\$(a))*10)+150,156endifif sel=a thensetrgb 1,0,128,0elsesetrgb 1,256,256,256endiftext 75*a+150,150,Rset\$(a)next afor a=1 to sets rem selif sel=a and up=1 R(a)=R(a)+1if sel=a and down=1 R(a)=R(a)-1if R(a)<1 R(a)=1if R(a)>cols R(a)=colsfor b=1 to colsif R(a)=b Rnos(a)=Rv(b)next bsetrgb 1,256,256,256text 75*a+150,165,str\$(Rnos(a))next aif slide=1 thenfor a=1 to selR(a)=int(ran(cols))+1next aendiffor a=1 to selsetrgb 1,Rnos(1),Rnos(2),Rnos(3)fill rectangle 200,200 to 450,450next auntil (1=0)label RGBdata 3data "RED",0data "GREEN",0data "BLUE",0label values1data 9data 0,32,64,96,128,160,192,224,256label values2data 16data 0,16,32,48,80,96,112,128,144data 160,176,192,208,224,240,256label values3data 31data 0,8,16,24,32,40,48,56,80,88data 96,104,112,120,128,136,144data 152,160,168,176,184,192,200data 208,216,224,232,240,248,256`

4
##### Yabasic / Re: Prime Numbers
« on: January 12, 2018 »
And a little faster.
If it only showed text for the last few,
it would take half the time. Use rem notes.

Code: [Select]
`open window 640,512setrgb 1,256,256,256for y=1 to 100000num=0for x=1 to sqrt(y)if frac(y/x)=0 num=num+1if num>3 goto skipnext xif num<2 thenlines=lines+1number=number+1nos=nos+1text 5+gap,lines*11,str\$(y)  rem place with this: if y>99950 text 5+gap,lines*11,str\$(y)endiflabel skipif lines>45 then   gap=gap+70   lines=0   endifif nos=414 theninkey\$ rem take out thisclear windownos=0gap=0lines=0endifnext ytext gap,(lines+1)*11,"("+str\$(number)+")"`

5
##### Yabasic / Re: Prime Numbers
« on: January 10, 2018 »
After a little thought, I sped it up a little, simplified it
and added clear screen carry on. It has room for 6 digits.

Code: [Select]
`open window 640,512setrgb 1,256,256,256for y=1 to 1000000num=0for x=1 to yif frac(y/x)=0 num=num+1if num>4 goto skipnext xif num<3 thenlines=lines+1number=number+1nos=nos+1text 5+gap,lines*11,str\$(y) endiflabel skipif lines>45 then   gap=gap+70   lines=0   endifif nos=414 theninkey\$clear windownos=0gap=0lines=0endifnext y`

6
##### Yabasic / Re: Prime Numbers
« on: January 09, 2018 »
Thanks. I've now added the numerical count
and a start off for larger numbers so the whole
screen doesn't get filled.

Code: [Select]
`open window 640,512space=12spaces=int(500/space)lines=0gap=0z=int(spaces*87)repeatlines=0gap=0number=0for y=1 to 10000num=0for x=1 to yif frac(y/x)=0 num=num+1next xif num<3 number=number+1if num<3 and y>9000 then 'won't start texting until after 9000'delay until then, since still has to countlines=lines+1setrgb 1,0,256,0text gap,lines*space,str\$(number)setrgb 1,256,256,256text 50+gap,lines*space,str\$(y)endif if lines>spaces then   gap=gap+90   lines=0   endifnext yuntil (1=0)`

7
##### Yabasic / Prime Numbers
« on: January 08, 2018 »
Couldn't find any samples of working out prime numbers
So here's mine.

Code: [Select]
`open window 640,512setrgb 1,200,200,200space=12spaces=int(490/space)lines=0gap=0z=3500repeatlines=0gap=0number=0for y=1 to znum=0for x=1 to yif frac(y/x)=0 num=num+1next xif num<3 thenlines=lines+1number=number+1text 10+gap,lines*space,str\$(y) endifif lines>spaces then   gap=gap+50   lines=0   endifnext ytext gap,(lines+1)*space,"("+str\$(number)+")"until (1=0)`

8
##### Yabasic / display problem fixed
« on: November 05, 2017 »
It's been a while, but I had to show this one.

The end result of this might not be of use to most people,
but the programming might. (resistor paralleling values)
My problem was displaying more inputs than I needed,
but only using two or more of those inputs.
All in a simple program. D-pad to navigate.

Code: [Select]
`restore resistorsread setsdim Rset\$(sets)dim Rnos(sets)dim R(sets)for a=1 to setsread Rset\$(a)read Rnos(a)R(a)=1next arestore valuesread resistordim Rv(resistor)for a=1 to resistorread Rv(a)next asel=1open window 640,512repeatanswer=0setdispbuf vmvm=1-vmsetdrawbuf vmclear windowc=peek("port1")if and(c,128)<>0 left=1if left=1 L=L+1if L>2 L=2if L=2 left=0if and(c,128)=0 L=0if and(c,32)<>0 right=1if right=1 R=R+1if R>2 R=2if R=2 right=0if and(c,32)=0 R=0if left=1 sel=sel-1if right=1 sel=sel+1if sel<1 sel=1if sel>8 sel=8if and(c,16)<>0 up=1if up=1 U=U+1if U>2 U=2if U=2 up=0if and(c,16)=0 U=0if and(c,64)<>0 down=1if down=1 D=D+1if D>2 D=2if D=2 down=0if and(c,64)=0 D=0for a=1 to setsif sel=a thensetrgb 1,0,256,0elsesetrgb 1,256,256,256endiftext 50*a+50,150,Rset\$(a)next afor a=1 to selif sel=a and up=1 R(a)=R(a)+1if sel=a and down=1 R(a)=R(a)-1if R(a)<1 R(a)=1if R(a)>5 R(a)=5for b=1 to resistorif R(a)=b Rnos(a)=Rv(b)next bsetrgb 1,256,256,256text 50*a+50,165,str\$(Rnos(a))next afor a=1 to selanswer=answer+1/Rnos(a)next atext 500,165,str\$(1/answer)until (1=0)label resistorsdata 8data "R1",0data "R2",0data "R3",0data "R4",0data "R5",0data "R6",0data "R7",0data "R8",0label valuesdata 5data 2.2,3.3,8,15,39 `

9
##### Yabasic / Re: Basic San Serif Font
« on: August 09, 2016 »
This is my original program before the approach was altered. The colour assign is added. Easy.
It's more work any future project as I've been told, but I can't follow the altered against my
original to add the colour assign to the altered.

Code: [Select]
`a\$="once upon a time there was a king and queen,"a\$=a\$+" and they lived happily ever after."s=1open window 640,512x=20*sy=60*srepeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowc=peek("port1")if c=16 s=s+.01if c=64 s=s-.01x=20*sy=60*sfor a=1 to len(a\$)if  mid\$(a\$,a,1)="a" thensetrgb 1,256,0,0line x-(18*s),y to x,y-(40*s)line x,y-(40*s) to x+(18*s),yline x-(13*s),y-(11*s) to x+(13*s),y-(11*s)endifif mid\$(a\$,a,1)="b" thensetrgb 1,0,256,0line x-(17*s),y to x-(17*s),y-(40*s)line x-(17*s),y to x+(7*s),yline x-(17*s),y-(20*s) to x+(7*s),y-(20*s)line x-(17*s),y-(40*s) to x+(7*s),y-(40*s)line x+(12*s),y-(35*s) to x+(12*s),y-(25*s)line x+(12*s),y-(15*s) to x+(12*s),y-(5*s)line x+(7*s),y-(40*s) to x+(12*s),y-(35*s)line x+(7*s),y-(20*s) to x+(12*s),y-(25*s)line x+(7*s),y-(20*s) to x+(12*s),y-(15*s)line x+(7*s),y to x+(12*s),y-(5*s)endifif mid\$(a\$,a,1)="c" thensetrgb 1,0,0,256line x-(15*s),y-(5*s) to x-(15*s),y-(35*s)line x-(10*s),y to x+(10*s),yline x-(10*s),y-(40*s) to x+(10*s),y-(40*s)line x-(15*s),y-(35*s) to x-(10*s),y-(40*s)line x-(15*s),y-(5*s) to x-(10*s),yline x+(10*s),y-(40*s) to x+(15*s),y-(35*s)line x+(10*s),y to x+(15*s),y-(5*s)endifif mid\$(a\$,a,1)="d" thensetrgb 1,256,256,0line x-(15*s),y-(40*s) to x-(15*s),yline x-(15*s),y-(40*s) to x+(7*s),y-(40*s)line x-(15*s),y to x+(7*s),yline x+(12*s),y-(35*s) to x+(12*s),y-(5*s)line x+(7*s),y-(40*s) to x+(12*s),y-(35*s)line x+(7*s),y to x+(12*s),y-(5*s)endifif mid\$(a\$,a,1)="e" thensetrgb 1,256,0,256line x-(17*s),y to x-(17*s),y-(40*s)line x-(17*s),y-(40*s) to x+(15*s),y-(40*s)line x-(17*s),y to x+(15*s),yline x-(17*s),y-(20*s) to x+(12*s),y-(20*s)endifif mid\$(a\$,a,1)="f" thensetrgb 1,0,256,256line x-(17*s),y to x-(17*s),y-(40*s)line x-(17*s),y-(40*s) to x+(17*s),y-(40*s)line x-(17*s),y-(20*s) to x+(10*s),y-(20*s)endifif mid\$(a\$,a,1)="g" thensetrgb 1,256,128,0line x-(17*s),y-(35*s) to x-(17*s),y-(5*s)line x-(12*s),y-(40*s) to x+(12*s),y-(40*s)line x-(12*s),y to x+(12*s),yline x+(17*s),y-(5*s) to x+(17*s),y-(20*s)line x+(17*s),y-(35*s) to x+(17*s),y-(30*s)line x+(17*s),y-(20*s) to x+(7*s),y-(20*s)line x-(17*s),y-(35*s) to x-(12*s),y-(40*s)line x-(17*s),y-(5*s) to x-(12*s),yline x+(12*s),y-(40*s) to x+(17*s),y-(35*s)line x+(12*s),y to x+(17*s),y-(5*s)endifif mid\$(a\$,a,1)="h" thensetrgb 1,256,0,128line x-(15*s),y to x-(15*s),y-(40*s)line x+(15*s),y to x+(15*s),y-(40*s)line x-(15*s),y-(20*s) to x+(15*s),y-(20*s)endifif mid\$(a\$,a,1)="i" thensetrgb 1,128,256,0line x,y to x,y-(40*s)line x-(10*s),y to x+(10*s),yline x-(10*s),y-(40*s) to x+(10*s),y-(40*s)endifif mid\$(a\$,a,1)="j" thensetrgb 1,128,0,256line x,y-(40*s) to x,y-(5*s)line x-(10*s),y-(40*s) to x+(10*s),y-(40*s)line x-(17*s),y-(5*s) to x-(12*s),yline x,y-(5*s) to x-(5*s),yline x-(5*s),y to x-(12*s),yendifif mid\$(a\$,a,1)="k" thensetrgb 1,0,128,256line x-(15*s),y to x-(15*s),y-(40*s)line x+(15*s),y-(40*s) to x-(15*s),y-(15*s)line x+(15*s),y to x-(10*s),y-(18*s)endifif mid\$(a\$,a,1)="l" thensetrgb 1,64,64,64line x-(15*s),y to x-(15*s),y-(40*s)line x-(15*s),y to x+(10*s),yendifif mid\$(a\$,a,1)="m" thensetrgb 1,192,192,192line x-(17*s),y to x-(17*s),y-(40*s)line x+(17*s),y to x+(17*s),y-(40*s)line x-(17*s),y-(40*s) to x,yline x+(17*s),y-(40*s) to x,yendifif mid\$(a\$,a,1)="n" thensetrgb 1,128,128,128line x-(15*s),y to x-(15*s),y-(40*s)line x-(15*s),y-(40*s) to x+(15*s),yline x+(15*s),y to x+(15*s),y-(40*s)endifif mid\$(a\$,a,1)="o" thensetrgb 1,192,64,192line x-(15*s),y-(5*s) to x-(15*s),y-(35*s)line x+(15*s),y-(5*s) to x+(15*s),y-(35*s)line x-(10*s),y-(40*s) to x+(10*s),y-(40*s)line x-(10*s),y to x+(10*s),yline x-(15*s),y-(35*s) to x-(10*s),y-(40*s)line x-(15*s),y-(5*s) to x-(10*s),yline x+(15*s),y-(35*s) to x+(10*s),y-(40*s)line x+(15*s),y-(5*s) to x+(10*s),yendifif mid\$(a\$,a,1)="p" thensetrgb 1,64,192,128line x-(17*s),y to x-(17*s),y-(40*s)line x-(17*s),y-(40*s) to x+(10*s),y-(40*s)line x-(17*s),y-(15*s) to x+(10*s),y-(15*s)line x+(15*s),y-(35*s) to x+(15*s),y-(20*s)line x+(10*s),y-(40*s) to x+(15*s),y-(35*s)line x+(10*s),y-(15*s) to x+(15*s),y-(20*s)endifif mid\$(a\$,a,1)="q" thensetrgb 1,0,64,128line x-(15*s),y-(5*s) to x-(15*s),y-(35*s)line x+(15*s),y-(5*s) to x+(15*s),y-(35*s)line x-(10*s),y-(40*s) to x+(10*s),y-(40*s)line x-(10*s),y to x+(10*s),yline x-(15*s),y-(35*s) to x-(10*s),y-(40*s)line x-(15*s),y-(5*s) to x-(10*s),yline x+(15*s),y-(35*s) to x+(10*s),y-(40*s)line x+(15*s),y-(5*s) to x+(10*s),yline x+(15*s),y to x+(5*s),y-(10*s)endifif mid\$(a\$,a,1)="r" thensetrgb 1,192,128,64line x-(17*s),y to x-(17*s),y-(40*s)line x-(17*s),y-(40*s) to x+(10*s),y-(40*s)line x-(17*s),y-(15*s) to x+(10*s),y-(15*s)line x+(15*s),y-(35*s) to x+(15*s),y-(20*s)line x+(10*s),y-(40*s) to x+(15*s),y-(35*s)line x+(10*s),y-(15*s) to x+(15*s),y-(20*s)line x+(17*s),y to x+(5*s),y-(15*s)endifif mid\$(a\$,a,1)="s" thensetrgb 1,256,64,192line x-(12*s),y to x+(12*s),yline x-(12*s),y-(20*s) to x+(12*s),y-(20*s)line x-(12*s),y-(40*s) to x+(12*s),y-(40*s)line x-(17*s),y-(25*s) to x-(17*s),y-(35*s)line x+(17*s),y-(5*s) to x+(17*s),y-(15*s)line x-(17*s),y-(35*s) to x-(12*s),y-(40*s)line x-(17*s),y-(5*s) to x-(12*s),yline x+(17*s),y-(35*s) to x+(12*s),y-(40*s)line x+(17*s),y-(5*s) to x+(12*s),yline x-(17*s),y-(25*s) to x-(12*s),y-(20*s)line x+(17*s),y-(15*s) to x+(12*s),y-(20*s)endifif mid\$(a\$,a,1)="t" thensetrgb 1,128,64,128line x,y to x,y-(40*s)line x-(15*s),y-(40*s) to x+(15*s),y-(40*s)endifif mid\$(a\$,a,1)="u" thensetrgb 1,192,128,64line x-(15*s),y-(40*s) to x-(15*s),y-(5*s)line x-(15*s),y-(5*s) to x-(10*s),yline x-(10*s),y to x+(10*s),yline x+(10*s),y to x+(15*s),y-(5*s)line x+(15*s),y-(5*s) to x+(15*s),y-(40*s)endifif mid\$(a\$,a,1)="v" thensetrgb 1,128,64,64line x-(17*s),y-(40*s) to x,yline x,y to x+(17*s),y-(40*s)endifif mid\$(a\$,a,1)="w" thensetrgb 1,256,192,64line x-(20*s),y-(40*s) to x-(10*s),yline x-(10*s),y to x,y-(40*s)line x,y-(40*s) to x+(10*s),yline x+(10*s),y to x+(20*s),y-(40*s)endifif mid\$(a\$,a,1)="x" thensetrgb 1,192,256,64line x-(15*s),y-(40*s) to x+(15*s),yline x-(15*s),y to x+(15*s),y-(40*s)endifif mid\$(a\$,a,1)="y" thensetrgb 1,128,256,64line x-(15*s),y-(40*s) to x,y-(15*s)line x+(15*s),y-(40*s) to x,y-(15*s)line x,y-(15*s) to x,yendifif mid\$(a\$,a,1)="z" thensetrgb 1,192,64,256line x-(15*s),y-(40*s) to x+(15*s),y-(40*s)line x+(15*s),y-(40*s) to x-(15*s),yline x-(15*s),y to x+(15*s),yendifx=x+(40*s)if x>450 and mid\$(a\$,a,1)=" " theny=y+(60*s)x=20*sendifnext auntil (1=0)`

10
##### Yabasic / Re: Basic San Serif Font
« on: August 08, 2016 »
Thanks. It took a bit more work than the wire lettering I did before.
I now want assign a colour to each letter using data.
Not sure how to figure it. My first try failed. Random looked good.

11
##### Yabasic / Basic San Serif Font
« on: August 07, 2016 »
I bothered to do a letter-only upper case font.
Some of the letters could be a bit more pleasant looking - which I'll probably fix - later.

The working part of the program was done for me in another post.

Code: [Select]
`a\$="i bothered to do a basic letter only upper"a\$=a\$+" case font for title headings in pstwo"a\$=a\$+" abcde fghij klmno pqrst uvwxyz"LoadFont()open window 640,512repeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowx=20y=20for a=1 to len(a\$)PrintCharacter(mid\$(a\$,a,1),x,y)x=x+CharacterWidthif x>500 and mid\$(a\$,a,1)=" " theny=y+CharacterHeightx=CharacterWidthendifnext auntil (1=0)sub LoadFont()MAX_CHARACTERS=256dim Start(MAX_CHARACTERS)dim Count(MAX_CHARACTERS)dim x1(1),y1(1),x2(1),y2(1),x3(1),y3(1)read NumCharactersread CharacterWidthread CharacterHeightTotalLines=1for ch=1 to NumCharactersread Ascii\$read NumLinesAscii = asc(lower\$(Ascii\$))Start(Ascii) = TotalLinesCount(Ascii) = NumLinesfor l=1 to NumLinesredim x1(TotalLines),y1(TotalLines)redim x2(TotalLines),y2(TotalLines)redim x3(TotalLines),y3(TotalLines)read x1(TotalLines),y1(TotalLines)read x2(TotalLines),y2(TotalLines)read x3(TotalLines),y3(TotalLines)TotalLines = TotalLines + 1next lnext chend subsub PrintCharacter(char\$,x,y)ch = asc(mid\$(char\$,1,1))for i=Start(ch) to Start(ch)+Count(ch)-1fill triangle x+x1(i),y+y1(i) to x+x2(i),y+y2(i) to x+x3(i),y+y3(i)next iend subdata 26 rem numcharactersdata 27 rem characterwidthdata 35 rem characterheightdata "a",8data 9,0,15,0,6,9data 15,0,18,9,6,9data 6,9,12,9,6,27data 6,9,6,27,0,27data 12,9,18,9,18,27data 18,9,24,27,18,27data 15,18,17,24,7,24data 9,18,15,18,7,24data "b",29data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,0,9,6,6,6data 6,0,9,0,9,6data 9,0,12,1,9,6data 12,1,14,3,9,6data 14,3,10,7,9,6data 14,3,15,5,10,7data 15,5,16,7,10,7data 10,7,16,7,16,9data 10,7,16,9,10,9data 10,9,16,9,15,11data 10,9,15,11,13,13data 10,9,13,13,9,10data 9,10,13,13,9,16data 6,10,9,10,9,16data 6,10,9,16,6,16data 13,13,11,17,9,16data 13,13,16,15,11,17data 16,15,17,17,11,17data 11,17,17,17,17,20data 11,17,17,20,11,20data 11,20,17,20,16,22data 11,20,16,22,14,25data 11,20,14,25,12,26data 11,20,12,26,9,21data 9,21,12,26,9,27data 6,21,9,21,9,27data 6,21,9,27,6,27data "c",30data 17,6,18,9,12,9data 11,7,17,6,12,9data 16,4,17,6,11,7data 16,4,11,7,10,6data 13,1,16,4,10,6data 10,0,13,1,10,6data 8,0,10,0,10,6data 8,0,10,6,8,6data 5,1,8,0,8,6data 5,1,8,6,2,4data 2,4,8,6,7,8data 2,4,7,8,1,6data 1,6,7,8,6,9data 1,6,6,9,0,9data 0,9,6,9,0,18data 6,9,6,18,0,18data 0,18,6,18,1,21data 6,18,7,19,1,21data 1,21,7,19,2,23data 7,19,5,26,2,23data 7,19,8,20,5,26data 8,20,8,27,5,26data 8,20,10,20,8,27data 10,20,10,27,8,27data 10,20,13,26,10,27data 11,19,13,26,10,20data 11,19,16,23,13,26data 11,19,17,21,16,23data 12,18,17,21,11,19data 12,18,18,18,17,21data "d",20data 0,0,10,0,0,6data 10,0,10,6,0,6data 10,0,13,1,10,6data 13,1,16,4,10,6data 16,4,11,7,10,6data 16,4,17,6,11,7data 17,6,12,9,11,7data 17,6,18,9,12,9data 12,9,18,9,18,18data 12,9,18,18,12,18data 12,18,18,18,17,21data 12,18,17,21,11,20data 11,20,17,20,16,23data 11,20,16,23,10,21data 10,21,16,23,13,26data 10,21,13,26,10,27data 0,21,10,21,10,27data 0,21,10,27,0,27data 6,6,6,21,0,21data 0,6,6,6,0,21data "e",8data 0,0,18,0,0,6data 18,0,18,6,0,6data 6,10,15,10,6,16data 15,10,15,16,6,16data 0,6,6,6,6,21data 0,6,6,21,0,21data 0,21,18,21,0,27data 18,21,18,27,0,27data "f",6data 0,0,18,0,0,6data 18,0,18,6,0,6data 6,10,15,10,6,16data 15,10,15,16,6,16data 0,6,6,6,6,27data 0,6,6,27,0,27data "g",34data 17,6,18,9,12,9data 11,7,17,6,12,9data 16,4,17,6,11,7data 16,4,11,7,10,6data 13,1,16,4,10,6data 10,0,13,1,10,6data 8,0,10,0,10,6data 8,0,10,6,8,6data 5,1,8,0,8,6data 5,1,8,6,2,4data 2,4,8,6,7,8data 2,4,7,8,1,6data 1,6,7,8,6,9data 1,6,6,9,0,9data 0,9,6,9,0,18data 6,9,6,17,0,18data 0,18,6,17,1,21data 6,17,7,19,1,21data 1,21,7,19,2,23data 7,19,5,26,2,23data 7,19,8,20,5,26data 8,20,8,27,5,26data 8,20,10,20,8,27data 10,20,10,27,8,27data 10,20,13,26,10,27data 11,19,13,26,10,20data 11,19,16,23,13,26data 11,19,17,21,16,23data 12,17,17,21,11,19data 12,17,18,18,17,21data 18,13,18,18,12,18data 12,13,18,13,12,18data 12,13,12,17,9,17data 9,13,12,13,9,17data "h",6data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,10,12,10,6,16data 12,10,12,16,6,16data 12,0,18,0,12,27data 18,0,18,27,12,27data "i",6data 3,0,17,0,3,6data 17,0,17,6,3,6data 7,6,13,6,7,21data 13,6,13,21,7,21data 3,21,17,21,3,27data 17,21,17,27,3,27data "j",18data 0,18,6,18,1,21data 6,17,7,19,1,21data 1,21,7,19,2,23data 7,19,5,26,2,23data 7,19,8,20,5,26data 8,20,8,27,5,26data 8,20,10,20,8,27data 10,20,10,27,8,27data 10,20,13,26,10,27data 11,19,13,26,10,20data 11,19,16,23,13,26data 11,19,17,21,16,23data 12,18,17,21,11,19data 12,18,18,18,17,21data 6,0,18,0,6,6data 18,0,18,6,6,6data 12,6,18,6,12,18data 18,6,18,18,12,18data "k",6data 0,0,6,0,0,27data 6,0,6,27,0,27data 16,0,24,0,6,10data 24,0,6,18,6,10data 11,13,24,27,16,27data 11,13,16,27,7,17data "l",4data 3,0,9,0,3,27data 9,0,9,27,3,27data 9,21,21,21,9,27data 21,21,21,27,9,27data "m",9data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,0,12,18,6,18data 6,18,12,18,9,27data 12,18,15,27,9,27data 12,18,18,18,15,27data 18,0,18,18,12,18data 18,0,24,27,18,27data 18,0,24,0,24,27data "n",6data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,0,15,16,6,11data 6,11,15,16,15,27data 15,0,21,0,15,27data 21,0,21,27,15,27data "o",32data 17,6,18,9,12,9data 11,7,17,6,12,9data 16,4,17,6,11,7data 16,4,11,7,10,6data 13,1,16,4,10,6data 10,0,13,1,10,6data 8,0,10,0,10,6data 8,0,10,6,8,6data 5,1,8,0,8,6data 5,1,8,6,2,4data 2,4,8,6,7,8data 2,4,7,8,1,6data 1,6,7,8,6,9data 1,6,6,9,0,9data 0,9,6,9,0,18data 6,9,6,18,0,18data 0,18,6,18,1,21data 6,18,7,19,1,21data 1,21,7,19,2,23data 7,19,5,26,2,23data 7,19,8,20,5,26data 8,20,8,27,5,26data 8,20,10,20,8,27data 10,20,10,27,8,27data 10,20,13,26,10,27data 11,19,13,26,10,20data 11,19,16,23,13,26data 11,19,17,21,16,23data 12,18,17,21,11,19data 12,18,18,18,17,21data 18,9,18,18,12,18data 12,9,18,9,12,18data "p",18data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,0,9,6,6,6data 6,0,9,0,9,6data 9,0,12,0,9,6data 12,0,15,2,9,6data 15,2,12,8,9,6data 15,2,17,4,12,8data 17,4,18,8,12,8data 12,8,18,8,12,10data 18,8,18,10,12,10data 12,10,18,10,17,14data 12,10,17,14,15,16data 12,10,15,16,9,12data 9,12,15,16,12,18data 9,12,12,18,9,18data 9,12,9,18,6,18data 6,12,9,12,6,18data "q",34data 17,6,18,9,12,9data 11,7,17,6,12,9data 16,4,17,6,11,7data 16,4,11,7,10,6data 13,1,16,4,10,6data 10,0,13,1,10,6data 8,0,10,0,10,6data 8,0,10,6,8,6data 5,1,8,0,8,6data 5,1,8,6,2,4data 2,4,8,6,7,8data 2,4,7,8,1,6data 1,6,7,8,6,9data 1,6,6,9,0,9data 0,9,6,9,0,18data 6,9,6,18,0,18data 0,18,6,18,1,21data 6,18,7,19,1,21data 1,21,7,19,2,23data 7,19,5,26,2,23data 7,19,8,20,5,26data 8,20,8,27,5,26data 8,20,10,20,8,27data 10,20,10,27,8,27data 10,20,13,26,10,27data 11,19,13,26,10,20data 11,19,16,23,13,26data 11,19,17,21,16,23data 12,18,17,21,11,19data 12,18,18,18,17,21data 18,9,18,18,12,18data 12,9,18,9,12,18data 9,16,20,25,17,28data 9,16,17,28,8,18data "r",19data 0,0,6,0,0,27data 6,0,6,27,0,27data 6,0,9,6,6,6data 6,0,9,0,9,6data 9,0,12,0,9,6data 12,0,15,2,9,6data 15,2,12,8,9,6data 15,2,17,4,12,8data 17,4,18,8,12,8data 12,8,18,8,12,10data 18,8,18,10,12,10data 12,10,18,10,17,14data 12,10,17,14,15,16data 12,10,15,16,9,12data 9,12,15,16,12,18data 9,12,12,18,9,18data 9,12,9,18,6,18data 6,12,9,12,6,18data 13,13,19,27,12,27data 13,13,12,27,8,16data "s",38data 18,7,18,9,12,9data 16,3,18,7,12,9data 16,3,12,9,11,7data 14,1,16,3,11,7data 14,1,11,7,10,6data 10,0,14,1,10,6data 8,0,10,0,10,6data 8,0,10,6,8,6data 4,1,8,0,8,6data 4,1,8,6,6,7data 4,1,6,7,2,3data 2,3,6,7,0,6data 0,6,6,7,0,10data 6,7,6,9,0,10data 0,10,6,9,2,13data 6,9,4,15,2,13data 6,9,8,10,4,15data 8,10,8,16,4,15data 8,10,10,10,8,16data 10,10,10,16,8,16data 10,10,14,11,10,16data 14,11,12,17,10,16data 14,11,16,13,12,17data 16,13,18,16,12,17data 12,17,18,16,18,21data 12,17,18,21,12,20data 12,20,18,21,16,24data 12,20,16,24,14,26data 10,21,12,20,14,26data 10,21,14,26,10,27data 10,21,10,27,8,27data 8,21,10,21,8,27data 8,21,8,27,4,26data 7,20,8,21,4,26data 7,20,4,26,2,24data 6,18,7,20,2,24data 6,18,2,24,0,20data 0,18,6,18,0,20data "t",4data 3,0,21,0,3,6data 21,0,21,6,3,6data 9,6,15,6,9,27data 15,6,15,27,9,27data "u",18data 0,0,6,0,0,18data 6,0,6,18,0,18data 0,18,6,18,0,20data 6,18,2,24,0,20data 6,18,7,20,2,24data 7,20,4,26,2,24data 7,20,8,21,4,26data 8,21,8,27,4,26data 8,21,10,21,8,27data 10,21,10,27,8,27data 10,21,14,26,10,27data 10,21,11,20,14,26data 11,20,16,24,14,26data 12,18,16,24,11,20data 12,18,18,20,16,24data 12,18,18,18,18,20data 18,0,18,18,12,18data 12,0,18,0,12,18data "v",7data 0,0,6,0,6,18data 6,0,12,18,6,18data 6,18,12,18,9,27data 12,18,15,27,9,27data 12,18,18,18,15,27data 18,0,18,18,12,18data 18,0,24,0,18,18data "w",8data 0,0,6,0,6,27data 6,0,12,27,6,27data 11,7,12,27,6,27data 11,7,16,7,12,27data 11,7,16,7,16,27data 16,7,21,27,16,27data 21,0,21,27,16,27data 21,0,27,0,21,27data "x",4data 0,0,6,0,16,27data 6,0,22,27,16,27data 16,0,6,27,0,27data 16,0,22,0,6,27data "y",6data 0,0,6,0,8,18data 6,0,14,18,8,18data 16,0,14,18,8,18data 16,0,22,0,14,18data 8,18,14,18,8,27data 14,18,14,27,8,27data "z",6data 0,0,18,6,0,6data 0,0,18,0,18,6data 11,6,7,21,0,21data 11,6,18,6,7,21data 0,21,18,21,18,27data 0,21,18,27,0,27`

12
##### Yabasic / Over-lap Colour Mixing
« on: June 21, 2016 »
I've always wanted to have different coloured squares moving around and creating
new colours during over-laps of two or more. No knowledge for full interaction with
any and all other squares - only two and one number apart - but the moving
program sample of two squares shows what I mean and an obvious colour mix.

Code: [Select]
`open window 640,512x1=260y1=200r1=256g1=256b1=0x2=380y2=310r2=256g2=0b2=0m=1repeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowif x2-x1<50 or x2-x1>210 m=-mx1=x1+my1=y1+mx2=x2-my2=y2-msetrgb 1,r1,g1,b1fill rectangle x1-100,y1-100 to x1+100,y1+100setrgb 1,r2,g2,b2fill rectangle x2-100,y2-100 to x2+100,y2+100setrgb 1,256,256,256if x2-x1<200 thencircle x2-100,y1+100,5circle x1+100,y2-100,5endifsetrgb 1,(r1+r2)/2,(g1+g2)/2,(b1+b2)/2if x2-x1<200 fill rectangle x2-100,y1+100 to x1+100,y2-100 rem doesn't work with yellow/bluesetrgb 1,0,0,0text x1-90,y1-80,"box1"text x2+50,y2+80,"box2"setrgb 1,256,256,256until (1=0)`

13
##### Yabasic / Letter colouring and count
« on: May 10, 2016 »
vowels only and sometimes 'y'.

Code: [Select]
`restore smallwordsread maxnumdim word\$(maxnum)for a=1 to maxnumread word\$(a)next aopen window 640,512repeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowrow=0col=0a1=0e1=0i1=0o1=0u1=0y1=0for a=1 to maxnumrow=row+1if row>31 thencol=col+39row=1endiffor b=1 to len(word\$(a))setrgb 1,256,256,256a\$=mid\$(word\$(a),b,1)if a\$="A" setrgb 1,256,0,0if a\$="A" a1=a1+1if a\$="Y" setrgb 1,256,96,0if a\$="Y" y1=y1+1if a\$="E" setrgb 1,256,256,0if a\$="E" e1=e1+1if a\$="I" setrgb 1,0,256,0if a\$="I" i1=i1+1if a\$="O" setrgb 1,0,0,256if a\$="O" o1=o1+1if a\$="U" setrgb 1,256,0,256if a\$="U" u1=u1+1text b*10+col,row*16,mid\$(word\$(a),b,1)next bnext asetrgb 1,256,256,256text 10,510,str\$(a1)+" A's/"text 90,510,str\$(e1)+" E's/"text 170,510,str\$(i1)+" I's/"text 250,510,str\$(o1)+" O's/"text 330,510,str\$(u1)+" U's/"text 410,510,str\$(y1)+" Y's in this list"until (1=0)label smallwordsdata 496data "ACE","ACT","ADD","AGE","AGO","AID","AIL","AIM","AIR","ALE"data "ALL","ALP","AMP","AND","ANT","ANY","APE","APT","ARC","ARE"data "ARK","ARM","ART","ASH","ASK","ASP","ASS","ATE","AVE","AWE"data "AWL","AWN","AXE","AYE","BAD","BAG","BAN","BAR","BAT","BAY"data "BED","BEE","BEG","BET","BIB","BID","BIG","BIN","BIT","BOA"data "BOB","BOG","BOO","BOP","BOW","BOX","BOY","BRA","BUD","BUG"data "BUM","BUN","BUR","BUS","BUT","BUY","BYE","CAD","CAM","CAN"data "CAP","CAR","CAT","COB","COD","COG","CON","COP","COT","COW"data "COY","CRY","CUB","CUD","CUE","CUP","CUR","CUT","DAB","DAG"data "DAM","DAY","DEW","DID","DIE","DIG","DIM","DIN","DIP","DOE"data "DON","DOT","DRY","DUB","DUD","DUE","DUG","DUO","DUX","DYE"data "EAR","EAT","EEK","EFT","EGG","EGO","EKE","ELF","ELK","ELM"data "EMU","END","EON","ERA","ERR","EWE","EYE","FAB","FAD","FAG"data "FAN","FAR","FAT","FED","FEE","FEW","FIB","FIG","FIN","FIR"data "FIT","FIX","FLU","FLY","FOB","FOE","FOG","FOR","FOX","FRY"data "FUN","FUR","GAG","GAL","GAP","GAS","GAY","GEE","GEL","GEM"data "GET","GIG","GIN","GIT","GNU","GOB","GOD","GOO","GOT","GUM"data "GUN","GUT","GUY","GYM","HAD","HAG","HAM","HAS","HAT","HAY"data "HEM","HEN","HER","HEW","HEX","HEY","HID","HIM","HIP","HIS"data "HIT","HOB","HOE","HOG","HOP","HOT","HOW","HUB","HUE","HUG"data "HUH","HUM","HUT","ICE","ICY","IDE","IFS","ILK","INK","INN"data "INS","ION","IRE","IRK","ITS","IVY","JAB","JAG","JAM","JAR"data "JAW","JET","JEW","JIB","JIG","JOB","JOG","JOT","JOY","JUG"data "JUT","KEA","KEF","KEG","KEY","KID","KIN","KIP","KIT","LAB"data "LAD","LAG","LAP","LAW","LAY","LEA","LED","LEE","LEG","LEI"data "LET","LEW","LID","LIE","LIP","LIT","LOB","LOG","LOO","LOP"data "LOT","LOW","LUG","LUX","MAD","MAN","MAP","MAR","MAT","MAX"data "MAY","MEN","MET","MID","MIX","MOA","MOB","MOM","MOO","MOP"data "MOW","MUD","MUG","MUM","NAB","NAG","NAP","NAY","NET","NEW"data "NIB","NIL","NIP","NIT","NOB","NOD","NOG","NON","NOR","NOT"data "NOW","NUB","NUN","NUT","OAF","OAK","OAR","OAT","ODD","ODE"data "OFF","OFT","OHM","OIL","OLD","ONE","OPT","ORB","ORE","OUR"data "OUT","OWE","OWL","OWN","PAD","PAL","PAN","PAR","PAT","PAW"data "PAY","PEA","PEE","PEG","PEN","PET","PEW","PIE","PIG","PIN"data "PIP","PIT","PLY","POD","POP","POT","POX","PRY","PUB","PUD"data "PUG","PUN","PUP","PUS","PUT","PYE","RAG","RAM","RAN","RAP"data "RAT","RAW","RAY","RED","RIB","RID","RIG","RIM","RIP","ROB"data "ROD","ROE","ROT","ROW","RUB","RUE","RUG","RUM","RUN","RUT"data "RYE","SAC","SAD","SAG","SAM","SAN","SAP","SAT","SAW","SAY"data "SEA","SEE","SET","SEW","SEX","SHE","SHY","SIN","SIP","SIR"data "SIT","SIX","SKI","SKY","SLY","SOB","SOD","SON","SOW","SOY"data "SPA","SPY","STY","SUB","SUD","SUE","SUM","SUN","TAB","TAD"data "TAG","TAN","TAP","TAR","TAX","TEA","TEE","TEN","THE","THY"data "TIC","TIE","TIN","TIP","TIT","TOE","TOG","TON","TOO","TOP"data "TOT","TOW","TOY","TRY","TUB","TUG","TUI","TUM","TUP","TUT"data "TUX","TWO","UPS","URE","USE","UTE","VAN","VAT","VEE","VET"data "VEX","VIA","VIE","VIM","VOW","WAD","WAG","WAR","WAS","WAX"data "WAY","WEB","WED","WEE","WET","WHO","WHY","WIG","WIN","WIT"data "WOE","WOK","WON","WRY","YAK","YAM","YAP","YEN","YES","YET"data "YOB","YOU","ZAP","ZIP","ZIT","ZOO"`

14
##### Yabasic / manual letter jumble
« on: June 10, 2015 »
application for single activation button push
arrow keys to move high-lighted letter
'END' key to change high-lighted letter

Code: [Select]
`a\$="DBFINTERACTIVE"open window 640,512word=len(a\$)cen=(620-(word*20))/2dim x(word)dim y(word)for a=1 to wordx(a)=a*20+ceny(a)=260next alite=1repeatc=peek("port1")setdrawbuf vmvm=1-vmsetdispbuf vmclear windowif and(c,8196)<>0 letter=1if letter=1 L=L+1if L>2 L=2if L=2 letter=0if and(c,8196)=0 L=0if letter=1 lite=lite+1if lite>word lite=1if and(c,16)<>0 up=1if up=1 u=u+1if u>2 u=2if u=2 up=0if and(c,16)=0 u=0if and(c,64)<>0 down=1if down=1 d=d+1if d>2 d=2if d=2 down=0if and(c,64)=0 d=0if and(c,128)<>0 left=1if left=1 l=l+1if l>2 l=2if l=2 left=0if and(c,128)=0 l=0if and(c,32)<>0 right=1if right=1 r=r+1if r>2 r=2if r=2 right=0if and(c,32)=0 r=0for a=1 to wordif lite=a thenif up=1 y(a)=y(a)-20if down=1 y(a)=y(a)+20if left=1 x(a)=x(a)-20if right=1 x(a)=x(a)+20endifif lite=a thensetrgb 1,0,256,0elsesetrgb 1,256,256,256endiftext x(a),y(a),mid\$(a\$,a,1)next auntil (1=0)`
have a yahappy day

15
##### Yabasic / single action button push
« on: June 07, 2015 »
moves a simple object around the screen using arrow keys
one action, per button push, at a time

Code: [Select]
`open window 640,512x=320y=256repeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowc=peek("port1")if and(c,16)<>0 up=1if up=1 u=u+1if u>2 u=2if u=2 up=0if and(c,16)=0 u=0if and(c,64)<>0 down=1if down=1 d=d+1if d>2 d=2if d=2 down=0if and(c,64)=0 d=0if and(c,128)<>0 left=1if left=1 l=l+1if l>2 l=2if l=2 left=0if and(c,128)=0 l=0if and(c,32)<>0 right=1if right=1 r=r+1if r>2 r=2if r=2 right=0if and(c,32)=0 r=0if up=1 y=y-50if down=1 y=y+50if left=1 x=x-50if right=1 x=x+50if x<25 x=25if x>615 x=615if y<25 y=25if y>485 y=485rectangle x-25,y-25 to x+25,y+25until (1=0)`

16
##### Yabasic / nutting out starfield
« on: May 31, 2015 »
here is left to right (my head hurts)
I'll post towards viewer version (much) later

Code: [Select]
`open window 640,512starfield=100dim x(starfield)dim y(starfield)dim z(starfield)for a=1 to starfieldx(a)=ran(620)+10y(a)=ran(490)+10z(a)=ran(4)+0.2next arepeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowfor a=1 to starfieldx(a)=x(a)+z(a)fill circle x(a),y(a),z(a)if x(a)>640 x(a)=0next auntil (1=0)`

17
##### Yabasic / Maze
« on: December 27, 2014 »
It's not a true maze, but it is a maze like pattern.

Code: [Select]
`open window 640,512 rem >.blox=800dim x(blox)dim y(blox)dim r(blox)for a=1 to bloxr(a)=ran(4) rem or 3 or 2next arepeatsetdrawbuf vmvm=1-vmsetdispbuf vmclear windowfor a=1 to bloxxx=xx+1if xx>32 thenxx=1yy=yy+1endifif yy>25 yy=1x(a)=xx*20y(a)=yy*20if r(a)<.7 line x(a),y(a) to x(a)+20,y(a)if r(a)>.6 and r(a)<1.3 line x(a),y(a) to x(a),y(a)-20if r(a)>1.2 and r(a)<2.9 line x(a),y(a) to x(a)-20,y(a)if r(a)>2.8 line x(a),y(a) to x(a),y(a)+20next auntil(1=0)`

18
##### General chat / Re: Are there people like this here?
« on: March 19, 2014 »
I want to see this work now. It must be a 12000 mile glitch.

Does this get to a Western Leader site?

if so, click on 'browse issues' (at the bottom)
click on year 2013
issue december 24
go to page 6

try this for his website

techvana.org.nz

this shows his collection

19
##### General chat / Re: Are there people like this here?
« on: March 18, 2014 »
There should be one about a guy starting up a gaming console museum.

He;s got examples of probably all consoles and home computers.