Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NoviGod #210

Merged
merged 8 commits into from
Dec 31, 2024
Merged

NoviGod #210

merged 8 commits into from
Dec 31, 2024

Conversation

Gersoon458
Copy link
Contributor

Описание PR

Нови годъ на станции + починен комод + скафандры у сб теперь нормальные


Изменения

🆑

  • add: New Year's map update/Новогоднее обновление карт
  • tweak: Security now has regular hardsuits, not EE ones/У СБ теперь обычные риги, а не ЕЕшные
  • tweak: The Christmas tree has a new texture/У Рождественской ёлки новая текстура
  • fix: Map bugs fixed/Пофикшены баги карт

Copy link
Contributor

coderabbitai bot commented Dec 26, 2024

Walkthrough

Этот обзор изменений охватывает модификации в нескольких файлах прототипов и ресурсов игры. Изменения включают обновление содержимого шкафчиков для различных ролей (например, начальника службы безопасности), корректировку спрайтов и метаданных для рождественских елок и комнатных растений, а также незначительные правки в конфигурации карт и мебели.

Changes

Файл Краткое описание изменений
Resources/Prototypes/Catalog/Fills/Lockers/heads.yml Обновлены предметы в шкафчике начальника службы безопасности
Resources/Prototypes/Catalog/Fills/Lockers/misc.yml Изменены списки лута для шкафчиков
Resources/Prototypes/Catalog/Fills/Lockers/security.yml Обновлены шкафчики службы безопасности и медперсонала
Resources/Prototypes/Catalog/Fills/Lockers/suit_storage.yml Добавлены новые шкафы для хранения костюмов
Resources/Prototypes/Entities/Objects/Decoration/flora.yml Обновлены рождественские елки с новыми эффектами
Resources/Prototypes/Entities/Structures/Furniture/dresser.yml Изменен спрайт комода
Resources/Prototypes/Maps/whitebox.yml Увеличено минимальное количество игроков

Suggested labels

Changes: Localization, Changes: Assets, Changes: Configuration

Suggested reviewers

  • Remuchi

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

github-actions bot commented Dec 26, 2024

RSI Diff Bot; head commit c4523d5 merging into 2132992
This PR makes changes to 1 or more RSIs. Here is a summary of all changes:

Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi

State Old New Status
dirt_small_1 Removed
dirt_small_2 Removed
dirt_small_3 Removed
dirt_small_4 Removed
dirt_small_5 Removed
dirt_small_6 Removed
dirt_tiny_1 Removed
dirt_tiny_2 Removed
dirt_tiny_3 Removed
dirt_tiny_4 Removed
dirt_tiny_5 Removed
dirt_tiny_6 Removed
plant_small_1 Removed
plant_small_10 Removed
plant_small_11 Removed
plant_small_12 Removed
plant_small_13 Removed
plant_small_14 Removed
plant_small_15 Removed
plant_small_16 Removed
plant_small_17 Removed
plant_small_18 Removed
plant_small_19 Removed
plant_small_2 Removed
plant_small_20 Removed
plant_small_3 Removed
plant_small_4 Removed
plant_small_5 Removed
plant_small_6 Removed
plant_small_7 Removed
plant_small_8 Removed
plant_small_9 Removed
plant_tiny_1 Removed
plant_tiny_2 Removed
plant_tiny_3 Removed
plant_tiny_4 Removed
plant_tiny_5 Removed
plant_tiny_6 Removed
plant_tiny_7 Removed
plant_tiny_8 Removed
plant_tiny_9 Removed
pot_small_1 Removed
pot_small_10 Removed
pot_small_2 Removed
pot_small_3 Removed
pot_small_4 Removed
pot_small_5 Removed
pot_small_6 Removed
pot_small_7 Removed
pot_small_8 Removed
pot_small_9 Removed
pot_tiny_1 Removed
pot_tiny_2 Removed
pot_tiny_3 Removed
pot_tiny_4 Removed
pot_tiny_5 Removed
pot_tiny_6 Removed
pot_tiny_7 Removed

Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi

State Old New Status
christmastree Added
glow Added
presents Added

Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi

