❌

Normal view

  • βœ‡Tyler
  • The 5 Piece Sword
    I made a Playdate Pulp game, okay so let’s go back. The Playdate is a small yellow 8-bit inspired console, it has no backlight and a lot of fun indie games. Now you can make a game on the Playdate in many different coding languages including SDK, NOVA, Swift, and Pulp which is what I coded my game in. Pulp is a simple coding language that is great for people who are new to coding to start with. All the instructions are on a website and there are a lot of different things you can do with t
     

The 5 Piece Sword

31 August 2024 at 01:43

I made a Playdate Pulp game, okay so let’s go back. The Playdate is a small yellow 8-bit inspired console, it has no backlight and a lot of fun indie games. Now you can make a game on the Playdate in many different coding languages including SDK, NOVA, Swift, and Pulp which is what I coded my game in. Pulp is a simple coding language that is great for people who are new to coding to start with. All the instructions are on a website and there are a lot of different things you can do with the code even though it’s a small language.

You design your own characters in an 8x8 grid and you design your own level in a 24x14 grid. You code each one of those characters and each level. I will have posts later on that were actually coded but here I’m trying to keep to the main point. I worked for about a month, over 100 hours, and had 1683 lines of code to finish it. It is called The 5 Piece Sword.

You go through 20 different levels that include mazes, enemies, turrets, and more to get all the pieces of your sword. As you get more and more pieces your weapon does more and more damage but beware as the enemies get stronger with you. That’s the main premise of the game, you can emulate it with this link.

I would love to hear what you think and if you find any glitches I would love to know. Thank You! (I will post more about he code of the game if you are interested in that)

Part of Summer Challenges.

  • βœ‡Tyler
  • Simple Enemies in Playdate
    This post is how I made the enemy’s move in my Playdate Pulp game. First, you need a function, EnemyMoveUpdate once you have that, in the game code you create a variable that is (I will use foo as this variable)= to event.frame. Event.frame is equal to the number of frames that have elapsed since the start of the game. Now you divided this by how fast you want your enemy to move, so 4 is fast whereas 10 is more normal. Then you make a new variable foo2 that = to the floor of foo then you
     

Simple Enemies in Playdate

31 August 2024 at 13:47

This post is how I made the enemy’s move in my Playdate Pulp game. First, you need a function, EnemyMoveUpdate once you have that, in the game code you create a variable that is (I will use foo as this variable)= to event.frame. Event.frame is equal to the number of frames that have elapsed since the start of the game. Now you divided this by how fast you want your enemy to move, so 4 is fast whereas 10 is more normal. Then you make a new variable foo2 that = to the floor of foo then you see if foo is equal to foo2 if it is then tell that function to run otherwise do nothing.
Credit to SquidGod for this part.

Now onto the actual enemy, make your little design
then get to coding. On the function set the EnemyX, and EnemyY to event.x/y which basically tracks wherever the tile is and then says if event.px which is the player x is more than enemyX then minus one from EnemyX elseif event.px less than the enemy then plus one to the EnemyX if nothing happens the player x is equal to the enemy x and it should change its y. You do the same for the enemy Y’s then you have to make sure the enemy isn’t going out of bounds so you just say something like foo = name of new enemyX and EnemyY now we have the name of the next block the enemy is going to go to. then it is != to white(which is the only block the enemies should go on) if it’s true it resets the EnemyX to event.x wherever it is now so when we change the next block it won’t plus or minus the x at all the x will stay the same. This just makes it so the enemy can’t go over solid block and it can’t go out of bounds. You do the same for the Y then you tell the enemy to swap white and the new EnemyX, EnemyY to swap with the enemy.

The final thing we have to do is deal damage. so we check if enemyX = to PlayerX then if EnemyY = PlayerY if that’s true I have a function to do damage to the player so we set the damage to 1 then tell event.player to call that function and in that function it damages the player. More on the health system next post. Thank you for reading tell me if you have any questions

❌