Refactored ModelCache into a module, misc. fixes due to change.

This commit is contained in:
2020-05-07 21:45:03 -05:00
parent bc480f9fae
commit bc695df4a1
5 changed files with 31 additions and 57 deletions

View File

@@ -60,7 +60,7 @@ class IMICFPS
hash = @assets[@asset_index]
case hash[:type]
when :model
ModelCache.new(manifest: hash[:manifest], entity: @dummy_entity)
ModelCache.find_or_cache(manifest: hash[:manifest])
when :shader
if window.config.get(:debug_options, :use_shaders)
shader = Shader.new(name: hash[:name], includes_dir: "shaders/include", vertex: "shaders/vertex/#{hash[:name]}.glsl", fragment: "shaders/fragment/#{hash[:name]}.glsl")