State Old New Status
dirt_small_1 Added
dirt_small_2 Added
dirt_small_3 Added
dirt_small_4 Added
dirt_small_5 Added
dirt_small_6 Added
dirt_tiny_1 Added
dirt_tiny_2 Added
dirt_tiny_3 Added
dirt_tiny_4 Added
dirt_tiny_5 Added
dirt_tiny_6 Added
icon_spawner Added
mask_null Added
plant_small_1 Added
plant_small_10 Added
plant_small_11 Added
plant_small_12 Added
plant_small_13 Added
plant_small_14 Added
plant_small_15 Added
plant_small_16 Added
plant_small_17 Added
plant_small_18 Added
plant_small_19 Added
plant_small_2 Added
plant_small_20 Added
plant_small_3 Added
plant_small_4 Added
plant_small_5 Added
plant_small_6 Added
plant_small_7 Added
plant_small_8 Added
plant_small_9 Added
plant_tiny_1 Added
plant_tiny_2 Added
plant_tiny_3 Added
plant_tiny_4 Added
plant_tiny_5 Added
plant_tiny_6 Added
plant_tiny_7 Added
plant_tiny_8 Added
plant_tiny_9 Added
pot_small_1 Added
pot_small_10 Added
pot_small_2 Added
pot_small_3 Added
pot_small_4 Added
pot_small_5 Added
pot_small_6 Added
pot_small_7 Added
pot_small_8 Added
pot_small_9 Added
pot_tiny_1 Added
pot_tiny_2 Added
pot_tiny_3 Added
pot_tiny_4 Added
pot_tiny_5 Added
pot_tiny_6 Added
pot_tiny_7 Added

Edit: diff updated after c4523d5

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
Resources/Prototypes/Catalog/Fills/Lockers/heads.yml (1)

272-274: Обновление снаряжения главы службы безопасности одобрено!

Замена боевого скафандра на красный скафандр службы безопасности и добавление противогаза SWAT логично дополняют общие изменения в экипировке. Рекомендуется обновить документацию по снаряжению.

#!/bin/bash
# Поиск файлов документации для обновления
fd -e md -e txt -e yaml "equipment" "docs"
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2132992 and 5167dac.

