News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_TheElectricMonk

From BASIC amateur to CPCTelera noob -> what do I need to learn?

Started by TheElectricMonk, 22:27, 19 March 24

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

TheElectricMonk

As I'm gearing up to remaking Blowaway Bob, an old game of mine, I come to realize more and more that I don't want to rely on a flickering BASIC RSX routine for my character's sprite.
The game itself will be nothing fancy: Blowaway Bob was a non-scrolling tile-based maze game with only one moving sprite, and not much will change in the remake: Planned upgrades are that some of the maze elements will be animated, and, if memory allows, the game may have some music and better sound effects. However, while the player sprite mostly moves in front of a black background, it also needs to be transparent so it can move across certain maze elements without erasing them.

8BP looked like a great idea so far, but the fact that it can't (or won't) offer the option to do a 15-colored sprite with a 16th transparent color but instead forces you to sacrifice colors was sadly a deal-breaker for me. I enjoy the CPC's mode 0 colors, and the idea of reducing my game palette to 8 colors or less breaks my heart.

So it looks like CPCTelera is the next step - it certainly promises great things. Problem is, I'm really not much of a coder. I've managed to muddle along in BASIC, but never got around to picking up Assembler or anything else machine-code related.

I'm willing to learn though, but I'm not sure where to begin. There seem to be a lot of good Assembler courses out there for the CPC, but it seems CPCTelera is using the C language instead? (Yay, something else I know nothing about)

At this point, I'm a bit overwhelmed as to where to begin. I don't want to learn Assembler just for the heck of it - as educational as it may be - and then find out I can't use it with CPCTelera. So I humbly ask you, wise CPC senseis: What do I need to learn, and where can I learn it?

MoteroV4

CPCtelera uses the SDCC compiler, which compiles your C or Z80 assembler source code, and many others, as you configure it.

Fran Gallego (Profesor Retroman) has courses on his YT channel both about C and assembler with CPCTelera.
https://www.youtube.com/playlist?list=PLmxqg54iaXriIiLmRbeOiwE_NWKM-i8DB

Carlos PerezGrin, has several games presented at the CPCRetrodev, all made in C, with the full source code available. He also has a tutorial on how to make a game in C using CPCtelera on his channel.
https://www.youtube.com/playlist?list=PL09EOWt_YmtVPbUtb9XxGy6ysg76s1Gxz

Both with english translation.
Released cpc games: Memtrainer, El Gerente (Remake)

Jean-Marie

For a simple game like this, you could perfectly use AGD.


ervin

You absolutely need to learn C in order to use cpctelera.
I knew nothing about C back when I started using cpctelera, but I stuck with it and learned by trying ideas and making mistakes. Lots of mistakes!  ;D
Now I can't imagine writing cpc code without cpctelera. It's absolutely brilliant.

TheElectricMonk

Quote from: Jean-Marie on 23:16, 19 March 24For a simple game like this, you could perfectly use AGD.



Thanks for the suggestion, but I already had a look at AGD and decided that despite Blowaway Bob being rather simple, I had one or two ideas that I may not be able to realize in that engine. (For one, my sprites will be too big)

Sykobee (Briggsy)

If you want to stay in BASIC, I recall Sprites Alive! allowed all the MODE 0 colours, and was good for static screen games.

However I'm sure an investment in learning CPCTelera and C would be worthwhile.

MoteroV4

I would recommend that you take this opportunity and invest in learning Assembler.
Why?

1. The 8 bits are the best machines to learn it.
2. It's easier than it looks like.
3. The coder who does not know assembler is like the mechanic who has never opened an engine in his life. Obviously they don't learn with an F1 but with the simplest broken junkyard engine they can find.
4. Understand the entrails of the machine is something that we owed to our profession and it should be taught in universities (they do it at the University of Alicante).
5. The assembler gives total control over the machine that is impossible to achieve with any other programming language.
6. It will open your mind.
7. Furthermore, making games in assembler, on an 8-bit, is when programming becomes Art.
Released cpc games: Memtrainer, El Gerente (Remake)


TheElectricMonk

OK, so I went and bought "C for Dummies" (Amazon promptly asked if I also wanted "Hepatitis C for Dummies" :laugh:) and I'm looking through some Assembler courses in scans of old CPC magazines. Wish me luck!

ervin

Quote from: TheElectricMonk on 16:38, 24 March 24OK, so I went and bought "C for Dummies" (Amazon promptly asked if I also wanted "Hepatitis C for Dummies" :laugh:) and I'm looking through some Assembler courses in scans of old CPC magazines. Wish me luck!
Computing With The Amstrad ran a brilliant assembler course that went for 20 issues or something like that. It's well worth a look.

ervin


TheElectricMonk

Quote from: ervin on 10:35, 25 March 24Here are all the CWTA machine code articles I could find.
https://www.dropbox.com/scl/fo/qjbpuw5ej4sylvmdqun9y/h?rlkey=1nenh3a7kpue2jt7m51l7ijgw&dl=0

Funny coincidence - I got the complete run of CWTA from https://acpc.me and started reading those very articles  :) But it's great to have them bundled like this. Thank you very much for sharing!

ervin

Quote from: TheElectricMonk on 22:02, 25 March 24
Quote from: ervin on 10:35, 25 March 24Here are all the CWTA machine code articles I could find.
https://www.dropbox.com/scl/fo/qjbpuw5ej4sylvmdqun9y/h?rlkey=1nenh3a7kpue2jt7m51l7ijgw&dl=0

Funny coincidence - I got the complete run of CWTA from https://acpc.me and started reading those very articles  :) But it's great to have them bundled like this. Thank you very much for sharing!

Happy to help  :)

Powered by SMFPacks Menu Editor Mod