NitroxNova / humanizer

convert MakeHuman to Godot4
The Unlicense
149 stars 15 forks source link

HumanizerAPI global #37

Closed michae107 closed 5 days ago

michae107 commented 6 days ago

Add HumanizerAPI global class with generate_random_human() that returns the CharacterBody3D of a randomly generated human. Automatically create res://humanizer_global_config.res in the project root directory if it doesn't exist. Rename Humanizer.load_config to load_config_async to reflect it's async-ness (3 hours of debugging that =]). add missing main_collider null check when saving scene

RavinMaddHatter commented 5 days ago

I think you may at some point want arguments in that function... Or some sort of reference. The reason I bring it up, is one logical reason to do it this way is to generate non player characters, and depending upon the game, you may want some people from some backgrounds to be on average short, skinny and generally young (to integrate indicate a malnourished background) in other cases, you may want to generate people with posh clothing.

Truly random is usually bad for a game, I think thematically random (eventually) would be good.

All this to say, if it is a Singleton, I think it needs to have some arguments, if it is a general class, you can change the ranges and keep 10 constructors for your "factions" or "species"

michae107 commented 5 days ago

I think you may at some point want arguments in that function... Or some sort of reference. The reason I bring it up, is one logical reason to do it this way is to generate non player characters, and depending upon the game, you may want some people from some backgrounds to be on average short, skinny and generally young (to integrate indicate a malnourished background) in other cases, you may want to generate people with posh clothing.

Truly random is usually bad for a game, I think thematically random (eventually) would be good.

All this to say, if it is a Singleton, I think it needs to have some arguments, if it is a general class, you can change the ranges and keep 10 constructors for your "factions" or "species"

This pull request was a bit premature but I'm going to be adding more to the API, you'll be able to pass a HumanConfig to another method to generate from config and it'll probably have a callback to have some access to modify the parameters before it generates the final character body. I also have some other things coming today or tomorrow to increase performance and throughput of the human generation and remove the stuttering in-game when generating characters.

NitroxNova commented 5 days ago

i think these are good changes, only thing is i'll probably move the randomizer to a static resource in services, but am going to accept and leave it for now, thank you for contributing! if you'd like to check out the discord, https://discord.gg/sQWar92A , we've got a thread open to discuss the possible use cases and implementations for the randomizer , would like to get your input