Note: if you are running from source and have speed issues please run the game using the -O flagDownloads
These are old links that correspond to my entries for pyweek newer versions can be found HERE
The aim of citySquare is to match up the tiles from the tray on the right on the grid as best as is possible in a given amount of time. Points are awarded for completed cities (the somewhat poorly drawn orange bits) and roads. They are however taken away if the city or road is incomplete.
Also note that scoring is skewed to give more points to large cities, so you should really be trying to make your cities as large as possible within the time limit. Finally, ensure that all of your tiles match up, and that any tiles touching the edge of the grid are grass, any invalid ignored for scoring purposes, don't waste those tiles!
Incidentally the easiest grid in the game is 3x3 meaning 9 tiles. And goes up to the nightmarishly difficult end of the spectrum where you will have a 9x9 grid. (yes it did drift from the theme a bit)Controls
The controls are fairly straightforward, click a tile to pick it up click again to drop it. Dragging and dropping will not work, you actually have to click and let go.
Tiles can be rotated by right-clicking them or by by picking up a tile and scrolling. All of the tiles currently on the grid can be shifted around using the arrow keys. To view a breakdown of your score so far you can press hold tab.
And finally the pause menu can be accessed by pressing escape while in game
Ratings (show detail)
Binary distribution for windows
A mac binary for those who want it
source: Final version for pyweek
Now with a working tray
FInaly have it generating the tiles to fill a board
I have uploaded the a source copy and managed a mac binary. I still cant get windows binary complied though without it throwing some errors about sqlite3 not being a valid win32 application.
Ok im not sure if it is against the rules to have done it after the finish data but i have modified the library i used for high-scores to use pickle instead of squlite3. I think it was allowed as i changed none of MY code or fixed any bugs or problems with the game, i only changed it enough to complile.
Anyways i have updated the game's page and uploaded binary's for windows and mac as well as the source
Have fun playing
I have made great progress in the past few days and implemented tons of stuff like proper scoring menu, and crushed many other subtle and rare bugs that seemed to wander through my code.
I am quite happy with the game i have come up with, even though it is a relatively simple game.
Tomorrow morning i will have a few hours to add in a scoreboard but then after the competition i will have more time to update and optimize some stuff as well as writing up a longer entry.
Before i crash i do have a screen-shot of my fancy new menus though
citySquare: Day 3
Nothing else much to say really besides i hope i get around to setting up scoring tomorrow.
I do however have another screenshot to offer
As well as a download link to the current state of the project on github, see readme for controls
Note: stick with the tagged releases found under downloads because any commits are likely to be broken or not quite work properly
Finally i got to a point where it was much easier to just ditch the offending objects and recode them. Many hours latter and i was still running into the same bugs of tiles not being rotated correctly, sometimes. Eventually the offender was tracked down, it turned out to be one of the first functions i had written, a simple little function to cycle a list forwards or backwards, and it only worked going forwards.
tlist = tlist[:]
for x in range(abs(direction)):
if direction > 0:
So the tiny mistake of forgetting to pass 0 to pop cost me about 6 hours of programming time. Complaining aside it works now and can generate a full 9x9 board. I have added weighting so some tiles are more likely to be chosen than others to try and generate a less erratic board but if i have time i would like to add some heuristics to try and make it favor forming larger cities over many small ones.
By tomorrow i hope to have unused tiles sitting in a tray on the right (scaled down) and be able to drag and drop them around on the grid, and if i am going really well hopefully a good start on the scoring code too.
I have also managed to rope in a friend to attempt drawing up some nicer tiles for me.
I commend you if you have read this far though the haze of poor spelling and grammar.
Coming up with a concept
Of all of the possible themes to be chosen 9 times was by far the most difficult for me to come up with a game concept because of which my game might not be the most original, but is more a mash together of a few different games that are currently out there.
Well anyway eventualy i came up with the idea for citySquare. In citySquare the user will be given 81 tiles and will have a certain amount of time to arrange them on a 9x9 Grid.
Each of the tile's edges can be either grass, road or city. The player has to place and arrange the tiles to gain as many points as possible.
Points will be awarded when time runs out for completed cities and roads but subtracted for any that are unfinished, with a bonus if all of the tiles are used to make a "perfect city"
The scoring system will reward players for bigger cities much more than for smaller ones, e.g. a city spanning 4 tiles would be given more points than 2 cities spanning 2 tiles.
If I have time I would like to add an additional game mode that just allows you to time how long it takes you to arrange your tiles to make a "perfect city"
All opinions or critiques are welcome