Week 7 – Midterm Project! – Megan Del Villar

“Salteñada”

Concept

For this project I wanted to create something that actually represents me. I thought about my culture and also something I really enjoy which is cooking. So I asked myself what are my favorite Bolivian dishes and which one feels the most iconic. For me that is the salteña. It is a type of empanada but very unique because it is juicy and has a mix of different ingredients inside.

From that idea I decided to turn it into a game where people can learn how to make salteñas. I was also inspired by a game I used to play when I was younger called Papa’s Pizzeria, where you receive orders and have to complete them correctly. I liked that structure a lot so I adapted it into my own concept but based on Bolivian food.

The main goal of the game is to complete four salteñas correctly by following the recipes shown in the tickets. Each time you play the orders are random so the experience changes every time.

Implementation

I started by thinking about the aesthetic of the game. I wanted it to match the same style I have been using in my other works which is clean, flat, and stylized with shadows made using shapes instead of realistic textures. That is why I built everything using p5.js shapes instead of drawing or importing detailed images.

I created different classes like Ingredient, Dough, and Order so I could organize the logic better. This helped me control how things move, how they are displayed, and how the player interacts with them.

One of the hardest parts at the beginning was figuring out how to drag the ingredients and the dough. I wanted it to feel smooth but also controlled. Designing the ingredients was also challenging because I wanted them to be recognizable but still look like part of a stylized game.

Then I worked on the main mechanics of the game. I created a system where orders are randomly generated so every game is different. I also built a system that stores the ingredients inside each dough and then checks if they match the recipe. This is a simplified version of how salteñas are actually made but it still represents the main ingredients.

For the visual part I used an image of an aguayo as the background and applied a pointillism effect to make it look more organic and consistent with the rest of the aesthetic. I also added a custom font that matches the vibe of the game and background music to make the experience more immersive.

I did not rely too much on external sources. Most of what I used was the p5.js library for things like collision detection and interaction, class notes, and inspiration from Papa’s Pizzeria and Bolivian cooking. I also spent a lot of time experimenting to make everything look visually consistent.

Another important source was actually my younger brother. I made him play the game when it was almost finished to see how a real user would interact with it. This helped me realize several issues like missing instructions or unclear elements. Because of that I ended up spending more time improving the tutorial than the game itself, since I wanted the player to clearly understand what to do and feel rewarded when they succeed.

I also used AI tools like ChatGPT and Claude mainly for debugging (a big part of this project was honestly debugging haha) and understanding certain technical problems and knowing what function, variable or tool would be useful for what I wanted to do.

Code that I am proud of

The part of the code I am most proud of is the recipe validation system. I had to create a way to store all the ingredients that the player places inside each dough and then count them correctly. After that I needed to compare those counts with the order requirements.

This was challenging because it connects multiple parts of the game. The interaction of dragging ingredients, storing them inside the dough, closing the salteña, and finally checking if everything is correct. Making all of that work together correctly took me a lot of time to understand and debug.

function checkRecipe(dough, order){
  let counts = {};

  for(let ing of dough.ingredients){
    counts[ing] = (counts[ing] || 0) + 1;
  }

I am also proud of the full game logic that decides if the player wins or loses. It checks if all salteñas are closed, if they have the correct ingredients, and also handles the timer and the Done button.

for(let d of doughBalls){
  if(!d.closed){
    loseReason = "Some salteñas are not closed";
    endGame(false);
    return;
  }

Finally, one that seemed so simple but it took soooo much time out from me was this multi – clicking to close the salteña

if(now - d.lastClickTime < 400){
  d.clickCount++;
}

Reflection

I really enjoyed making this project and I think I challenged myself a lot. There are still things I would improve. For example there was a moment where I did not like the dragging interaction and I wanted to change it to a pick and release system. However that was very difficult to implement and I was already deep into the project and felt like I was going down a rabbit hole while debugging that, so I decided to keep the drag system to avoid breaking everything.

It bothered me because when I played the game myself I noticed that dragging a lot can get tiring, especially because you are trying to finish quickly. So I think a different interaction system would make it more user friendly.

I also would have liked to add sound effects and more steps to the cooking process. Right now when you close the salteña it is assumed that it already has the juice and is baked. Ideally I would add another stage where the player adds the juice and then bakes the salteña to make the experience more complete.

Another challenge I faced was organization. Because of time changes and breaks in between working on the project, my coding process was not as consistent as before. Sometimes I would go a long time without looking at the code and then come back and work for many hours. That made the code feel a bit disorganized and sometimes I would get lost.

I also struggled at the beginning with making the design responsive to different screen sizes. I could not rely on fixed dimensions like before, so I had to adapt everything to the window size. That was difficult at first but I eventually got used to it.

Overall I am very proud of this project. Even though there are things I would improve, I feel like it represents me, my culture, and my interests. It is also a game that I would actually enjoy playing and I think my friends and family would too.

Leave a Reply