bcthund / Project_Parsec

1 stars 0 forks source link

Map load() method update #34

Closed bcthund closed 3 years ago

bcthund commented 3 years ago

The load method currently takes all data to load all parts of the map instance. It should be specialized to only load the items we request. This will allow the loader to use different ranges for loading different things. For example trees don't need to be loaded at max view distance because they wont be drawn that far away anyways, so only load trees within a certain distance. This could substantially reduce the amount of data loaded.

bcthund commented 3 years ago

Also change MapInstance to have a pointer to noise functions, that way we can call load for a requested item but not have to supply the noise function unless we want to override it. Some load functions require other noise functions to be defined before they will work so this should simplify the function and also reduce the number of arguments that need to get passed to the load method.

bcthund commented 3 years ago

Branch 0034 created MapBase and MapInstance which now use pointers to noise functions and MapBase has global map data that all noise functions may need to access.