Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [procedural-generation]

Procedural generation is the construction of content based on algorithms and calculations rather than by hand.

0
votes
0answers
20 views

Unity3D - How to create flat map render based on endless noise data

The Project I'm working actually on a Endless Map Generator (with chunks, height-map noise, threading system, etc..) This is actually what "dev data display" look like: The Goal Now I want to ...
0
votes
1answer
46 views

Using Reflection to access an array from a ScriptableObject in Unity

I am trying to get access to a set of stored variables inside a scriptible object in Unity. This class (SectorDeclaration) has a method to pull a variable with a string of the variables name from it: ...
2
votes
0answers
53 views

Non-Perfect maze generation with objectives [duplicate]

I need an algorithm that can generate mazes with these requirements: Allows for random structures to be made (Ex: a center spawn area, objective points and 'Caverns (corridors with 2 or more ...
3
votes
1answer
64 views

How to paint regions of a map with visually different colors

I'm learning some concepts of procedural content generation. Now I'm generating a map with regions and each region has a diferent colors generated in a pseudo-random way. My problem right now is ...
1
vote
3answers
113 views

Combining Minecraft and Dwarf Fortress: Simulating autoplay in a pseudo-infinite procedurally generated world?

One of the interesting things about Dwarf Fortress (and other procedurally generated games like Civilization) is that the game simulates multiple AI factions interacting with each other over time (...
4
votes
1answer
165 views

Pathfinding in Procedural cave generation

I'm learning THIS tutorial about procedural cave generation using cellular automata with Unity. I want to implement pathfinding on some enemies, so I need to make a quantization of the procedurally ...
2
votes
1answer
103 views

Coherence between 2d tile maps

In dwarf fortress, there are 3 levels of maps in the screen you pick your starting position, and they all coincide with each other perfectly. I am assuming that the top level tile accounts for lets ...
0
votes
0answers
52 views

Draw objects that move on an “infinite” map

I'm generating a game map using a mod function, so when I reach the boundaries of the map, I start generating the map again, I can generate the tiles by moving my character correctly, and when I reach ...
8
votes
2answers
405 views

Town generation algorithms

In this RPG.SE post a long-lost page with several online generators is mentioned. I'm particularly curious about the way towns were generated. Take this image for example: Although a lot of things ...
2
votes
2answers
103 views

How to better refactor loops in procedural world generation?

One of the steps for cell-based dungeon generation is deciding the amount and location of exits for each room. My current set up consists of the following: Define my exits. There are 15 types of room ...
4
votes
3answers
337 views

How can I tile Perlin noise to more accurately represent a world map?

I'm currently working on my game. I would like to generate the world map with Perlin noise, and wrap it just like a real world map. I've found a algorithm to create a map wrapped along X and Y axis: ...
1
vote
0answers
69 views

Spawn network objects in generated map

In my game, the server generates a procedural map, after send generation seed to generate it on the client. The client generates exactly the same map. In the map, I need to synchronize objects with ...
4
votes
1answer
105 views

Randomly generated maps in Multiplayer

I am currently trying to get randomly generated maps work in multiplayer but I have so many difficulties trying to figure out how. How do other games implement this(Minecraft, Terraria, Don't starve)? ...
1
vote
1answer
130 views

Algorithm to generate random shapes that fill up a rectangle?

The final result can be like this I've thought up several approaches: Generate random curved lines to "cut" the rectangle (or generate random dots and form the line from the dots) Break the ...
1
vote
0answers
106 views

How is terrain editing implemented like a sculpt tool?

Some creativity/sandbox games have a terrain editing feature. When thinking of a terrain, I'm thinking of a grid of vertices. The elevation of each vertex is then determined by a heightmap (image). ...
2
votes
1answer
411 views

How can I generate roads such as those in the game Twisty Road?

Here is a link to see the gameplay: https://www.youtube.com/watch?v=03PzsgO-uAM How could I procedurally generate the path upon which the ball rolls in Unity/C#? As an amendment suggested by ...
3
votes
1answer
288 views

Overcoming fill rate and generation bottlenecks in voxel engine

I decided to make a voxel engine using octrees. I am instancing entire cubes and sending the sizes and positions to the vertex shader. I currently have 2 major problems: Problem 1 - Because the ...
9
votes
1answer
279 views

Procedurally-generated 2D curved roads on map

I've been experimenting with algorithms to automatically generate road maps for a game I am working on. I'm using the "Kingdom Rush" games as a reference point as they have some great-looking maps. ...
3
votes
1answer
570 views

Create a 2d circular maze

How can I create a 2d procedurally generated circular maze like the following picture:
4
votes
1answer
80 views

Help Improving Map Generation

I've recently attempt for the first time to implement a map generation system and while it does work, it doesn't work exactly the same I want but I'm not really sure on what changes I can make it to ...
2
votes
1answer
63 views

Securing feasibility in procedurally generated endless runner

I am currently in the concept phase for an endless runner I want to develop with libgdx in Java. As I can not preassemble an infinite level, the generation of obstacles and power-ups needs to be "...
2
votes
1answer
256 views

Basic Random Tile Map Generation

Currently I've got a map like this: It's pretty simple but what I want is that area of tiles to be random, with the number of tiles present being random (Within a minimum and maximum amount of tiles ...
0
votes
2answers
114 views

Perlin noise terrain: 3 coordinates from one

I am making a game with procedural terrain, like minecraft. I have a perlin noise function which takes one integer and returns a number between zero and one. However, for terrain, I need a single ...
3
votes
1answer
231 views

Procedural Star Generator

I want to develop a procedural galaxy / starfield generator. A rather simple approach would be to use some pseudo-random algorithm to repeatedly create a star and its properties (such as position, ...
2
votes
1answer
89 views

Random generation of a board

So I have four "boards" made of 16 sprites (4x4). Each board is parented to an empty GameObject. I would like to randomly generate their positions but I am not sure how. However, they should still be ...
3
votes
1answer
169 views

Redistributing sprites in procedural generation according to player movement

I am making space arcade with procedurally generated background consisted of nebulas and stars sprites, which spawn on Awake() in certain borders around player. Mobile phones have limited capacity ...
0
votes
0answers
125 views

Unity Mesh Optimization

I am making a Minecraft style game and I am looking for a good way to hide block faces that are underground or blocked. Thank you for any suggestions. Below is my code. ...
6
votes
1answer
261 views

3D terrain generation: geological slices and noise function

Everyone knows how to use Perlin noise to generate the surface of a 3D world. You may use one or several octaves to generate more detail. It is also known how to use 3D Perlin noise to generate, to ...
0
votes
1answer
187 views

Procedural generation background works with one type of prefab and doesn't work with another

I have background generation script with 2 arrays. One contains stars prefabs with sprites and another contains nebulas prefabs with sprites. Both have identical types of variables as generating ...
0
votes
1answer
81 views

How can I generate random levels like in “Square it!” game?

In this game, you have a 2d field with some free squares and two colored squares which you can move but only together (they'll move only if the spot is still "free"). And you have to fill whole free ...
0
votes
1answer
139 views

Locking value when creating tweaking dependent values

I have several values which adjust them self In Unity Inspector when I tweak one of them. So total sum of these values stays constant. (which is 100 as 100%) Sometimes it is hard to get specific ...
1
vote
2answers
187 views

Procedural dungeon algorithms for a more open dungeon

I'm working on a game that I want dungeon generating in, but I plan on having ranged weapons in it, so I want it a bit more open. I'd like to avoid corridors and I don't want to use a grid of custom ...
1
vote
1answer
52 views

Prioritizing prefabs in array for procedural generation

I am trying to create procedural space background with a bunch of sprites of nebulas and stars. I have made few prefabs with different types of sprites attached to them. I have created an array ...
1
vote
2answers
136 views

Background generation with sprites in 2D dimension in Unity

I am making 2D game with Unity. I want to create a procedurally generated background with a bunch of sprites (space background, I have sprites of nebulas and stars). I want some area around the player ...
8
votes
1answer
171 views

How can I procedurally find a wall that separates two or more points on a grid-based map?

I'm trying to generate walls that cut off a given point from other given points. The attached image shows the sort of thing I'm after: Blue separated from Red. Blue separated from Red and Yellow. ...
2
votes
1answer
128 views

Unity - Background made with procedural shapes?

I would like to know how to make a background like Super Hexagon managed to do: a hexagon in the middle and equally sized trapezoids. There's a screenshot below & the here is the effect in motion. ...
1
vote
2answers
84 views

Voronoi graph - traversing from vertex to vertex

I'm working on a Unity Project in C# I've built a 3D Voronoi Diagram using the csDelaunay library from PouletFrit and using the X and Y values from a 2D diagram to instead setup some Vector3's with ...
1
vote
1answer
260 views

High-level advice on procedural river (Unity3D) [closed]

I'm working on some procedural content for Unity3D - in C# My main aim is to build a flat plane (or maybe later a terrain / mesh), with a single river running through it, based on a seed value. I ...
1
vote
2answers
189 views

How can I generate a random 2D surface

I'm trying to build an old game (Lander) where you try to land a spaceship on a flat platform. But I have no idea how to generate a random surface. Something like in the picture would be nice. Edit: ...
1
vote
0answers
130 views

2D Sideview Procedural Water Generation

How can I generate water in a procedural 2D sideview landscape? Here's what I currently have: First generate the heightmap of the land Then generate the water, based on the land Here's how I ...
1
vote
1answer
223 views

Scene building for procedurally generated tile based world in Unity

i'm making a procedurally generated side-scrolling and destructible tile based world. So far I've got : - the values generator (for deciding which tile to place where) - a testing scene generating ...
3
votes
1answer
70 views

Mix of Procedural and Manual level design / creation in UE4

I'm trying to design a maze using a mix of procedural and manual generation. I have the maze already generated and would like to place other objects in the maze manually in the editor. The issue is ...
18
votes
1answer
4k views

Why is this Procedural Content Generation while that other isn't?

I'm reading the online Procedural Content Generation book and on chapter 1, page 2 there's one example of what PCG is and another of what PCG is not and I can't tell them apart. This is PCG according ...
0
votes
1answer
74 views

Determine terrain type and worldobject placement techniques

I'm currently researching the techniques of generating a procedural map. I've already found some methods regarding the mesh generation (e.g. variations of noise like perlin, simplex and cell, midpoint ...
4
votes
2answers
190 views

Messy results from simple cellular automata algorithm?

I wrote something that will first randomly populate a square a with grass tiles, and then from there it will calculate tile types from each tile's surrounding tiles. My ultimate goal is generate a ...
4
votes
1answer
92 views

Diagonal symmetry across a filtered array?

I wrote this code to randomly generate a square terrain that somewhat resembles an island. First, I randomly populated a square with grass tiles (1s) on a plane of water tiles (0s): Then, I looped ...
5
votes
2answers
229 views

Scan for water in 2D procedural terrain locale

In my 2D-sideview game, I have certain biomes, each one having a unique sea level, or water height, (depending on the humidity of the biome). The terrain is composed of stacks of blocks, each being a ...
0
votes
0answers
60 views

Lighting the generated scene

I have a corridor generated at runtime from a prefabs of floor, ceiling, walls and random decoration on them (like paintings or shelves), and doors. Each wall is a separate part. Each prefab except ...
1
vote
2answers
54 views

Letter game board creation

I currently have a game concept similar to the mobile app Alphabetty where you are given a grid of letters and are tasked with spelling words. When you use a letter in a word, it disappears and new ...
6
votes
3answers
395 views

Generate cave like Terrain in 2D

I want to create 2D Terrain randomly. It should look like a connected Cave (Shown below). What is the best method or Algorithm to get similar results? The important part is the open area(green) and ...