Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Biomes "Object reference not set to an instance of an object" #33

Open
OfficialSammyTheWolf opened this issue Feb 27, 2021 · 2 comments

Comments

@OfficialSammyTheWolf
Copy link

I was trying to add Biomes to the generator, i tried to make new BiomeData scriptable Object and just copy every single variable function etc from other Data functions into that, everything was working but i has issue that i was using just one scriptable Object that i put into Mapgenerator and then use values from that, but then i just tried to create something that will generate Random Biome to each chunk and then use information from that Biome Data of each chunk, i tried to create an instance for the Chunk script and then just replace everything like noiseData.NoiseScale etc to Chunk.instance.biomeData.NoiseScale, everything as working until OnValidate function in Mapgenerator where the script check if the data is not null and then unsubscribe from OnValuesUpdated and then again subscribe to OnValuesUpdated, i just repalced every Data.OnValuesUpdated to Chunk.instance.biomeData.OnValuesUpdated and even in the if statements, but then the first if statement return error "Object reference not set to an instance of an object"

@Fodk44
Copy link

Fodk44 commented Feb 20, 2022

Can you send the code so we can know which object is null ?

@SteenPetersen
Copy link

@OfficialSammyTheWolf Did you manage to get biomes working with this project, if so Id be very interested to see how you did it as I am looking to learn how that could be done.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants