Skip to content

Commit

Permalink
final stream fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
bananaturtlesandwich committed Apr 16, 2023
1 parent d962d96 commit 4c750b2
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 21 deletions.
Binary file added src/Cinzel-Regular.ttf
Binary file not shown.
15 changes: 14 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ fn ask_game_path() -> Option<std::path::PathBuf> {
fn get_pak_str(pak: &std::path::PathBuf) -> String {
let mut pak_str = pak.to_str().unwrap_or_default().to_string();
pak_str.truncate(pak_str.len() - 13);
pak_str = "...".to_string() + &pak_str[(pak_str.len() - 40).clamp(0, 1000)..];
pak_str = "...".to_string() + &pak_str[(pak_str.len() - 50).clamp(0, 1000)..];
pak_str
}

Expand Down Expand Up @@ -147,6 +147,19 @@ macro_rules! notify {
impl eframe::App for Rando {
fn update(&mut self, ctx: &eframe::egui::Context, _: &mut eframe::Frame) {
use eframe::egui;

let mut fonts = egui::FontDefinitions::default();
fonts.font_data.insert(
"cinzel".to_string(),
egui::FontData::from_static(include_bytes!("Cinzel-Regular.ttf")),
);
fonts
.families
.get_mut(&egui::FontFamily::Proportional)
.unwrap()
.insert(0, "cinzel".to_string());
ctx.set_fonts(fonts);

egui::CentralPanel::default().show(ctx, |ui| {
ui.horizontal(|ui| {
ui.heading(
Expand Down
39 changes: 20 additions & 19 deletions src/logic/checks.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use super::*;
use crate::{no_walljump, walljump};

pub const CHECKS: [Check; 255] = [
pub const CHECKS: [Check; 252] = [
// Fire Keep
Check {
location: Locations::Lab,
Expand Down Expand Up @@ -955,24 +955,25 @@ pub const CHECKS: [Check; 255] = [
drop: Drop::Tunic(Tunics::ForestTunic),
locks: &[],
},
Check {
location: Locations::TempleGardens,
context: Context::Shop(Shop::Nilo, 0, 1500),
drop: Drop::Item(Items::EmeraldOre, 1),
locks: &[Lock::Money(1500)],
},
Check {
location: Locations::TempleGardens,
context: Context::Shop(Shop::Nilo, 1, 800),
drop: Drop::Item(Items::SapphireOre, 1),
locks: &[Lock::Money(800)],
},
Check {
location: Locations::TempleGardens,
context: Context::Shop(Shop::Nilo, 2, 500),
drop: Drop::Item(Items::RubyOre, 1),
locks: &[Lock::Money(500)],
},
// editing the savegame doesn't edit unlike other shops
// Check {
// location: Locations::TempleGardens,
// context: Context::Shop(Shop::Nilo, 0, 1500),
// drop: Drop::Item(Items::EmeraldOre, 1),
// locks: &[Lock::Money(1500)],
// },
// Check {
// location: Locations::TempleGardens,
// context: Context::Shop(Shop::Nilo, 1, 800),
// drop: Drop::Item(Items::SapphireOre, 1),
// locks: &[Lock::Money(800)],
// },
// Check {
// location: Locations::TempleGardens,
// context: Context::Shop(Shop::Nilo, 2, 500),
// drop: Drop::Item(Items::RubyOre, 1),
// locks: &[Lock::Money(500)],
// },
Check {
location: Locations::TempleGardens,
context: Context::Overworld("Dance_Platform_Wave_Chest"),
Expand Down
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ fn main() -> Result<(), eframe::Error> {
eframe::run_native(
"",
eframe::NativeOptions {
initial_window_size: Some(eframe::epaint::Vec2::new(400.0, 360.0)),
initial_window_size: Some(eframe::epaint::Vec2::new(500.0, 390.0)),
resizable: false,
icon_data: Some(eframe::IconData {
rgba: include_bytes!("umby.rgba").to_vec(),
Expand Down
1 change: 1 addition & 0 deletions src/writing/overworld.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ pub fn write(
(0.0, 0.0, 100.0)
}
Locations::WaterwayDucks => (800.0, 0.0, 100.0),
Locations::Queen => (500.0, -500.0, 0.0),
_ => (0.0, 0.0, 0.0),
},
);
Expand Down

0 comments on commit 4c750b2

Please sign in to comment.