Changed const ref to a normal parameter on the get_key methods. This fixes a crash.

This commit is contained in:
Relintai 2021-08-02 22:34:07 +02:00
parent 4dad639cc6
commit 16fe978c41
2 changed files with 6 additions and 6 deletions

View File

@ -69,7 +69,7 @@ Ref<Material> TerramanLibrary::material_lod_get(const int index) {
return _materials[index];
}
void TerramanLibrary::material_cache_get_key(const Ref<TerraChunk> &chunk) {
void TerramanLibrary::material_cache_get_key(Ref<TerraChunk> chunk) {
call("_material_cache_get_key", chunk);
}
@ -143,7 +143,7 @@ Ref<Material> TerramanLibrary::liquid_material_lod_get(const int index) {
return _liquid_materials[index];
}
void TerramanLibrary::liquid_material_cache_get_key(const Ref<TerraChunk> &chunk) {
void TerramanLibrary::liquid_material_cache_get_key(Ref<TerraChunk> chunk) {
call("_liquid_material_cache_get_key", chunk);
}
@ -217,7 +217,7 @@ Ref<Material> TerramanLibrary::prop_material_lod_get(const int index) {
return _prop_materials[index];
}
void TerramanLibrary::prop_material_cache_get_key(const Ref<TerraChunk> &chunk) {
void TerramanLibrary::prop_material_cache_get_key(Ref<TerraChunk> chunk) {
call("_prop_material_cache_get_key", chunk);
}

View File

@ -72,7 +72,7 @@ public:
Ref<Material> material_get(const int index);
Ref<Material> material_lod_get(const int index);
void material_cache_get_key(const Ref<TerraChunk> &chunk);
void material_cache_get_key(Ref<TerraChunk> chunk);
virtual void _material_cache_get_key(Ref<TerraChunk> chunk);
Ref<TerraMaterialCache> material_cache_get(const int key);
virtual Ref<TerraMaterialCache> _material_cache_get(const int key);
@ -89,7 +89,7 @@ public:
Ref<Material> liquid_material_get(const int index);
Ref<Material> liquid_material_lod_get(const int index);
void liquid_material_cache_get_key(const Ref<TerraChunk> &chunk);
void liquid_material_cache_get_key(Ref<TerraChunk> chunk);
virtual void _liquid_material_cache_get_key(Ref<TerraChunk> chunk);
Ref<TerraMaterialCache> liquid_material_cache_get(const int key);
virtual Ref<TerraMaterialCache> _liquid_material_cache_get(const int key);
@ -106,7 +106,7 @@ public:
Ref<Material> prop_material_get(const int index);
Ref<Material> prop_material_lod_get(const int index);
void prop_material_cache_get_key(const Ref<TerraChunk> &chunk);
void prop_material_cache_get_key(Ref<TerraChunk> chunk);
virtual void _prop_material_cache_get_key(Ref<TerraChunk> chunk);
Ref<TerraMaterialCache> prop_material_cache_get(const int key);
virtual Ref<TerraMaterialCache> _prop_material_cache_get(const int key);