Skip to content

Commit

Permalink
Fix: Recotte studioに対応
Browse files Browse the repository at this point in the history
  • Loading branch information
sevenc-nanashi committed May 31, 2024
1 parent 45640dc commit e08e021
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion crates/cantari/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ async fn main_impl(args: Cli) -> Result<()> {
{
let ongens = ONGEN.get().unwrap().read().await;
for ongen in ongens.values() {
info!("- {} ({})", ongen.name(), ongen.uuid);
info!("- {} ({}, {})", ongen.name(), ongen.uuid, ongen.id());
}
}

Expand Down
2 changes: 1 addition & 1 deletion crates/cantari/src/ongen.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ impl Ongen {
pub fn id(&self) -> u32 {
let uuid_string = self.uuid.to_string();
let uuid_first_section = uuid_string.split('-').next().unwrap();
u32::from_str_radix(uuid_first_section, 16).unwrap() & !(0xffu32)
(u32::from_str_radix(uuid_first_section, 16).unwrap() >> 1) & !(0xffu32)
}

pub async fn read_image(&self) -> Option<Vec<u8>> {
Expand Down

0 comments on commit e08e021

Please sign in to comment.