I need to make this

The place for codemasters or beginners to talk about programming any language for the Spectrum.
User avatar
1bvl109
Dizzy
Posts: 98
Joined: Tue Jun 04, 2019 9:00 pm

Re: I need to make this

Post by 1bvl109 »

ZXDunny wrote: Fri Jul 19, 2019 5:24 pm I taught him about DRAW, which is fine.
It is.
ZXDunny wrote: Fri Jul 19, 2019 5:24 pm Strangely enough, they haven't been taught binary, register usage, esoteric display layouts or bit-patterns.
Go easy on them. They are only teachers. They wasted their lives at some university or such instead of experiencing the one true religion in the basement of their parents houses.

Drawing graphs in school you say. Say did they also teach the very important distinction between the graph of the function, i.e. the set of ordered (x,y) value pairs where x is from X and y from Y so that f:x -> y holds and the function itself which is an association f:x -> y. And what exactly is a function? It is a relation, so that for a given x there is at most one y. And what is a relation? It is a subset of XxY. And what exactly is XxY, what are the elements of it? Well they are ordered value pairs (x,y) where x is from X and y from Y.
ZXDunny wrote: Fri Jul 19, 2019 5:24 pm ... or bit-patterns.
That's the beauty. There is nothing to learn. You see the bits, you see the pattern.
ZXDunny wrote: Fri Jul 19, 2019 5:24 pm
He is drawing circles with PLOT and trig, not because he understands SIN/COS (and try teaching him how to do that in asm) but because I gave him the formula for drawing a circle.
If this is heading somewhere I don't know where to.
ZXDunny wrote: Fri Jul 19, 2019 5:24 pm.. there's no way on earth he will understand assembler.
Chubby hen it is.

I suspect that there must have been people who learned assembler from scratch, to give us high level languages.
"Truth would quickly cease to be stranger than fiction, once we got used to it." - H.L. Mencken
User avatar
1bvl109
Dizzy
Posts: 98
Joined: Tue Jun 04, 2019 9:00 pm

Re: I need to make this

Post by 1bvl109 »

Ralf wrote: Fri Jul 19, 2019 4:51 pm Man, I don't know what you're smoking but I want it too :D
Sorry, couldn't find a suitable dead drop.

Unfortunately my description of doing precise loops without knowing how to count featuring the Zermelo-Fraenkel-Set-Rap got banned by the Monty-Phyton-Funniest-Joke-Law.
"Truth would quickly cease to be stranger than fiction, once we got used to it." - H.L. Mencken
User avatar
Morkin
Bugaboo
Posts: 3250
Joined: Mon Nov 13, 2017 8:50 am
Location: Bristol, UK

Re: I need to make this

Post by Morkin »

Eugene C. wrote: Wed Jul 17, 2019 6:51 pm This is "my" version of Can Can:
https://gofile.io/?c=XdiZmK
I don't have any experience of programming. :(
It looks like you know some BASIC, and your music is Beepola generated.

One issue is that the .asm code that Beepola generates plays the whole tune. Though you could modify it to get it to just play one note at a time.

That way you could PRINT something after each note. If it's BASIC it'd probably have to be quite efficient PRINTing - if it's too slow it might start to mess up the music a bit.

Try something like this:

Code: Select all

10 RESTORE
20 GO SUB 1000
30 RANDOMIZE USR 40000		; start Beepola playing
35 GO SUB 100			; PRINT something
40 RANDOMIZE USR 40028		; play a single note
50 GO SUB 100			; PRINT something
60 GO TO 40

100 REM ** PUT YOUR PRINT ROUTINE HERE **
200 RETURN


1000 FOR z=40031 TO 40039	; amend the generated Beepola code
1010 POKE z,0			; to allow playing one note at a time
1020 NEXT z			; rather than the whole tune
1030 RETURN			;
My Speccy site: thirdharmoniser.com
User avatar
Cosmium
Microbot
Posts: 154
Joined: Tue Dec 04, 2018 10:20 pm
Location: USA

Re: I need to make this

Post by Cosmium »

ZXDunny wrote: Fri Jul 19, 2019 2:36 pm I have to agree to disagree with AndyC - Sinclair BASIC served me very well for years and I loved it. Yes, it was slow but being able to produce programs with similar graphics to the games (with character movement and general slowness etc) was amazing.

I loved it so much, I remade the BASIC for PCs. I still love it.
I have to agree also. It was Sinclair BASIC that made making those early games so achievable and accessible - first on the ZX81 and then the Spectrum - even if they ran a bit slowly and had simple character based movement!

But most of the Spectrum features were quite easily accessible from the 'instant on' BASIC and that allowed you to recreate much of the spirit of games from the arcade. Something that wasn't always the case for the computers of the era.

It was that easing in with the accessibility of Sinclair BASIC that then led me on, bit by bit, to the world of machine code.
User avatar
ZXDunny
Manic Miner
Posts: 498
Joined: Tue Nov 14, 2017 3:45 pm

Re: I need to make this

Post by ZXDunny »

1bvl109 wrote: Fri Jul 19, 2019 7:12 pm Drawing graphs in school you say. Say did they also teach the very important distinction between the graph of the function
What, for a 7 year old? Why would they?
ASH-II
Drutt
Posts: 11
Joined: Sun Jun 16, 2019 11:48 am

Re: I need to make this

Post by ASH-II »

Code: Select all

10 RESTORE 130
20 LET x=0: LET b=0: LET n=7
30 BORDER 7: PAPER 0: INK 6: BRIGHT 1: CLS 
40 READ t$: PRINT AT 21,0;
50 FOR f=0 TO LEN t$
60 POKE 23692,255
70 PRINT t$(f+1);
80 IF b=2 THEN LET b=0: READ n
90 IF N=255 THEN LET N=0: READ T$: RESTORE 180: GO TO 50
100 BEEP .1,n
110 LET b=b+1
120 NEXT f
130 DATA "THIS IS THE FIRST LINE OF TEXT  I HAVE DISSABLED THE SCROLL WITHA POKE AND PLAYING THE TUNE WITHA SIMPLE BEEP COMMAND***********THANK YOU. . . . . . . . . . . ....... ADD TEXT HERE AS YOU WISH..."
140 DATA 14,14,16,14,12,12,16,17,21,24,21,21,19,19,19
150 DATA 21,12,12,21,19,12,12,16,16,14,16,14,16,14,16,14
160 DATA 7,14,14,16,14,12,12,16,17,21,24,21,21,19,19,19
170 DATA 21,12,12,21,19,12,12,16,16,14,16,14,12,12,12,12,0
180 DATA 0,0,0,0,4,2,0,7,7,7,7,7,9,4,5,2,2,2,2,2,5,4,2,0
190 DATA 12,11,9,7,5,4,2,255,"*.*.*.*.*.*.*.*.*.THANK YOU*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*.*."
Eugene C.
Drutt
Posts: 28
Joined: Wed Jul 17, 2019 2:47 pm

Re: I need to make this

Post by Eugene C. »

:o :o :o :o Thank you !!!! :D
Post Reply