Benoît du Garreau
dda54e6ee2
Update assets_manager
to 0.6.0
2021-10-01 21:13:01 +02:00
juliancoffee
29d91cdd6a
Add support for override asset folder
...
- ASSETS_OVERRIDE environment variable with asset path which has higher
priority.
2021-09-02 20:24:23 +03:00
juliancoffee
ce04dd5c69
Adress review, add test for structs
2021-08-06 13:04:01 +03:00
juliancoffee
d4d6072c03
Add asset_tweak macros
2021-08-03 16:31:13 +03:00
juliancoffee
f9733b58cb
Remove redundant serial_test crate
2021-08-03 16:31:13 +03:00
juliancoffee
b6cfd06724
Add ability to specify directory in asset_tweak
2021-08-03 16:31:13 +03:00
juliancoffee
4630237739
Remove clone() for creating new tweak file
2021-08-03 16:31:13 +03:00
juliancoffee
bf8acca375
Introduce helper functions and deduplicate docs
2021-08-03 16:31:13 +03:00
Benoît du Garreau
ab6105d789
Add a feature to optionnally disable hot-reloading
2021-07-06 00:27:09 +02:00
juliancoffee
63aa4219c5
Remove load_expect_dir
as it's misused
...
- load_expect_dir while expected to fail on erros, fails only on
filesystem errors and only on root directory.
This commit replaces this function with `read_expect_dir` which returns iterator
which loads all files and panics if can't load them.
2021-07-05 20:14:26 +03:00
juliancoffee
5157b84f2f
Run asset_tweak tests separately
...
+ Make parse_all_ron_files_to_value panic-friendly. Remove unwraps
to unwrap_or_else with panic message.
2021-07-04 19:31:57 +03:00
eckso
43bc40c7d5
Fix #1158 - Add a test that all the .ron
manifests parse
2021-07-03 18:11:04 +00:00
juliancoffee
f4d457bc04
Better error signaling in assets::load_dir_expect
2021-06-30 21:06:06 +03:00
Benoît du Garreau
ab3c8cf764
Update assets_manager
to 0.5
2021-06-26 12:05:40 +02:00
Joshua Barretto
6f6a7e3617
Removed .jpeg as valid image format (to encourage consistency)
2021-06-18 12:42:08 +01:00
Joshua Barretto
38907a8bf2
Added support for JPEG backgrounds
2021-06-18 12:27:39 +01:00
Marcel Märtens
d291a71f79
Change the version number to 0.10
2021-06-12 10:14:07 +02:00
juliancoffee
6ffbbe85bd
serialize AssetTweakWrapper<T>, not just T
...
asset_tweak::tweak_expect_or_create works by writing default data to
file and then read it as asset.
the problem is that it was writing T, and read AssetTweakWrapper<T>
which are different types.
Tests didn't handle case when you will load data back so bug was hidden.
2021-06-08 22:39:51 +03:00
juliancoffee
e5d2c66cb8
put serde behind feature gate
2021-06-08 14:03:15 +03:00
juliancoffee
849ee4f18a
Fix find_root() search in case if .git isn't dir
2021-06-08 13:34:46 +03:00
juliancoffee
8c28e29056
place asset_tweak behind a feature
2021-06-08 13:34:41 +03:00
juliancoffee
7eacee7a85
More tests, support only assets/tweak
directory
...
- Use `serial_test` because tests can't run in parallel as both of them
are accessing fs.
- Take only filename, use hardcoded `assets/tweak` to keep it simple and
support .gitignore
2021-06-08 13:31:27 +03:00
juliancoffee
932ff7d42b
add asset_tweak_or_create
that will create file
2021-06-08 13:31:27 +03:00
juliancoffee
beeea5830b
New tweak_expect
fn to tweak values from .ron
...
- Function to tweak values via temporary hot-reloaded .ron files
2021-06-08 13:31:27 +03:00
Marcel
b044253d52
Merge branch 'alphyr/guess_image_format' into 'master'
...
Guess image format from file extension
See merge request veloren/veloren!2260
2021-05-12 18:41:22 +00:00
juliancoffee
7bec0bc529
add authors
2021-05-09 13:12:26 +03:00
juliancoffee
ab2ee20ba3
Fix tests
...
1) Use more correct way to look for `assets` dir
2) Rename veloren_common::assets to veloren_common_assets in doc-tests
2021-05-09 13:12:26 +03:00
juliancoffee
d4fd0d6b96
Search for assets in workspace root
2021-05-09 13:12:26 +03:00
juliancoffee
5bd4dcc167
Extract common/src/assets.rs to own crate
...
This gives us ability to use assets-related code in i18n without
depending on whole veloren-common
2021-05-09 13:12:26 +03:00