Hmmm well, where to start....
you've really just got to get in there and get your hands dirty so you can grasp what Pulp is doing. Pulp shows tiles on the screen and has some default behaviors for how the user's inputs affect them. It's designed for moving a character around the screen in what they call a "room" and them moving between them. If you don't want the dpad to move a little character around, you'll need to do some work (hide the character, build solid walls for them not to move etc) as it is the main system pulp is built around. The A button, B button, crank and accelerometer all do nothing by default, but the scripting portion of pulp lets you handle that.
Since you mentioned using the crank, I will explain it here.
In the Script tool in Pulp, you pick from "Sources" in the top right. Make sure you have the one called "player" selected. Take a look at the area of code it puts in the center of the screen. If it doesn't already have a method called "crank" add one. It should look like
on crank do
// maybe some stuff here?
end
Lines that start with two slashes are "comments" meaning they are not a part of the code, but are for whomever is reading the code. (This is just the same as javascript which I assume you have some passing familiarity with due to your css/html experience.)
Any code you put between the on crank do
and the end
will be run each time the game notices the crank being used.
As a demo, put in something like this:
on crank do
frame_tracker += 1
if frame_tracker > 5 then
frame_tracker = 1
end
tell 5,5 to
frame frame_tracker
end
end
Then head to the room tool. Click on the "World" layer. Click on the "new tile" button; it is towards the top right, looks like a plus and says "New tile" in the tooltip if you hover over it. Use the tool below that to draw a tile. Make sure the tile has at least five frames and the animation time is set to zero. Try to make each frame different enough to tell which one it is on at a glance. The tool in the middle of the screen is for putting tiles into room so they can actually be seen. Make sure you have the starting room selected and put your new tile in that room in the (5, 5) coordinates (to match what we did in the code.)
Now when you play the game, any use of the crank will progress that frame's animation by one frame. You'll notice that it doesn't matter which way you move it or anything like that because this code is super simple. If you're wondering what frame_tracker
is, that is just a variable that I made up. As the coder, you do this often where you make up names of variables to store numbers (and sometimes a string of words) in, and as long as you don't use words that mean anything else in the language, you can name them whatever you want and each time the code using that name, the game will know it's the same one.
You should definitely read this document: Playdate Pulp. Read a few sentences and then go look at what it was talking about in the Pulp editor so you can better grasp what it is talking about. Once that all seems to make sense, you are going to want to make your own code and not just use this very simple example I gave. Read this document: Playdate PulpScript. Come up with quick ways to use each thing it talks about in there at least once so you know what tools you have.
I hope this helps some.