Questions tagged [procedural-generation]

Programmatic generation of content (graphics, sounds, level-design,...) using random or pseudo-random processes, usually on the fly.

535 questions
0
votes
1 answer

Trying to use perlinnoise for generation of terrain

I am trying to generate a procedural terrain using perlin noise. Before, I was just creating a 1000 * 1000 vertice terrain so I just had a simple function that would fill the height map with the noise values. However now I am trying to generate a…
fltray10
  • 31
  • 6
0
votes
1 answer

How to return tile based on heightmap efficiently?

I am procedurally generating a world and for each position in the Tilemap I call this function in order to get the tile type that matches the height: public static NaturalTile GetNaturalTileByHeight(float height) { SortedDictionary
0
votes
2 answers

Procedural world generator spawns overlapping ground tiles - Unity3D C#

I am a bit of a noob at coding so sorry if I'm missing something obvious. I am working on procedurally generating a junkyard of finite boundaries. I used a 2D unity tutorial (part 1 of 3 found here:…
0
votes
1 answer

How to generate objects (trees) on tiles at runtime? (Unity 2D Tilemap)

I am making a game that looks similar to Rimworld (top-down colony simulator) for a college project and I procedurally generate my terrain using perlin noise, then for each tile in the map I use SetTile() to populate the map with walkable…
caleidon
  • 239
  • 4
  • 13
0
votes
0 answers

Procedural generation and permutations question

I probably won't pursue this but I had this idea of generating a procedural universe in the most memory efficient way possible. Like in the game Elite, you could use a random number generator based on a seed, and so each star system can be…
0
votes
1 answer

What could be causing meshes to generate rotated? LWGL

I am loading chunk values from a height map to create infinite terrain, but I'm having issues with the rendering of each mesh chunk. When I load a single 500x500 unit mesh, it is a smooth mesh. When I load a 5x5 of 100x100 meshes, it is a jumbled up…
0
votes
1 answer

Unity: mesh.triangles = t; mesh.triangles == t returns false

I'm making a program where a large and complicated mesh is procedurally generated. At first I generated a large number of smaller meshes, which works just fine, but then I decided to merge them together and some triangles got corrupted. After a bit…
0
votes
0 answers

Is there any way to improve performance of my procedural generation code?

I've been working on a project lately that creates procedurally generated terrain which uses 3d simplex noise as well as the Marching cubes algorithm. I am currently running it on my cpu which takes around 10-20 seconds to render a 200x200x200…
0
votes
1 answer

Can you reset World.frameCount in Code.org JS (Game Lab)?

This question is for a game I am working on in the Game Lab in Code.org. The game in question will be like a skydiving game, where obstacles spawn at random intervals (between 1000 and 3000 ms). Here is the code: World.frameRate = 10; var rects =…
0
votes
0 answers

Generating and manipulating big raster

I'm working on a strategy game. One of the main mechanics is that the game map can be manipulated. Change terrain, elevation and so on. The map is randomly generated and consists of a block of a specified size. This is the problem. If I generate say…
0
votes
1 answer

How do i distribute the influence of different world generators to generate terrain?

My applogies for the title as I do not know the correct term for my problem. I'm using Simplex Noise (with 8 octaves) to generate a height map for my terrain. To get the terrain blend in, I calculated which biome fits the location best using a…
hampus toft
  • 55
  • 10
0
votes
1 answer

Unity - Deleting other instances spawning on top of another, but keeping the original

So, I am working on some level generation stuff in Unity, and I have some cubes spawning around the world. The way I have it working right now, is that each floor tile checks if there is 'air' around it and if so, it spawns a wall. But, if I have a…
Ben Lusted
  • 15
  • 3
0
votes
2 answers

How to fix "Thread 1: Fatal error: Unexpectedly found nil while implicitly unwrapping an Optional value" error in Swift?

I'm currently taking an iOS game development course on Make School. The first step in this course is to. make a game which is similar to flappy bird, with some of the basics like procedural generation and infinite scrolling, so on so forth. I am not…
0
votes
0 answers

Splitting rectangles for binary space partitioning, don't know how to position them

Sorry if the title isn't clear, I'm not really sure how to word this. I'm very new to this, so if I'm not clear on something just ask and I can try and word it better. I am using binary space partitioning for procedural level generation in a 2d…
0
votes
1 answer

3D Cylinder how to calculate vertexSize, indicesSize and textCoordinateSize In openGl

I am trying to draw a 3D cylinder by LWJGL, and i am trying to generate the vertices, indices and textCoordinate and storing them in arrays , but i am stuck how to calculate the size of the vertices, indices and textCoordinate…
Mohamad_Hn
  • 55
  • 1
  • 6