October 2018 challenge: “Flow”

Alien Toy Factory - Theme troubleshooting

Posted by AnthonyB on 2018/10/21 01:56

So I spent the last hour or so brainstorming how I'm going to do this thing, and trying to come up with something that'll both fit the theme, and work within the only-use-Kenney.nl-graphics constraint that I seem to have set myself.

Here's what I've got so far, it looks like the industrial theme is the go, based on the number of ideas it triggered, but feel free to steal the other ideas :D

The theme is flow, so the first step is to go look at kenney.nl (https://kenney.nl/assets?q=2d) and think about the sorts of games I can make, and how I'm going to do this whole thing.

Wishlist:

  • it should definitely be multiplayer
  • use the cute aliens from the platformer pack
  • use joysticks and have a couch game (but still need a single player mode)

Thoughts on the theme/graphics:

  • Should we use just one or two map packs? or collate a "custom" image set? 
  • Platformer deluxe doesn't really fit the 'flow' theme (pipes, rivers, etc.) unless I do weird stuff with it?

Some sort of thing with pipes?

  • Aliens building a pipe network for some reason? Water and/or sewage management? (https://kenney.nl/assets/puzzle-pack-2)

Or perhaps holding back a tide or river to save a town from flooding? (https://kenney.nl/assets/map-pack, or the platformer town one?)

  • rain -> river flow
  • build dams, plant/log trees, build sandbag walls, dig trenches, operate pumps, move water downhill or soak it into the ground.

Population or animal management?

  • farm: Fences, food, crazy goat AI
  • try to get animals into the right place without having your roses or crops eaten
  • or a city: subway station management
  • paths, different animal types don't mix (chickens + pigs)
  • animals can break fences if they're left for too long near food
Perhaps a permaculture/ecosystem simulation game? :o
  • more a simulation: cut down trees, plant different ones, remove weeds, encourage animals
  • manage erosion, water, sun, wind
  • relationships between the animals + plants, spreading seeds (poop!), eating certain types
  • fencing + management while the system stabilises
  • need to feed yourself, too.
Platformer industrial pack (https://kenney.nl/assets/platformer-pack-industrial) could work (not included in platformer complete pack?)
  • manage a production line, build conveyor belts, pick things up, run around with them
  • machines which assemble parts to make 'stuff'
        - ingots (copper, iron, carbon?, aluminium, biological?, glass)
        -> plates, wires, cogs
        -> widgets (boxes? larger parts, anyway)
        -> TVs, chainsaws, toys, robots (generic items pack: https://kenney.nl/assets/generic-items)
  • different types of flow:
        - parts, electrical, hydraulic
        - multiple lines of production
        - different tools for each, which you have to pick up and put down :)
  • limited parts (belts, pipes, wires, machines) to make it happen
  • new parts arrive all the time (can order some?)
  • requests for new things to make,
  • refactoring production lines on the fly
  • maybe stuff randomly breaks and backs up and you have to fix it?
  • timed, everyone running around frantically trying to make it all hang together
  • bathroom breaks required - every alien has a little yellow bar next to them which builds up over time. Maybe only one bathroom, too :D
  • A manual (which you have to go run to) which will bring up lists of recipes (but pause the game?)
  • Maybe you need to build the machines, too?

Workflow:

  • 3 hour 'crunches' a'la agile sprints (this is the first one :) )
  • 2-3 crunches per day
  •     - maybe 4 if a crunch finishes early
  •     - 2 if I have something on in the evening
  • try and have an extra feature + working game at the end of each crunch
  • Python-only version for most of it (just need to have Python + pygame installed), but build an .exe at key points/milestones
  • recruit play testers
  •     - family :)
  •     - might be hard for a couch co-op?
  • need to leave time for polish + playtesting (maybe? or just go full goat simulator)

Add a comment

Alien Toy Factory - Pre-comp todo list

Posted by AnthonyB on 2018/10/21 01:35

Didn't get to all of this pre-comp stuff, but I'm parking it here for future reference / just in case I need to refer to it later


TODO:

  • Book leave for the week 
  • Set up entry page 
  • Figure out how to package up a game + test that that part works (maybe make the demo above available as a test?) 
  • XWork out screen capture and recording software for updates. (Livestream development?) Maybe, if people ask for it 
  • Simple agile/scrum-like workflow (one morning / afternoon / evening = 1 sprint?) 
  • XLook at themes from last couple of competitions + workshop them? Too late :D 

Add a comment

Flowing Magic - Project management day 1

Posted by saluk on 2018/10/21 00:04

So It's "flow". Cool theme! A brainstorming session with my friend on the themes earlier yielded a card game where the cards you play will flow around the board, affecting your opponent when they get on their side. We'll see if that sticks - the first few days are going to be very focused on the technical challenges.

I thought I should write down everything I hope to get done today. Until I have really ironed out my design, it wouldn't make much sense to plan further than that. You can check my last entry for the initial spec of what I hope to get done in a week. I have made an addition - I am going to implement an ai mode and a hotseat mode. This is because I'd like the game to still be easily playable if the server is gone, and to let players get a taste even if they can't find someone to play against. Also, it gives me a backup plan if I have trouble fitting in the online components. However I will develop everything so that it would work online even if I don't implement that component.

For today, roughly in order:
Create basic client - opens a window and displays game objects
Create basic game model - find the mvp and implement the model for that
Serialize model - make sure the model can be serilaized for networking
Render model in client - the display should match the model, and be able to update (rebuild itself?) when the model updates
User interface to modify model in memory - give players something (anything) they can do
Objects in model for multiple players - multiple player components, and player unable to mess with the other player's objects
Hotseat mode for basic game - switch current player when "end turn" is pressed
Define basic game mechanics - start designing the rest of the game by building on the mvp mechanics (no code for this)

That's 8 items, an hour each puts me to bed time, so hopefully they take a little less time than that. I think I will be pretty happy if I can at least get to the first user interface part though.

Add a comment

WaveStopper - Welp, gonna make everyone hate me

Posted by ikanreed on 2018/10/20 01:29

I think I've decided to use visual studio to develop my python code this year.  The python plugins are starting to work pretty nicely, and having a GUI wrapper for different installs with info of what's pip-installed in them and able to spit out a requirements.txt automagically is nice.

Add that with shader autocomplete and it's actually a pretty satisfying experience to use Microsoft(TM) Visual Studio(TM) and Microsoft(TM) GitHub(TM) to work on pyglet stuff.


Now to see if I have any hope of coding fragment shader fluid dynamics next week.

Add a comment

SomethingSomething - Procedural Sound

Posted by lucio on 2018/10/15 05:55

I think i will do a game with a sorta real time sound synthesis engine. Generating numpy arrays on the fly and queueing them with pygame's channels. Maybe pyglet for ui if i can mix them.

13 comments

Flowing Magic - Basic Spec

Posted by saluk on 2018/10/14 01:29

Overview

The game will be an asynchronous digital card game. Players will download the client. From there they play the game, which actually takes place on a server. The state of a players game is saved until the game ends, either with a victory or with a player conceding. If both players are connected, it will seem as if the game occurs in real time - though like most card games players take discrete turns, each of which is made up of a series of ordered actions. However, if you connect to a game that you are involved with but had been disconnected, you will see a replay of what happened while you are gone, and can resume your turn.

Client

The client will be written in Kivy. Currently I can build something that works well for OSX or ios. I'm still working on android support - for some reason the build I have has a terrible lag for the touch inputs that really won't fly. I also should be able to do windows pretty easy - just haven't given it a shot yet.

  • Menu for how to get into a game
  • Apply model to graphical interface
  • Animate model state changes into interface
  • Send commands to server based on player input to the interface according to model
Server

The server must handle a series of ongoing games, user accounts, and then state transitions for each game. Since there is no actual synchronous play (it is all discrete state changes) I intend to use a lightweight REST server like hug to manage the networking. The general algorithm looks something like this:

  • Client sends an action command - this is tied to a specific way to change the model
  • Server checks if the player in this state is authorized to make that move
  • Server updates the model
  • Server returns an acknowledgement or an error along with the new model state
  • Clients will also periodically poll for whether the state has updated, and get the new state
Model

The client and server are somewhat dumb in this sense, where the model has the guts of the actual game implemented.

  • Contains some information about the Players involved
  • Contains a Game definition
  • Contains Spaces - these are places that Things can go. Those Things have a Position defined by the Space
  • Spaces contain Things. Things are elements like cards or tokens. Things contain both Static properties and Dynamic properties
  • Each type of object (player, game, space, thing) includes Triggers and Actions
  • Calling an Action is the only way to cause the model to transform. An action results in an updated model, or an error state
The model will exist on the server as well as the client. The client can "look ahead" by attempting to perform Actions and seeing the new state or error cases. This can help with giving feedback to players on what actions are possible in a given board state. Only highlighting cards that they have resources to play for example. In this way, the client can be made slightly more smart - but I can keep scope low by only implementing some of these things as time permits, while still enforcing the rules in a cheat-proof way on the server.

2 comments

Flowing Magic - (Re)-intro

Posted by saluk on 2018/10/12 18:33

I program python for my job, but it is all test cases and selenium. For games I haven't used python in a long time, and lately have been feeling nostalgic for all of the fun game programming I used to do.

So what have I been doing gamewise in the last couple years if I haven't been using python? Well, it's been a little bit of unity, chasing the early VR craze, which was quite fun but I feel pretty over it as the market is really challenging. Not enough people have headsets, and many who do are looking for a specific kind of thing. I usually tend to make very experimental games, and the anti-gravity 3d space pool game I made was no exception. You can see some video of it at the steam page here. Hmm. I should really do another update!

I've also been thinking about and experimenting with analogue game design - board games and card games. It's been a great experience for several reasons. First, without having to worry about programming, you get to the raw gameplay much faster and can answer questions like "is this mechanic good" or "what affect does this change have" much faster. On the other hand, I've found that without being able to rely on the whiz bang of multimedia, you really have to execute strong. I recommend any budding game designers give it a try - you'll learn things you didn't know you didn't know!

There seems to be a lot of cool things happening in this space as well, with card games like keyforge and warhammer champions shifting paradigms in the physical realm, and hearthstone and tabletop simulator bringing analog gaming into the digital space in exciting ways.

So, I'm burned out on 3d, jazzed up about card games, and nostalgic about game development with python. What better excuse than pyweek to make on a digital board game of some kind?

My plan is to build a client/server implementation of a digital card game. The game design itself will be based on the theme, the client/server I will be experimenting with before the competition starts, (but not writing any code.) I will be using kivy, to enable the client to be available on mobile and desktop platforms. And I intend for the server, written with simple http requests using hug to allow both realtime and asynchronous play.

Ambitious I know. It wouldn't be pyweek without some early big dreams that are dashed on the rocks of the reality of the last days.

Add a comment

WaveStopper - Well, my company is making me take python 101 training

Posted by ikanreed on 2018/10/08 17:03

So... right now I'm supposed to be learning how triple quote strings and upper() work and bored out of my mind.  Guess I'll take the opportunity to blog about what I hope to accomplish.


  1.  I'd love to make a machine learning game of some kind.  Bit of a pipe dream in the timeframe we have, but maybe the theme will make an obvious case to fill out?
  2. Art is going to be hell, I'm so used to having teammates who are good at it.  This year, I'm alone.  Unless I drag my wife into it, and I don't know that she'd enjoy that considering she's already doing a seperate game art contest this month.
  3. I want to use my new (kinda expensive) music tools to make some awesome stuff.  Or flail wildly at it, in particular all week and not have any time for code.
  4.  I really want to lean hard into the theme, and make something that really beats a deceased equine organism with whatever connection I come up with.  Some past occasions I've been super light-and-free with theming, and I want to avoid that this time.
  5. Networking?????

Add a comment

Alien Toy Factory - Pygame Zero and PyInstaller working together

Posted by AnthonyB on 2018/10/08 04:07

So I've managed to get Pyinstaller working with Pygame Zero packaging up a script, and it's actually not been too hard to get working, once I figured out a few quirks.

You can see the source code in this gist, which just loads and runs the Pygame Zero demo directly. I haven't tested this *thoroughly*, so (eg.) importing something in the main script may blow up - caveat emptor, etc.

If you're feeling brave and want to help test by running the demo itself, you should be able to download the .exe from Google Drive. Note that you'll need a gamepad with joystick that's recognised by Windows - please let me know if you manage to run it successfully.

Add a comment

Alien Toy Factory - Getting set up for PyWeek

Posted by AnthonyB on 2018/10/04 07:02

Open offer: if you're stuck on something Python related (doesn't even have to be Pyweek related!), drop me a line either as a comment on my entry, or in the IRC #pyweek channel and I'll see if I can help you out.

Quick kinda-brag: I hacked joystick support into PyGameZero and made a demo. You might like it if you're entering PyWeek:

Alien shooting a laser

There's a video at https://twitter.com/AnthonyBriggs/status/1039070401366650880, with a link to a gist in the replies (though bear in mind you'll need my version of PgZero with the joystick and mirroring patches applied). I'll put up a link to it as a test of the packaging process at some point soon.

4 comments