feat: atlas tile color modulation

This commit is contained in:
2025-07-26 15:06:27 -05:00
parent 9066b2cdbc
commit a1d37a1a0b
12 changed files with 80 additions and 78 deletions

View File

@@ -1,3 +1,4 @@
use std::cell::RefCell;
use std::rc::Rc;
use crate::texture::sprite::{AtlasTile, SpriteAtlas};
@@ -8,6 +9,6 @@ pub mod directional;
pub mod sprite;
pub mod text;
pub fn get_atlas_tile(atlas: &Rc<SpriteAtlas>, name: &str) -> AtlasTile {
pub fn get_atlas_tile(atlas: &Rc<RefCell<SpriteAtlas>>, name: &str) -> AtlasTile {
SpriteAtlas::get_tile(atlas, name).unwrap_or_else(|| panic!("Could not find tile {}", name))
}