FyroxEngine / Fyrox

3D and 2D game engine written in Rust
https://fyrox.rs
MIT License
7.51k stars 341 forks source link

Building error in new empty project #472

Closed san-smith closed 12 months ago

san-smith commented 12 months ago

Hi. I create a new empty project:

fyrox-template init --name my_game --style 3d

Then I run

cargo run --package editor --release

And I've got the error:

[ERROR]: Failed to load settings, fallback to default. Reason: Io(Os { code: 2, kind: NotFound, message: "No such file or directory" })
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: ParseError(SpannedError { code: ExpectedStructLike, position: Position { line: 40, col: 27 } })', /home/san-smith/.cargo/registry/src/index.crates.io-6f17d22bba15001f/fyrox-0.30.0/src/material/shader/mod.rs:634:69
mrDIMAS commented 12 months ago

Hi, this error comes from nalgebra's breaking changes, that were published as patch. To fix this, you need to update to latest version of the engine - https://fyrox-book.github.io/fyrox/beginning/scripting.html#using-the-latest-engine-version . I'll try to release 0.31 on this week.

san-smith commented 12 months ago

It works, thanks!

mrDIMAS commented 12 months ago

0.31 is now released and the issue is fixed there. Closing this one.

ktimam commented 10 months ago

Receiving same error. Running fyrox-template upgrade --version nightly command in game's directory doesn't fix the problem.

mrDIMAS commented 10 months ago

@ktimam I re-checked this on latest version of the engine and it does not reproduce. What's the dependencies versions in your Cargo.tomls?

ktimam commented 10 months ago

[package] name = "editor" version = "0.1.0" edition = "2021"

[dependencies] my_game = { path = "../game" }

[dependencies.fyrox ] git = "https://github.com/FyroxEngine/Fyrox"

[dependencies.fyroxed_base ] git = "https://github.com/FyroxEngine/Fyrox"

ktimam commented 10 months ago

Tried downloading the latest code and running "cargo run --example 2d_scene --release" Still gives the same error.

Edit: issue happens in wsl only (works fine on ubuntu os). The issue is related to audio: ALSA lib confmisc.c:855:(parse_card) cannot find card '0' ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:5701:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM default thread 'main' panicked at 'called Result::unwrap() on an Err value: Custom("\"No such file or directory\"")'