Writing tutorials?

Hey all, as I just posted in the about thread, I think that a tutorial thread would be useful. As the creators pointed out on Kickstarter, many backers are beginners! I certainly am, at least as far as game development, so while I’m hoping to share my experience as I learn, I think that we could get a lot more of the other backers in here by starting a discussion about jumping in.

I’m taking a look at the API right now, but it can sometimes be difficult to look at tools and know how to put them together. I know there are a lot of other places online for people to learn various processes for developing programs, but why not here also?

For example: I’m not immediately aware of how I would go about drawing a stick figure to the screen and then animating it; I intend to play around and figure that out, but for a person who’s never even touched C++, it could prove too daunting to even attempt.

2 Likes

Totally aware of this. Tutorials coming. Please do not hesitate to say you feel unsure about something, otherwise we won’t know what’s on your mind.

Going to move this to a dedicated category

Oh I wasn’t trying to complain or anything, I was thinking more along the lines of us community members getting in on writing tutorials, make it a group effort :slight_smile:

already on it, going to start off with introduction to c++ since we dont really have access to the library’s yet

1 Like

This may be a very handy reference then

wait why is everyone linking to this one XD.
well anyway my programming teacher worked on a quiz for local tv station back in 90s
(idk if it was on dutch television its basically a tetris clone with 2 players with your standard quiz questions and letters pop out some of the blocks, they still make it :joy:)

anyway the way he started was not even with the language at all, you need a basic understanding of what the cpu is doing and how it stores things, im not sure if i sude explain pre compile keywords to its a bit confusing for beginners

1 Like

Well, that sounds a lot better, at least to me, since I’ve recoiled a few times from learning C++ since most courses start at learning the basics of the compiler and language elements instead of how to structure a program. I ended up with java and python where you have more ‘goal-oriented’ tutorials.

@adekto if you were to take a stab at writing a tutorial like that, I’d be happy to be a guinea pig.

if you know any programming language its a way easier start then the absolute beginner, you try and explain the diference between [ ] { } ( ) < > " " ’ ’ to someone who has no idea what that even is

My first language was Python, then onto ANSI C, them C++, then assembly and digital design or more advanced OOD at student discretion. California State standards go Java, then C++, basic assembly and architecture or data structures, then onto higher levels. I gather from updates and that we’re starting with a C++ API that we won’t be expected to know anything remotely low level.

1 Like

I have sent some code to @adekto. We will have a nice little first tutorial soon! Thanks for volunteering @adekto !

1 Like

started with the first tutorial level 1-1
explaining it is harder then it looks XD, anyone with experience in c++ please correct me if i mess up or could explain a concept better or if you know a better way then just going line by line

2 Likes

Teaching is harder then doing. I think your tutorial is very good. It’s the first pokitto programming tutorial ever in the universe. Congratulations :slight_smile:

Sorry for hijacking this thread. But @adekto i’m used to c-like languages, but more active in other areas at the moment. Could you whip a simple tutorial with a game loop and drawing up a simple sprite? Shouldn’t be too big. 20 loc maybe?

That would really get me started. That and a simulator :P. I’ll figure out the rest, just need a starting example.

sure thing, well i dont know for sure if this is going to work
ofcource spirte data is b big chunk (you paste in from what the converter gave you) and you can put it in a separate header and include it.

im just making sure the default pallete is set it probebly is but just in case (thats the pico 8 pallete)

and just drawBitmap realy

include "Pokitto.h"
Pokitto::Core game; 

const char sprite[]={/*your sprite data*/};

int main(){
	game.begin();
	game.setDefaultPalette();
	
	while (game.isRunning()) {
    	if (game.update()) {
        	game.display.drawBitmap(10,5,sprite);
    	}
	}
}

also it migth need a game.display.clear(); to clear the screen buffer have to check with jonne wen he has the time, but i would just wait a bit so he can finish that simulator XD

1 Like

I will help you soon with this @adekto I have some time to work on the simulator today.

Have you tested the bmp2pok tool? It generates a sprite & palette. That palette can be loaded with display.load565Palette(uint16_t*)

https://pokitto.com/api/class_pokitto_1_1_display.html#a4c8d110357d836067791711d651d95c8

Ah yes, exactly what I was looking for. No I won’t bother him with that. That’s easily tested :wink:
Great, thanks. Fingers are itching.

ok @jonne so load565Palette() is that set on the sprites individualy or set on the entire buffer?
and do you have to clear the screen or is it automatic?

The palette is used next time a screen refresh occurs. If you draw something, the stop refreshing & change palette, nothing happens on screen until you refresh again.

Huhu lovely you know what.
When you tell me that the first thing i think is :
AMIGA PALETTE TRICK !!!

:slight_smile: