1
Fork 0
mirror of https://github.com/redstrate/Kawari.git synced 2025-04-20 14:47:45 +00:00

Update dependencies, remove Physis chardat workaround

This commit is contained in:
Joshua Goins 2025-03-31 17:26:56 -04:00
parent b04fd6e8e1
commit 1a7da9d662
4 changed files with 22 additions and 21 deletions

18
Cargo.lock generated
View file

@ -473,9 +473,9 @@ dependencies = [
[[package]] [[package]]
name = "hyper-util" name = "hyper-util"
version = "0.1.10" version = "0.1.11"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4" checksum = "497bbc33a26fdd4af9ed9c70d63f61cf56a938375fbb32df34db9b1cd6d643f2"
dependencies = [ dependencies = [
"bytes", "bytes",
"futures-util", "futures-util",
@ -581,9 +581,9 @@ checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e"
[[package]] [[package]]
name = "log" name = "log"
version = "0.4.26" version = "0.4.27"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" checksum = "13dc2df351e3202783a1fe0d44375f7295ffb4049267b0f3018346dc122a1d94"
[[package]] [[package]]
name = "lua-src" name = "lua-src"
@ -640,9 +640,9 @@ checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"
[[package]] [[package]]
name = "minijinja" name = "minijinja"
version = "2.8.0" version = "2.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6e36f1329330bb1614c94b78632b9ce45dd7d761f3304a1bed07b2990a7c5097" checksum = "98642a6dfca91122779a307b77cd07a4aa951fbe32232aaf5bad9febc66be754"
dependencies = [ dependencies = [
"serde", "serde",
] ]
@ -751,7 +751,7 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e"
[[package]] [[package]]
name = "physis" name = "physis"
version = "0.4.0" version = "0.4.0"
source = "git+https://github.com/redstrate/physis#a34361b9560a95bdd257ee4fe721dbe1156a5610" source = "git+https://github.com/redstrate/physis#d2e724227b3297025d51e5899a32827b0a74cd49"
dependencies = [ dependencies = [
"binrw", "binrw",
"bitflags 1.3.2", "bitflags 1.3.2",
@ -1012,9 +1012,9 @@ checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd"
[[package]] [[package]]
name = "socket2" name = "socket2"
version = "0.5.8" version = "0.5.9"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c970269d99b64e60ec3bd6ad27270092a5394c4e309314b18ae3fe575695fbe8" checksum = "4f5fd57c80058a56cf5c777ab8a126398ece8e442983605d280a44ce79d0edef"
dependencies = [ dependencies = [
"libc", "libc",
"windows-sys 0.52.0", "windows-sys 0.52.0",

View file

@ -67,7 +67,7 @@ tracing-subscriber = { version = "0.3", features = ["fmt"], default-features = f
rand = { version = "0.9", features = ["std", "thread_rng"], default-features = false } rand = { version = "0.9", features = ["std", "thread_rng"], default-features = false }
# HTML templates used in the web servers # HTML templates used in the web servers
minijinja = { version = "2.8", features = ["serde"], default-features = false } minijinja = { version = "2.9", features = ["serde"], default-features = false }
# Serialization of packets # Serialization of packets
binrw = { version = "0.14", features = ["std"], default-features = false } binrw = { version = "0.14", features = ["std"], default-features = false }
@ -89,4 +89,4 @@ bitflags = { version = "1.3", default-features = false }
mlua = { version = "0.10", features = ["lua51", "vendored", "send", "async"], default-features = false } mlua = { version = "0.10", features = ["lua51", "vendored", "send", "async"], default-features = false }
# For character backup decompression # For character backup decompression
zip = { version = "2.2", features = ["deflate", "lzma", "bzip2"], default-features = false } zip = { version = "2.5", features = ["deflate", "lzma", "bzip2"], default-features = false }

View file

@ -35,11 +35,11 @@ pub struct CustomizeData {
impl From<physis::chardat::CustomizeData> for CustomizeData { impl From<physis::chardat::CustomizeData> for CustomizeData {
fn from(value: physis::chardat::CustomizeData) -> Self { fn from(value: physis::chardat::CustomizeData) -> Self {
Self { Self {
race: value.race as u8 + 1, race: value.race as u8,
gender: value.gender as u8, gender: value.gender as u8,
age: value.age, age: value.age,
height: value.height, height: value.height,
subrace: value.subrace as u8 + 1, subrace: value.tribe as u8,
face: value.face, face: value.face,
hair: value.hair, hair: value.hair,
enable_highlights: value.enable_highlights as u8, enable_highlights: value.enable_highlights as u8,

View file

@ -21,24 +21,25 @@ impl GameData {
pub fn new() -> Self { pub fn new() -> Self {
let config = get_config(); let config = get_config();
let mut game_data = physis::gamedata::GameData::from_existing( let mut game_data =
Platform::Win32, physis::gamedata::GameData::from_existing(Platform::Win32, &config.game_location)
&config.game_location, .unwrap();
).unwrap();
let mut item_pages = Vec::new(); let mut item_pages = Vec::new();
let item_exh = game_data.read_excel_sheet_header("Item").unwrap(); let item_exh = game_data.read_excel_sheet_header("Item").unwrap();
for (i, _) in item_exh.pages.iter().enumerate() { for (i, _) in item_exh.pages.iter().enumerate() {
item_pages.push(game_data item_pages.push(
.read_excel_sheet("Item", &item_exh, Language::English, i) game_data
.unwrap()); .read_excel_sheet("Item", &item_exh, Language::English, i)
.unwrap(),
);
} }
Self { Self {
game_data, game_data,
item_exh, item_exh,
item_pages item_pages,
} }
} }