⛔ Files ignored due to path filters (4)
  • Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi/christmastree.png is excluded by !**/*.png
  • Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi/glow.png is excluded by !**/*.png
  • Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi/presents.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/furniture.rsi/dresser.png is excluded by !**/*.png
📒 Files selected for processing (10)
  • Resources/Prototypes/Catalog/Fills/Lockers/heads.yml (1 hunks)
  • Resources/Prototypes/Catalog/Fills/Lockers/misc.yml (1 hunks)
  • Resources/Prototypes/Catalog/Fills/Lockers/security.yml (2 hunks)
  • Resources/Prototypes/Catalog/Fills/Lockers/suit_storage.yml (3 hunks)
  • Resources/Prototypes/Entities/Objects/Decoration/flora.yml (1 hunks)
  • Resources/Prototypes/Entities/Structures/Furniture/dresser.yml (1 hunks)
  • Resources/Prototypes/Maps/whitebox.yml (1 hunks)
  • Resources/Prototypes/Recipes/Construction/furniture.yml (1 hunks)
  • Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi/meta.json (1 hunks)
  • Resources/Textures/_White/Structures/Furniture/furniture.rsi/meta.json (1 hunks)
✅ Files skipped from review due to trivial changes (3)
  • Resources/Textures/_White/Structures/Furniture/furniture.rsi/meta.json
  • Resources/Prototypes/Recipes/Construction/furniture.yml
  • Resources/Textures/_White/Objects/Decoration/Flora/christmastree.rsi/meta.json
🔇 Additional comments (9)
Resources/Prototypes/Entities/Structures/Furniture/dresser.yml (1)

8-9: Корректные изменения спрайта и ротации!

Изменение пути к спрайту и добавление свойства noRot логично для данного типа мебели.

Resources/Prototypes/Entities/Objects/Decoration/flora.yml (2)

461-466: Отличные визуальные улучшения новогодней ёлки!

Добавление эффекта свечения и предотвращение вращения улучшают внешний вид и поведение ёлки.


469-479: Проверьте баланс выпадения подарков

Механика выдачи подарков реализована корректно, но рекомендуется проверить вероятности выпадения различных типов подарков для обеспечения баланса игры:

  • PresentRandom: 100% (базовый)
  • PresentRandomCash: 20%
  • PresentRandomAsh: 5%

Предлагаю добавить ограничение по времени между получением подарков для предотвращения злоупотребления механикой.

Resources/Prototypes/Maps/whitebox.yml (1)

5-5: Проверьте влияние изменения минимального количества игроков

Увеличение минимального количества игроков с 0 до 40 может значительно повлиять на доступность карты. Убедитесь, что:

  • Это соответствует среднему количеству игроков на сервере
  • Карта действительно требует такого количества игроков для баланса
✅ Verification successful

Изменение минимального количества игроков соответствует другим картам

Анализ показывает, что установленное значение minPlayers: 40 для карты whitebox находится в пределах нормы:

  • Несколько других карт имеют схожие или даже более высокие требования:
    • hammurabi и tortuga: 50 игроков
    • submarine: 60 игроков
    • core и radstation: 35 игроков
  • Существует достаточно альтернативных карт с низкими требованиями (0-15 игроков) для серверов с меньшим онлайном
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if there are other maps with similar player requirements
rg "minPlayers:" -A 1

Length of output: 3782

Resources/Prototypes/Catalog/Fills/Lockers/misc.yml (1)

244-244: Подтвердите баланс добавленного снаряжения

Добавление приборов ночного и термального видения в таблицу SyndieMaintLoot может существенно повлиять на баланс игры. Рекомендуется:

  • Проверить вероятность появления этих предметов
  • Убедиться, что это соответствует общему балансу синдикатского снаряжения
✅ Verification successful

Let me check the spawn weights in the loot tables.


Баланс снаряжения подтвержден

На основе анализа кодовой базы:

  • Приборы ночного и термального видения уже доступны через различные игровые механики (исследования, верстаки, аплинк)
  • В аплинке эти предметы стоят 3 телекристалла, что указывает на их сбалансированную ценность
  • Вероятность появления в техах через SyndieMaintLoot составляет всего 5% (prob: 0.05), что делает их достаточно редкими
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for similar high-tier equipment in loot tables
rg "ClothingEyes.*Vision" -A 2

Length of output: 7043


Script:

#!/bin/bash
# Check SyndieMaintLoot table configuration
rg "SyndieMaintLoot" -A 10

Length of output: 1750

Resources/Prototypes/Catalog/Fills/Lockers/suit_storage.yml (2)

201-201: Проверьте обновление скафандров для руководства СБ

Замена боевых скафандров для начальника службы безопасности и смотрителя соответствует общим изменениям в экипировке.

Also applies to: 215-215


Line range hint 263-290: Проверьте конфигурацию новых хранилищ

Добавление хранилищ для парамедиков и корпусменов выглядит корректным:

  • Правильно настроены ограничения доступа
  • Комплектация соответствует ролям
  • Включены как кислородные, так и азотные баллоны

Рекомендуется:

  • Проверить наличие соответствующих ролей в системе доступа
  • Убедиться в существовании всех указанных типов скафандров
✅ Verification successful

Let me generate another verification script to check for access levels.


Конфигурация хранилищ скафандров подтверждена

Проверка показала, что:

  • Уровни доступа Paramedic и Corpsman корректно определены в системе
  • Роли интегрированы в соответствующие департаменты (медицинский и охрана)
  • Все необходимые компоненты (скафандры, баллоны, маски) присутствуют в кодовой базе
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Verify access roles and hardsuit types exist
rg "Paramedic|Corpsman" -A 2
ast-grep --pattern 'enum AccessLevels {
  $$$
}'

Length of output: 70006


Script:

#!/bin/bash
# Search for access level definitions
rg "Paramedic|Corpsman" Resources/Prototypes/Access/ -A 2

Length of output: 910

Resources/Prototypes/Catalog/Fills/Lockers/security.yml (2)

158-159: Обновление снаряжения медика службы безопасности одобрено!

Добавление стандартного скафандра и кислородного баллона соответствует общим изменениям в экипировке.


21-22: Изменение снаряжения смотрителя одобрено!

Замена боевого скафандра на стандартный и добавление кислородного баллона соответствует общему направлению изменений в снаряжении службы безопасности.

✅ Verification successful

Изменение защитного костюма смотрителя подтверждено!

Анализ показывает, что новый скафандр смотрителя (ClothingOuterHardsuitWarden) имеет следующие характеристики:

  • Улучшенная защита от физического урона (0.55 против стандартных 0.6)
  • Дополнительная защита от высоких температур и химических веществ (0.65)
  • Повышенная устойчивость к оглушению (35%)
  • Сбалансированная защита от высокого/низкого давления

Замена боевого скафандра на стандартный вариант смотрителя и добавление кислородного баллона хорошо вписываются в общий баланс экипировки службы безопасности.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Проверка баланса характеристик скафандров
ast-grep --pattern 'ClothingOuterHardsuitWarden {
  $$$
}'

Length of output: 60


Script:

#!/bin/bash
# Search for warden hardsuit definition
rg -A 10 "ClothingOuterHardsuitWarden:" --type yaml

# Search for combat hardsuit definition for comparison
rg -A 10 "ClothingOuterHardsuitCombat:" --type yaml

# Search for other files referencing warden hardsuit
rg "ClothingOuterHardsuitWarden" --type yaml

Length of output: 639


Script:

#!/bin/bash
# Get hardsuit definitions to compare properties
cat Resources/Prototypes/Entities/Clothing/OuterClothing/hardsuits.yml

Length of output: 32738

@@ -139,7 +139,7 @@
- type: StorageFill
contents:
- id: OxygenTankFilled
- id: ClothingOuterHardsuitCombatOfficer # DeltaV - ClothingOuterHardsuitSecurity replaced in favour of security combat hardsuit.
- id: ClothingOuterHardsuitSecurity #WWDP edit
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Обнаружено несоответствие в конфигурации скафандров

В репозитории все еще присутствуют ссылки на боевые скафандры (ClothingOuterHardsuitCombat*) в следующих файлах:

  • Resources/Prototypes/DeltaV/Entities/Clothing/OuterClothing/hardsuits.yml
  • Resources/Prototypes/Catalog/Fills/Crates/hardsuits.yml
  • Resources/Prototypes/Catalog/Fills/Lockers/suit_storage.yml
  • Resources/Maps/pebble.yml
  • Resources/Maps/hive.yml

Необходимо обновить все эти ссылки на соответствующие варианты стандартных охранных скафандров (ClothingOuterHardsuitSecurity).

🔗 Analysis chain

Проверьте соответствие изменений скафандров

Замена боевых скафандров на стандартные охранные соответствует целям PR. Убедитесь, что:

  • Все ссылки на старые типы скафандров обновлены
  • Характеристики новых скафандров соответствуют балансу

Let me verify the references to security hardsuits by checking for the new type as well.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for any remaining references to combat hardsuits
rg "ClothingOuterHardsuitCombat"

Length of output: 3536


Script:

#!/bin/bash
# Check for security hardsuit references
rg "ClothingOuterHardsuitSecurity"

Length of output: 1763

Resources/Prototypes/Recipes/Construction/furniture.yml Outdated Show resolved Hide resolved
Resources/Prototypes/Entities/Objects/Decoration/flora.yml Outdated Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Наш комод уже лежит в папках игры, не стоит его дублировать

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Вместо создания новой меты, лучше просто в мете комода из основных папках добавить "directions": 4

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ну вот на счёт комода. Ремучи мне сказала все респрайты пихать в вайтопапку, комод я забыл пихнуть, потому что на тот момент это была уже третья попытка переноса спрайтов (Раскол все дела). Поэтому думаю лучше перенести комод в вайтопапку, а в старую ебануть обычный комод

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Если пихать все в вайтопапки, то при любом апстриме, где будет задействован данный спрайт придется менять пути. Как по мне, легче просто указать в мете авторство.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ну, мне сказали что пихать надо в вайтопапку, вот и пихаю. Кого теперь слушать? Я хз

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ну, мне сказали что пихать надо в вайтопапку, вот и пихаю. Кого теперь слушать? Я хз

Я PuroSlavKing, делай что я скажу - респрайты в кор папки, уникальные текстуры в папку _White.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Gersoon458 все еще не резолв

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
Resources/Prototypes/Entities/Objects/Decoration/flora.yml (1)

Line range hint 484-499: Предложение по улучшению механики подарков

Рекомендуется добавить систему охлаждения (cooldown) для получения подарков, чтобы предотвратить возможный фарминг предметов. Также стоит рассмотреть возможность персонализации подарков на основе роли или предпочтений игрока.

Пример реализации:

  - type: LimitedItemGiver
    spawnEntries:
      - id: PresentRandom
        orGroup: present
      - id: PresentRandomCash
        prob: 0.20
        orGroup: present
      - id: PresentRandomAsh
        prob: 0.05
        orGroup: present
+   cooldown: 1800  # 30 минут
+   perPlayerCooldown: true
    receivedPopup: christmas-tree-got-gift
    deniedPopup: christmas-tree-no-gift
    requiredHoliday: FestiveSeason
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5167dac and 9587fc4.

📒 Files selected for processing (2)
  • Resources/Prototypes/Entities/Objects/Decoration/flora.yml (1 hunks)
  • Resources/Prototypes/Entities/Structures/Furniture/dresser.yml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • Resources/Prototypes/Entities/Structures/Furniture/dresser.yml
🔇 Additional comments (2)
Resources/Prototypes/Entities/Objects/Decoration/flora.yml (2)

461-468: Корректная реализация визуальных эффектов!

Правильное использование слоёв и шейдера unshaded для создания эффекта свечения. Структура изменений соответствует целям PR по улучшению внешнего вида новогодней ёлки.


471-471: Логичное наследование и корректное добавление слоя подарков!

Правильное переиспользование базовой функциональности через наследование от FloraTreeChristmas01 и добавление визуального слоя подарков.

Also applies to: 477-483

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (2)
Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/meta.json (1)

9-490: Рекомендуется реорганизовать состояния спрайтов

Хотя все необходимые состояния определены корректно, рекомендуется:

  1. Сгруппировать состояния по категориям используя общие префиксы
  2. Добавить комментарии для разделения логических групп состояний

Пример организации:

 "states": [
+    # Utility states
     {
         "name": "mask_null",
         ...
     },
     {
         "name": "icon_spawner",
         ...
     },
+    # Tiny pots
     {
         "name": "pot_tiny_1",
         ...
     },
Resources/Prototypes/_White/Entities/Structures/Furniture/random_potted_plants.yml (1)

122-141: Улучшите организацию RandomSprite компонентов

Компоненты RandomSprite добавлены для всех вариантов растений, что улучшает разнообразие. Рекомендуется:

  1. Вынести списки состояний в отдельные файлы конфигурации
  2. Использовать наследование для избежания дублирования

Пример реорганизации:

# random_plant_states.yml
tiny_plant_states: &tiny_plant_states
  dirt:
    dirt_tiny_1: ""
    dirt_tiny_2: ""
    # ...
  plant:
    plant_tiny_1: ""
    plant_tiny_2: ""
    # ...

# В основном файле
components:
  - type: RandomSprite
    available:
      - <<: *tiny_plant_states

Also applies to: 334-364, 588-607

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9587fc4 and 2a5886d.

⛔ Files ignored due to path filters (118)
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/dirt_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_10.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_11.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_12.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_13.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_14.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_15.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_16.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_17.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_18.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_19.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_20.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_small_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/plant_tiny_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_10.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_small_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/pot_tiny_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/dirt_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/icon_spawner.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/mask_null.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_10.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_11.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_12.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_13.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_14.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_15.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_16.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_17.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_18.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_19.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_20.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_small_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/plant_tiny_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_10.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_7.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_8.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_small_9.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_1.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_2.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_3.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_4.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_5.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_6.png is excluded by !**/*.png
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/pot_tiny_7.png is excluded by !**/*.png
📒 Files selected for processing (3)
  • Resources/Prototypes/_White/Entities/Structures/Furniture/random_potted_plants.yml (25 hunks)
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/meta.json (0 hunks)
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/meta.json (1 hunks)
💤 Files with no reviewable changes (1)
  • Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/meta.json
🔇 Additional comments (3)
Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/meta.json (1)

1-8: Метаданные корректно определены

Метаданные RSI файла правильно структурированы с указанием версии, лицензии и размера спрайтов.

Resources/Prototypes/_White/Entities/Structures/Furniture/random_potted_plants.yml (2)

113-113: Проверьте наличие всех необходимых спрайтов

Путь к спрайтам изменен на _White/Structures/Furniture/random_potted_plants_small.rsi. Убедитесь, что все необходимые состояния присутствуют в новом файле спрайтов.

Also applies to: 149-149, 165-165, 181-181, 197-197, 213-213, 229-229, 325-325, 372-372, 388-388, 404-404, 420-420, 436-436, 452-452, 468-468, 484-484, 500-500


12-12: Проверьте корректность смещений спрайтов

Изменения смещений спрайтов могут повлиять на визуальное отображение:

  • RandomPottedPlantBase: 0.0,2.3 → 0.0,2.25
  • RandomPottedTinyPlant: 0.0,2.3 → 0.0,0.5
  • RandomPottedSmallPlant: 0.0,2.3 → 0.0,0.5
  • RandomPottedMediumPlant: Без изменений (0.0,2.25)

Also applies to: 56-57, 254-255, 522-522

✅ Verification successful

Смещения спрайтов корректны и соответствуют их размерам

Анализ показывает, что изменения смещений полностью обоснованы:

  • Средние растения (160x160 пикселей) используют смещение 0.0,2.25
  • Маленькие и крошечные растения (48x48 пикселей) используют смещение 0.0,0.5

Смещения были скорректированы пропорционально размерам спрайтов для правильного позиционирования относительно тайла. Это стандартная практика для спрайтов разного размера.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Проверка использования смещений в других файлах
rg "offset:\s+[\"']0\.0,(?:2\.3|2\.25|0\.5)[\"']" --type yaml

Length of output: 1019


Script:

#!/bin/bash
# Поиск всех файлов с потенциальными спрайтами растений
fd "plants.*\.rsi" --type directory

# Поиск других сущностей с похожими спрайтами
rg -l "\.rsi/plant" --type yaml

Length of output: 332


Script:

#!/bin/bash
# Проверим содержимое RSI директорий для анализа размеров спрайтов
ls -la Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/
ls -la Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/
ls -la Resources/Textures/Structures/Furniture/potted_plants.rsi/

# Поищем метаданные спрайтов
cat Resources/Textures/_White/Structures/Furniture/random_potted_plants.rsi/meta.json
cat Resources/Textures/_White/Structures/Furniture/random_potted_plants_small.rsi/meta.json

Length of output: 21902

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2a5886d and c4523d5.

📒 Files selected for processing (1)
  • Resources/Textures/Structures/Furniture/furniture.rsi/meta.json (1 hunks)

Comment on lines +29 to 31
"name": "dresser",
"directions": 4
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

⚠️ Potential issue

Обнаружено критическое несоответствие в конфигурации спрайтов

В файле конфигурации мебели обнаружены противоречивые настройки:

  • В meta.json указано "directions": 4, что предполагает наличие спрайтов для 4-х направлений
  • В dresser.yml установлен параметр noRot: True, который блокирует вращение
  • В директории furniture.rsi присутствует только один файл спрайта dresser.png

Необходимо:

  • Либо удалить параметр directions: 4 из meta.json, если шкаф не должен вращаться
  • Либо убрать noRot: True и добавить недостающие спрайты для всех направлений, если шкаф должен поворачиваться
🔗 Analysis chain

Обнаружено несоответствие в конфигурации вращения

Параметр "directions": 4 указывает на поддержку 4-х направлений спрайта, что противоречит параметру noRot: True в файле dresser.yml. Это может привести к неправильному отображению объекта в игре.

Выполните следующий скрипт для проверки всех связанных файлов конфигурации:

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify dresser rotation configuration and sprites

# Check for dresser configuration in yml files
rg -A 5 "noRot.*True" "Resources/Prototypes/Entities/Structures/Furniture/dresser.yml"

# Check if all direction sprites exist
fd "dresser.*\.png$" "Resources/Textures/Structures/Furniture/furniture.rsi"

Length of output: 377


Script:

#!/bin/bash
# Check the actual dresser.png file to see if it's a sprite sheet with multiple directions
file Resources/Textures/Structures/Furniture/furniture.rsi/dresser.png

# Let's also check the full meta.json content to understand the sprite configuration better
cat Resources/Textures/Structures/Furniture/furniture.rsi/meta.json

Length of output: 963

@Spatison Spatison merged commit 59589ca into WWhiteDreamProject:master Dec 31, 2024
11 of 12 checks passed
RedFoxIV pushed a commit to RedFoxIV/wwdpublic that referenced this pull request Jan 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants