procedural generation
107 subscribers
4.57K photos
1.36K videos
2 files
10K links
Created by @r_channels
Download Telegram
Media is too big
VIEW IN TELEGRAM
Working on a Procedural Village Generator – I Would Love Some Feed Back. What Visuals or Features Would Make It Really Pop?

https://redd.it/1lvt9ex
@proceduralgeneration
Looking for advice on how to classify terrain based on a height map

To be brief I am trying to make an island generator that sets tiles based on height; however, I was wondering if there was a more efficient way to loop through different tiles and assign based on height rather than just a bunch of if statements. Additionally I am using a random function bounded by ranges that i feel are reasonable(they might not be I'm new to this) to give a more varied result. here is the code in GD script (\~ python) if my explanation was unsatisfactory

extends TileMapLayer



#constants

var map_size := 300

var gradient:=.45 # must be 0<x<.5 effects how far out the island can go with a max value of .5



# __innit__

var fnl := FastNoiseLite.new()

var random := RandomNumberGenerator.new()



#Fast_Noise_Light -----------------------------------------------------

# General

var frequency := Vector2(0.01, 0.1) # Scale, larger = smoother, smaller = more detial



# Fractal

var f_octaves := Vector2(3, 8) # layers of noise

var f_lacuranity := Vector2(1.5, 3.0) # essentially applies zoom to an octave

var F_gain := Vector2(0.3, 0.7) # Strength of each subsequent octave

var f_weighted_strength := Vector2(0.0, 1.0) #str of subsequent octaves blending

var f_ping_pong_strength := Vector2(0.0, .5) # cuases more repetitive terrain, well keep this low



# Domain Warp

var dm_amplitude := Vector2(5.0, 30.0) # Warp strength

var dm_frequency := Vector2(0.01, 0.1) # Frequency for warp, same general concept



# Domain Warp Fractal

var dwf_octaves := Vector2(2, 5) #^ but for warp

var dwf_lacuranity := Vector2(2.0, 6.0) #^ but for warp

var dwf_gain := Vector2(0.3, 0.7) #^ but for warp











# Called when the node enters the scene tree for the first time.

func _ready() -> void:

fnl.seed = randi()

fnl.noise_type = FastNoiseLite.TYPE_SIMPLEX_SMOOTH

fnl.frequency = random.randf_range(frequency.x, frequency.y)

fnl.fractal_octaves = random.randi_range(f_octaves.x, f_octaves.y)

fnl.fractal_lacunarity = random.randf_range(f_lacuranity.x, f_lacuranity.y)

fnl.fractal_gain = random.randf_range(F_gain.x, F_gain.y)

fnl.fractal_weighted_strength = random.randf_range(f_weighted_strength.x, f_weighted_strength.y)

fnl.fractal_ping_pong_strength = random.randf_range(f_ping_pong_strength.x, f_ping_pong_strength.y)

fnl.domain_warp_amplitude = random.randf_range(dm_amplitude.x, dm_amplitude.y)

fnl.domain_warp_frequency = random.randf_range(dm_frequency.x, dm_frequency.y)

fnl.domain_warp_fractal_octaves = random.randi_range(dwf_octaves.x, dwf_octaves.y)

fnl.domain_warp_fractal_lacunarity = random.randf_range(dwf_lacuranity.x, dwf_lacuranity.y)

fnl.domain_warp_fractal_gain = random.randf_range(dwf_gain.x, dwf_gain.y)

generate_map()





# Called every frame. 'delta' is the elapsed time since the previous frame.

func _process(delta: float) -> void:

generate_map()



func border(noise_topo,x:int,y:int):

var center = Vector2(map_size/2,map_size/2)

var new_noise = fnl.get_noise_2d(x*.01,y*.01)

var current_pos = Vector2(x, y)

var euclid = (current_pos - center).length()

var max = euclid*gradient

var adjusted_val = max*noise_topo*30

noise_topo = adjusted_val+noise_topo

return noise_topo



pass

func generate_map():





for x in map_size:

for y in map_size:

var noise_topo:= fnl.get_noise_2d(x,y)

var noise_topo_2 = border(noise_topo,x,y)

if noise_topo_2 < -0.2:

set_cell(Vector2i(x, y), 0, Vector2i(2, 4)) # Water

elif noise_topo_2 < 0.4:

set_cell(Vector2i(x, y), 0, Vector2i(0, 4)) # Grass

else:

set_cell(Vector2i(x, y), 0, Vector2i(4, 4)) # Stone



https://redd.it/1lvwpks
@proceduralgeneration
House/Room Layout Generation Paper

I've become borderline obsessed with house exterior and interior runtime generation, but I've struggled to find resources that don't rely on AI to make it happen.

I also run a game developer nonprofit in Montreal, and one of our discord members and event regulars shared this paper with me on generating building interiors.

Once I'm finished work for the day, I plan on trying to implement it in Unity (since that's where most of my proc gen work goes to die), but I wanted to share it with everyone here as an interesting take on interior generation based on parameters like building areas.

I would love to be able to one day generate a city, all the way down to explorable buildings, and this paper does seem promising for a good start at least.

If anyone has other resources or better processes, consider this post as an open invitation to be a resource dump :)
https://onlinelibrary.wiley.com/doi/10.1155/2010/624817

https://redd.it/1lwali8
@proceduralgeneration
Any nTop users in here? I just made a tutorial on procedural staircases 😁
https://redd.it/1lwtmm2
@proceduralgeneration
What do you say to people who claim procedural generation is lazy, not your work, or disrespectful to creatives?

Or to people who mix it up with the nebulous category of AI (power-intensive NN models trained on scraped data)?

One classmate tried to tell me that procedural generation was an insult to his time!

https://redd.it/1lxw627
@proceduralgeneration
Dissertation Showcase - Exploring a Large NPC Ecosystem in a Procedurally Generated Voxel Environment in UE5

https://reddit.com/link/1ly4sue/video/ep1yrmpq1hcf1/player

This subreddit really motivated me for the past year to complete my dissertation and have my own procedural generation focused project. I'm happy with how it turned out and wanted to share it with the community.

The project was done solely in C++ using Unreal Engine 5, and besides the purchased 3D assets for the NPCs, everything is generated at runtime.

https://preview.redd.it/a7ncjqltzgcf1.png?width=3439&format=png&auto=webp&s=1b45521e7012d6f76d78b831ecf5b1c3856ce868

https://preview.redd.it/c300mwkuzgcf1.png?width=3439&format=png&auto=webp&s=166c50473f809a9cbccfdb3167ff598ecfb97bd0

# Some performance metrics

Computation Averages for 150 NPCs Over 60 Seconds

Pathfinding Tasks: 1,705
Actions Requested: 1,501
Notifications Sent: 1,086
Vision Sphere Updates: 30,759

https://preview.redd.it/afl9gc1jzgcf1.png?width=2000&format=png&auto=webp&s=f5ba8a463c9264fb1d44d589e6b8459e7da5b133

https://redd.it/1ly4sue
@proceduralgeneration
ideal method to place rocks/trees etc. on a map with procedural generation?

I currently have a map with diff areas designated for various biomes, problem is when I try to use WFC to place landscape elements like trees/rocks around the map my laptop simply struggles. I even made the mistake of trying to generate individual tiles with WFC in biomes(you can guess how that went). I'm probably going to use noise for the ground layer(is this optimal?) of terrain but I still am unsure about how to generate landscape elements organically. I could of course multi thread it, assuming Godot has that feature - I'm new to this.

bit rough, still in development



https://redd.it/1lylp02
@proceduralgeneration
Proc Gen Resource List

So a little backstory: last year I created a game development community and last month I turned it into a non-profit organization aimed at providing more resources to game developers. Based in the Montreal area, we've grown to just below 500 people on the server in a year. One of our regular events attendees shared this gold mine of a procedural generation resource into our resources channel:

A massive link library to all kinds of papers and talks about procedural generation. I'm sure the info was shared somewhere in this subreddit, but if not then consider this my gift to the community:

https://procgen.space/resources

https://redd.it/1lzlaz2
@proceduralgeneration
What's your biggest problem with procedural generation in game design / development?

Want to invest some time in procedural generation skills, and feels like huge part of it is knowing weaknesses.

https://redd.it/1m0abtj
@proceduralgeneration