Skip to content

Simple game written in LÖVE 2D game engine. Collect as many triangles as you can.

License

Notifications You must be signed in to change notification settings

hXR16F/TriangleYAY

Repository files navigation

TriangleYAY - YouTube
Simple game written in LÖVE 2D game engine.


Screenshot_1

About - process of creating TriangleYAY

I've never programmed in Lua. This is my first project that I created in under 24H and this is how I made it:

  1. Learning basics of Lua and how it works in few minutes.
  2. Learning how LÖVE. works - printing some random text on screen (examples from LÖVE homepage). It's similar to python so I've spent about 10-30 minutes.
  3. Learning commands/functions of LÖVE (similar to AutoIt). This part was most time-drainful - few hours. I picked some commands that I will use.
  4. Trying to display something different than text - worked at first try.
  5. Understanding how to receive keyboard input - few minutes.
  6. Added some window collisions - pretty easy, just used WINDOW_WIDTH and WINDOW_HEIGHT variables - 10 minutes of coding.
  7. Now it's part for more than 1 object - I added a "triangle" (it's a circle with 3 segments lol). Took me few minutes.
  8. Understanding how collisions works on different objects - about 30-60 minutes.
  9. I wanted to rotate "triangles" (circles) but it's probably impossible (yeah, I realised I can do it with love.graphics.triangle) - wasted 15 minutes.
  10. Now the hardest part - creating multiple triangles and detecting collisions from them. I've spent about 4 hours to do it.
  11. Adding some effects/shaders. GLSL syntax is more akin to C/C++ so... next few hours. Screen shaking was really easy to apply.
  12. Time for music - sound effects are made with bfxr. Music is from random copy-right free websites.
  13. Final.

Why "TriangleYAY"

Because all you do is collecting triangles that are not triangles and at the end you can hear "yaaay" sound.

Instruction

  • Use arrow keys or WASD to move.
  • Collect as many triangles as you can to get higher score.

Donate

If you support my work or like my projects, you can donate me some money. Thank you 💙