Group | Members |
---|---|
A | Danielle, Amber, Sanie |
B | Talia, Bateel, Jane, Sachi |
C | Jennifer, Jonathan, Dorothy |
D | Enayet, Kim, Gabriel |
This is the last week of the “Foundation” unit. Look back at the topics covered so far: tile systems, using random, user parameters, using noise, and now thinking strategically.
Begin by completing the challenge for this week. Completing this week’s challenge will result in two posts.
Keep Sketching! For the remaining three posts, I encourage you to build a more complex sketch than usual. Post work in progress as you go.
Two of your sketches this week should be based on the challenges below.
For each of the challenge:
Procedural Content Generation in Games is a collection of research in the field of procedural game content. It covers many interesting topics including dungeon+maze generation, fractals, L-systems, generating rules/mechanics, and mixing proc-gen and human-authored content.
Read: PCG Book, Chapter 1
Game Maker’s Toolkit is a Youtube channel that features high-quality video essays on game design.
Watch: GMT: Spelunky
If you want to play Spelunky, the original version (not the HD Remake) is free.
Don’t forget to sign up for orientations for the Laser Cutter and 3D printer.
You must complete orientations for the Laser Cutter and 3D Printer before spring break!
So far we’ve been looking at low-level, tactical topics like how to use random()
and noise()
. Achieving specific, complex results requires looking at problems from at a higher level. You must first have a clear understanding of the effect you would like to achieve, and then begin to plan a series of steps to reach your goal.
How might you make something like this?
As you work in computational form. You will find than many problems involve the techniques composed in different ways. Hopefully you are already seeing that the techniques we have already discussed are common building-blocks that can be used to create a wide array of forms. This trend will continue as we explore other tools and media.
There are many techniques that are widely used in math, physics, or game programming that provide further building-blocks: brownian motion, noise sampling, L-systems, neural nets, turtles, Markov chains, poisson-disc sampling, particle systems, fractals, metaballs.
Today, we will be looking at a single problem domain: placing points on a square. There are countless strategies we might use to place the points depending on the look we want to achieve.
Study each example above:
There are many techniques one may use when scattering points. The examples above were made by composing the following few techniques in different ways.
Place each point at a random location on the square.
// psudeocode
...
x = random() * width;
y = random() * height;
...
Place each point at a location determined by a noise lookup.
// psudeocode
...
x = noise(i * frequency, 0) * w;
y = noise(i * frequency, 1000) * h;
...
Place points in the center points of grid squares. One way to do this is a nested loop.
// psudeocode
...
for (row = 0; row < grid_rows; row++) {
for (col = 0; col < grid_cols; col++) {
x = (row + .5) / grid_size * w;
y = (col + .5) / grid_size * h;
...
}
}
...
Place points randomly, but reject a point if it is too close to an existing point and/or too far from all existing points.
Create hand-made (or generated) arrangements of points. Copy these arrangements onto different locations on the square.
Given a set of points, offset the location of each point a random amount.
// psudeocode
...
x = x + random() * width;
y = y + random() * height;
...
Displace each point at by an amount determined by a noise lookup.
// psudeocode
...
x = x + noise(i * frequency, 0) * w;
y = x + noise(i * frequency, 1000) * h;
...
Find pairs of points that are near each other. Move them towards or away from each other a small amount. This technique is often applied several times with small movements this avoids the problem of pushing a point away from one, but then into another.
Sample noise based on the location of the point. Use the sampled value to determine if the point should be culled (discarded).
When designing a procedural generation system there are several properties to consider. The following properties are borrowed from PCGBook: Chapter 1