Coding a game in Python: beta version in AUR

python
python3
pyglet
gaming
puzzle
#1

Since my wife is watching “Your Face Sounds Familiar”, and no coding is possible at the moment, I thought to tell you what I’m working on lately. Even if nobody’s interested in joining the project, this will at least prevent me from spamming the screenshot thread.

This is going to be an open source project. I chose python3 as the language and Pyglet as the platform. I already know PyGame limitations and would like to learn something new. Every contribution (e.g. code, ideas, graphics) is more than welcome.

10.04.2019: you may install squarely from AUR.

Coding Night 0

Coding Night 1

Coding started. For now I only have the game concept and the board, dynamically divided into cells and the control panel area.

Coding Night 2

The code learnt to create and deploy animated sprites of n types. Temporarily they’re just rounded squares. I’ll need a graphic designer to draw animation frames.

2 Likes
What are you drinking?
#2

Some projects again @nwg

1 Like
#3

Education first. :smiley:

#4

lol, better of that way.

#5

Coding night 3

The task for tonight was the square selector.

Touch screen will not be given a chance. Squares will be selected with mouse hovering the board, and rotated on left / right click. The logic behind it may still need some improvement, but it already works quite well.

2 Likes
#6

Nice work

#7

Seems like a take on the old rubiks cube? You could possibly do something like create a picture as the ultimate goal to wining say round 1 as far as graphics go, just a thought.

#8

Until some dedicated graphics is drawn. I used squares just to see how much space may be taken by each cell. Those elements could be animated diamonds, dragons, aliens - whatever. But yes: the idea of rotating a square package of elements somewhat reminds of the Rubik’s cube.

#9

Thinking a little more, perhaps you could have instructions for the player that to finish round 1 you have have all the blue squares in a certain pattern or maybe fill the screen, then reveal an animation just for fun to progress to round 2? Then other colours in other patterns or some such?

Im not a coder of any sort but can help with some ideas maybe.

#10

The line you see at the bottom will be replaced with some context help.

I knew that showing the concept as colored squares would be misleading. This is gonna change sooner or later. :slight_smile:

#11

sorry yeah i didn’t read the concept properly. Object is to destroy all the squares so you need something like animated characters that match up, kind of like candy crush i suppose.

#12

Having a befriended designer, who’s really a genius, I do hope not to need to invent the shapes. The problem is, that he always makes me wait forever. :smiley:

#13

Bet that he s in a pretty good demand right !

1 Like
#14

Artists - who’s gonna understand them? :wink: But, well… I’m testing some simple frames drawn by myself. Gazing at the board makes mi sick. :stuck_out_tongue:

1 Like
#15

lol, you bet !

#16

Coding night 4-5

Just to prove I’m still working. :wink:

I restructured data and added a 2-dimensional list to represent the cells grouped in rows. This allowed to implement rotation of 2x2 groups, performed on mouse left / right click.

The coding itself is pure pleasure, but the graphics is not. I intended cells to be 8-frames long animations, but… Watching them move is exhausting… As I mentioned, I’m partially color blind, so 6 types of cells in no way can be represented by colors only: there must be different shapes. I wasted all the last evening on testing various animated shapes, but they all would make me sick.

For now I made all the frames look identical, so no animation is visible. I also added some stupid fruits to make types differ to my handicapped eyes. Will focus on further progress in the code. If no skilled designer offers help in the meantime, I’ll get back to drawings later.

2 Likes
#17

Coming along nicely !

1 Like
#18

Coding night 6

Square rotator seems to be ready. I’m still unsure if it needs further improvement.

1 Like
#19

You work too hard ! lol Looking good.

1 Like
#20

Coding night 7

A lot of code under the hood done.

  • The draw of the board elements takes into account the number of cells of each type at which the game can be won;
  • marking and deleting cells works;
  • determining rows to be scrolled down ready.

Special FX must wait for their turn.

2 Likes