diff --git a/export_presets.cfg b/export_presets.cfg index 0053b25..0618c92 100644 --- a/export_presets.cfg +++ b/export_presets.cfg @@ -9,7 +9,7 @@ custom_features="" export_filter="all_resources" include_filter="" exclude_filter="builds/*,playtest/*,scripts/*" -export_path="builds/v0.5.0-prealpha/windows-x86_64/NETfishing.exe" +export_path="builds/v0.5.1-prealpha/windows-x86_64/NETfishing.exe" patches=PackedStringArray() encryption_include_filters="" encryption_exclude_filters="" @@ -35,11 +35,11 @@ application/modify_resources=true application/icon="" application/console_wrapper_icon="" application/icon_interpolation=4 -application/file_version="0.5.0.0" -application/product_version="0.5.0.0" +application/file_version="0.5.1.0" +application/product_version="0.5.1.0" application/company_name="" application/product_name="NETfishing" -application/file_description="NETfishing v0.5.0-prealpha" +application/file_description="NETfishing v0.5.1-prealpha" application/copyright="" application/trademarks="" application/export_angle=0 @@ -51,6 +51,67 @@ ssh_remote_deploy/extra_args_scp="" ssh_remote_deploy/run_script="#!/usr/bin/env bash\nexport DISPLAY=:0\nunzip -o -q \"{temp_dir}/{archive_name}\" -d \"{temp_dir}\"\n\"{temp_dir}/{exe_name}\" {cmd_args}" ssh_remote_deploy/cleanup_script="#!/usr/bin/env bash\nkill $(pgrep -x -f \"{temp_dir}/{exe_name} {cmd_args}\")\nrm -rf \"{temp_dir}\"" +[preset.3] + +name="Linux ARM64" +platform="Linux" +runnable=false +advanced_options=false +dedicated_server=false +custom_features="" +export_filter="all_resources" +include_filter="" +exclude_filter="builds/*,playtest/*,scripts/*" +export_path="builds/v0.5.1-prealpha/linux-arm64/NETfishing.arm64" +patches=PackedStringArray() +encryption_include_filters="" +encryption_exclude_filters="" +seed=0 +encrypt_pck=false +encrypt_directory=false +script_export_mode=2 + +[preset.3.options] + +custom_template/debug="" +custom_template/release="" +debug/export_console_wrapper=0 +binary_format/embed_pck=false +binary_format/architecture="arm64" +texture_format/s3tc_bptc=true +texture_format/etc2_astc=false + +[preset.4] + +name="macOS" +platform="macOS" +runnable=false +advanced_options=false +dedicated_server=false +custom_features="" +export_filter="all_resources" +include_filter="" +exclude_filter="builds/*,playtest/*,scripts/*" +export_path="builds/v0.5.1-prealpha/macos/NETfishing.zip" +patches=PackedStringArray() +encryption_include_filters="" +encryption_exclude_filters="" +seed=0 +encrypt_pck=false +encrypt_directory=false +script_export_mode=2 + +[preset.4.options] + +custom_template/debug="" +custom_template/release="" +application/bundle_identifier="io.makearmy.netfishing" +application/short_version="0.5.1" +application/version="0.5.1" +application/architecture="universal" +codesign/enable=false +notarization/enable=false + [preset.2] name="Android" @@ -62,7 +123,7 @@ custom_features="" export_filter="all_resources" include_filter="" exclude_filter="builds/*,playtest/*,scripts/*" -export_path="builds/android/NETfishing-debug.apk" +export_path="builds/v0.5.1-prealpha/android/NETfishing.apk" patches=PackedStringArray() encryption_include_filters="" encryption_exclude_filters="" @@ -83,8 +144,8 @@ architectures/armeabi-v7a=false architectures/arm64-v8a=true architectures/x86=false architectures/x86_64=false -version/code=40100 -version/name="0.5.0-prealpha" +version/code=50100 +version/name="0.5.1-prealpha" package/unique_name="io.makearmy.netfishing" package/name="NETfishing" package/signed=true @@ -121,7 +182,7 @@ custom_features="" export_filter="all_resources" include_filter="" exclude_filter="builds/*,playtest/*,scripts/*" -export_path="builds/v0.5.0-prealpha/linux-x86_64/NETfishing.x86_64" +export_path="builds/v0.5.1-prealpha/linux-x86_64/NETfishing.x86_64" patches=PackedStringArray() encryption_include_filters="" encryption_exclude_filters="" diff --git a/playtest/README-PLAYTEST.txt b/playtest/README-PLAYTEST.txt index 553fc44..8116fc2 100644 --- a/playtest/README-PLAYTEST.txt +++ b/playtest/README-PLAYTEST.txt @@ -1,6 +1,6 @@ NETfishing -v0.5.0-prealpha -Pre-Alpha 0.5.0 +v0.5.1-prealpha +Pre-Alpha 0.5.1 Thank you for trying this early private playtest. diff --git a/progression/character_customization_catalog.gd b/progression/character_customization_catalog.gd index fe3b249..ddcf0b3 100644 --- a/progression/character_customization_catalog.gd +++ b/progression/character_customization_catalog.gd @@ -155,15 +155,21 @@ static func _ensure_feature_assets() -> void: if directory != null: var files := directory.get_files() files.sort() + var normalized_paths: Dictionary = {} for file_name: String in files: - if not file_name.to_lower().ends_with(".png"): + var normalized_file_name := _canonical_feature_filename(file_name) + if ( + normalized_file_name.is_empty() + or normalized_paths.has(normalized_file_name) + ): continue + normalized_paths[normalized_file_name] = true var option_id := _feature_id_from_filename( - category_id, file_name + category_id, normalized_file_name ) if option_id.is_empty() or textures.has(option_id): continue - var resource_path := root_path.path_join(file_name) + var resource_path := root_path.path_join(normalized_file_name) var texture := ResourceLoader.load(resource_path) as Texture2D if texture == null: push_warning( @@ -181,6 +187,18 @@ static func _ensure_feature_assets() -> void: _feature_textures[category_id] = textures +static func _canonical_feature_filename(file_name: String) -> String: + var lower_name := file_name.to_lower() + for sidecar_suffix: String in [".import", ".remap"]: + if lower_name.ends_with(".png" + sidecar_suffix): + return file_name.substr( + 0, file_name.length() - sidecar_suffix.length() + ) + if lower_name.ends_with(".png"): + return file_name + return "" + + static func _feature_id_from_filename( category_id: String, file_name: String, diff --git a/project.godot b/project.godot index 43d04a9..080c9f8 100644 --- a/project.godot +++ b/project.godot @@ -11,7 +11,7 @@ config_version=5 [application] config/name="NETFISHING" -config/version="0.5.0-prealpha" +config/version="0.5.1-prealpha" run/main_scene="res://main/main.tscn" config/features=PackedStringArray("4.7", "GL Compatibility") config/icon="res://icon.svg" diff --git a/scripts/build_playtest.sh b/scripts/build_playtest.sh index 2cc3e72..e984de3 100755 --- a/scripts/build_playtest.sh +++ b/scripts/build_playtest.sh @@ -4,12 +4,12 @@ set -euo pipefail readonly SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" readonly PROJECT_ROOT="$(cd -- "${SCRIPT_DIR}/.." && pwd)" -readonly BUILD_ROOT="${PROJECT_ROOT}/builds/v0.5.0-prealpha" +readonly BUILD_ROOT="${PROJECT_ROOT}/builds/v0.5.1-prealpha" readonly WINDOWS_DIR="${BUILD_ROOT}/windows-x86_64" readonly LINUX_DIR="${BUILD_ROOT}/linux-x86_64" readonly README_SOURCE="${PROJECT_ROOT}/playtest/README-PLAYTEST.txt" -readonly WINDOWS_ZIP="${BUILD_ROOT}/NETfishing-v0.5.0-prealpha-windows-x86_64.zip" -readonly LINUX_ZIP="${BUILD_ROOT}/NETfishing-v0.5.0-prealpha-linux-x86_64.zip" +readonly WINDOWS_ZIP="${BUILD_ROOT}/NETfishing-v0.5.1-prealpha-windows-x86_64.zip" +readonly LINUX_ZIP="${BUILD_ROOT}/NETfishing-v0.5.1-prealpha-linux-x86_64.zip" readonly GODOT_BIN="${GODOT_BIN:-godot}" if [[ ! -f "${PROJECT_ROOT}/project.godot" ]]; then diff --git a/tests/exported_decal_hotfix_validation.gd b/tests/exported_decal_hotfix_validation.gd new file mode 100644 index 0000000..be70325 --- /dev/null +++ b/tests/exported_decal_hotfix_validation.gd @@ -0,0 +1,47 @@ +extends SceneTree + + +func _initialize() -> void: + call_deferred("_run") + + +func _run() -> void: + assert( + CharacterCustomizationCatalog._canonical_feature_filename( + "eyes_alligator_eyes.png" + ) == "eyes_alligator_eyes.png" + ) + assert( + CharacterCustomizationCatalog._canonical_feature_filename( + "eyes_alligator_eyes.png.import" + ) == "eyes_alligator_eyes.png" + ) + assert( + CharacterCustomizationCatalog._canonical_feature_filename( + "eyes_alligator_eyes.png.remap" + ) == "eyes_alligator_eyes.png" + ) + assert( + CharacterCustomizationCatalog._canonical_feature_filename( + "eyes_alligator_eyes.jpg" + ).is_empty() + ) + + var expected_counts := {"eyes": 22, "mouth": 17, "nose": 17} + for category_id: String in expected_counts: + var options := CharacterCustomizationCatalog.options_for(category_id) + assert(options.size() == int(expected_counts[category_id]) + 1) + var seen_ids: Dictionary = {} + for option: Dictionary in options: + var option_id := str(option.get("id", "")) + assert(not seen_ids.has(option_id)) + seen_ids[option_id] = true + if option_id != "none": + assert( + CharacterCustomizationCatalog.texture_for( + category_id, option_id + ) != null + ) + + print("Exported decal hotfix validation: PASS") + quit() diff --git a/tests/exported_decal_hotfix_validation.gd.uid b/tests/exported_decal_hotfix_validation.gd.uid new file mode 100644 index 0000000..e75742a --- /dev/null +++ b/tests/exported_decal_hotfix_validation.gd.uid @@ -0,0 +1 @@ +uid://dolsbknm52hsy diff --git a/ui/title_screen.tscn b/ui/title_screen.tscn index 475a180..7f7d499 100644 --- a/ui/title_screen.tscn +++ b/ui/title_screen.tscn @@ -206,7 +206,7 @@ unique_name_in_owner = true layout_mode = 2 theme_override_colors/font_color = Color(0.682, 0.733, 0.761, 1) theme_override_font_sizes/font_size = 22 -text = "v0.5.0-prealpha" +text = "v0.5.1-prealpha" horizontal_alignment = 1 [node name="Spacer" type="Control" parent="ResponsiveTitleStage/TitlePresentationScaleRoot/Center/MainContent"]