-
Notifications
You must be signed in to change notification settings - Fork 34
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
[Feature] StepTriggerGroup to improve StepTriggerImmune behaviour #53
[Feature] StepTriggerGroup to improve StepTriggerImmune behaviour #53
Conversation
WalkthroughThe pull request introduces enhancements to the step trigger system by adding new properties, such as Changes
Possibly related PRs
Recent review detailsConfiguration used: CodeRabbit UI Files selected for processing (1)
Files skipped from review as they are similar to previous changes (1)
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? TipsChatThere are 3 ways to chat with CodeRabbit:
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)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Проверял на фелинидах и лаве. Пока что не работает. |
@coderabbitai review |
Actions performedReview triggered.
|
@coderabbitai full review |
Actions performedFull review triggered. |
There was a problem hiding this 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
Outside diff range and nitpick comments (1)
Resources/Prototypes/Entities/Mobs/Player/ipc.yml (1)
114-114
: Approve the addition of theDamageable
component.The addition of the
Damageable
component to theMobIPC
entity is a valid change that allows the entity to take damage, which is consistent with the PR objective.Consider configuring the
Damageable
component.The
Damageable
component is added without any properties, which means it will use default values. To fine-tune the damage behavior, consider configuring the component with appropriate properties such as:
maxDamage
: The maximum amount of damage the entity can take before being destroyed.resistances
: The resistance values for different damage types (e.g.,Blunt
,Slash
,Piercing
, etc.).onDamageChanged
: An event that is triggered when the entity's damage value changes.
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (9)
- Content.Shared/StepTrigger/Components/StepTriggerComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1 hunks)
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (2 hunks)
- Resources/Prototypes/Entities/Mobs/Player/ipc.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/chasm.yml (4 hunks)
- Resources/Prototypes/Entities/Tiles/lava.yml (1 hunks)
- Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml (1 hunks)
Additional comments not posted (10)
Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1)
1-13
: LGTM!The
StepTriggerTypePrototype
class is well-defined and follows good practices:
- The class is
sealed
andpartial
, preventing unintended inheritance and allowing for extension in other files.- The
ID
property is correctly decorated with[ViewVariables]
and[IdDataField]
attributes, indicating its purpose as a unique identifier for the prototype.- The
ID
property is initialized with a null-forgivingdefault!
value to ensure it is never null.Overall, the code is clean, concise, and follows the expected conventions for defining a prototype class.
Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (2)
9-20
: LGTM!The
StepTriggerGroup
class is well-defined with appropriate access modifiers, attributes, and a clear summary describing its purpose. The use of thepartial
keyword allows for extending the class functionality in other files if needed.
17-19
: LGTM!The
Types
property is well-defined with an appropriate type, default value, and custom serializer. The restricted access permissions provide an additional layer of security by limiting access to theStepTriggerSystem
.Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs (2)
17-18
: LGTM!The
[Access]
attribute is correctly used to specify that theStepTriggerSystem
can access this component. This change aligns with the objective of tighter integration between the component and the system.
20-24
: TheWhitelist
property is a valuable addition to theStepTriggerImmuneComponent
.The new property enhances the functionality of the component by allowing for selective immunity based on specified triggers. The
[DataField]
attribute ensures proper serialization and deserialization of the property.A few additional insights:
- The nullable type
StepTriggerGroup?
allows the property to be optional, providing flexibility in configuration.- The default value of
default!
suppresses the null-state analysis for the expression, indicating that the property can be null.Overall, this change aligns with the PR objectives and introduces a new layer of control over which triggers the component can ignore, potentially affecting gameplay mechanics related to step triggers.
Resources/Prototypes/Entities/Tiles/lava.yml (1)
16-18
: LGTM! The newtriggerGroup
property enhances the step trigger functionality.The addition of the
triggerGroup
property with the "Lava" type is a valid enhancement to theStepTrigger
component configuration for the lava tile entity. This change allows for more granular control over how the lava tile interacts with other game elements based on the associated trigger group.By specifying the "Lava" type in the
types
array, you are effectively creating a new category of triggers that can be used to define specific behaviors or interactions related to lava tiles. This can lead to more complex and dynamic gameplay mechanics.The changes are consistent with the existing structure and syntax of the configuration file, ensuring a smooth integration with the rest of the codebase.
Great work on enhancing the configurability of the lava tile entity!
Resources/Prototypes/Entities/Tiles/chasm.yml (1)
17-19
: LGTM!The addition of the
triggerGroup
property with the "Chasm" type is a valid enhancement to the chasm entity definition. It allows grouping chasm entities and potentially triggering specific behaviors or interactions based on their classification, which aligns with the PR objective of improving the StepTriggerSystem and enhancing immunity features.Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml (1)
83-85
: LGTM!The addition of the
whitelist
property to theStepTriggerImmune
component for felinids is implemented correctly. TheLava
entry in thetypes
list matches the expected step trigger type for lava, making felinids immune to lava damage as intended.The change is consistent with the PR objective and fits well within the existing structure of the
felinid.yml
file.Content.Shared/StepTrigger/Components/StepTriggerComponent.cs (1)
62-63
: LGTM! The newTriggerGroups
property enhances the functionality of theStepTriggerComponent
.The addition of the nullable
TriggerGroups
property of typeStepTriggerGroup
allows the component to associate multiple trigger groups. This could facilitate more complex interactions or behaviors in the game environment.The property is appropriately marked with the
[DataField]
attribute for data serialization and the[AutoNetworkedField]
attribute for network synchronization.The existing properties and overall structure of the
StepTriggerComponent
class remain preserved, ensuring backward compatibility.Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (1)
122-143
: LGTM!The changes to the
CanTrigger
method introduce several improvements:
The new logic enhances the control flow by first checking the active state of the
StepTriggerComponent
and the presence of theotherUid
in theCurrentlySteppedOn
list, returning false immediately if either condition fails. This is more efficient than the original logic.The introduction of the whitelist mechanism in the
StepTriggerImmuneComponent
allows for more fine-grained control over which entities can trigger step events based on their types. This feature enhances the flexibility of the step trigger system.The logic for iterating through the types in the whitelist and comparing them with the types in the
TriggerGroups
of theStepTriggerComponent
is implemented correctly.The code segment is well-structured and follows a clear logical flow, making it easy to understand and maintain.
The removal of the commented-out code improves code readability.
Overall, the changes are a valuable addition to the step trigger system and are implemented effectively.
There was a problem hiding this 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
Files selected for processing (9)
- Content.Shared/StepTrigger/Components/StepTriggerComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1 hunks)
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (2 hunks)
- Resources/Prototypes/Entities/Mobs/Player/ipc.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/chasm.yml (4 hunks)
- Resources/Prototypes/Entities/Tiles/lava.yml (1 hunks)
- Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml (1 hunks)
Additional comments not posted (15)
Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1)
1-13
: LGTM!The
StepTriggerTypePrototype
class is well-structured and follows the conventions for defining a prototype class. The class has a single propertyID
that serves as the unique identifier for the prototype. The use of attributes like[ViewVariables]
and[IdDataField]
is appropriate for a prototype class.The class is marked as
sealed
to prevent inheritance andpartial
to allow its definition to span multiple files if needed. The class implements theIPrototype
interface, which is likely a requirement for all prototype classes in the project.The naming conventions for the class, namespace, and property are followed consistently. The class is defined in a namespace to prevent naming conflicts and improve code organization. The file name matches the class name, adhering to the convention of one class per file.
Overall, the code is clean, well-organized, and follows the project's conventions. Great job!
Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (2)
9-20
: LGTM!The
StepTriggerGroup
class is well-defined with appropriate attributes and a clear summary describing its purpose.
17-19
: LGTM!The
Types
property is well-defined with appropriate attributes, serializer, and access permissions.Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs (3)
17-17
: LGTM!The
[Access]
attribute is correctly used to restrict access to theStepTriggerSystem
. This change reinforces the relationship between the component's functionality and the broader game mechanics.
20-24
: LGTM!The
Whitelist
property is correctly defined with a nullableStepTriggerGroup
type and a default value. The[DataField]
attribute is used appropriately to serialize the property. This change allows for selective immunity and is consistent with the AI-generated summary.
1-2
: LGTM!The new using statement correctly imports the
Content.Shared.StepTrigger.Prototypes
namespace, which is required for theStepTriggerGroup
type used in theWhitelist
property. The formatting change to the existing using statement is acceptable.Resources/Prototypes/Entities/Tiles/lava.yml (1)
16-18
: LGTM! The addition of thetriggerGroup
property enhances the lava tile's functionality.The introduction of the
triggerGroup
property with the "Lava" type allows the lava tile entity to interact with other game elements in a more nuanced manner. This change enables more complex interactions or behaviors based on the specified trigger group, potentially enhancing the gameplay experience.It's important to note that the existing
blacklist
property remains unchanged, suggesting that the new functionality is additive and does not interfere with the current behavior of the lava tile.Consider the following additional points:
- Ensure that the "Lava" type is properly handled in the corresponding game logic to achieve the desired behavior.
- Verify that the addition of the
triggerGroup
property does not introduce any unintended side effects or conflicts with other game elements.- Update the relevant documentation or comments to reflect the new functionality and its purpose.
Overall, this change improves the configurability and potential interactions of the lava tile entity, likely enhancing the gameplay experience.
Resources/Prototypes/Entities/Tiles/chasm.yml (4)
17-19
: LGTM!The addition of the
triggerGroup
property withtypes: - Chasm
is a valid way to categorize the entity as a chasm. This categorization can be effectively used to trigger specific behaviors or interactions based on the entity type.
61-61
: Looks good!The removal of the unnecessary empty line enhances the readability of the file without affecting the functionality.
71-71
: Looks good!The removal of the unnecessary empty line enhances the readability of the file without affecting the functionality.
80-80
: Looks good!The removal of the unnecessary empty line enhances the readability of the file without affecting the functionality.
Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml (1)
83-85
: LGTM!The addition of the
whitelist
property with theLava
entry to theStepTriggerImmune
component is correctly implemented. This change aligns with the PR objective of adjusting the damage modifier for felinids, making them immune to step triggers from lava.Content.Shared/StepTrigger/Components/StepTriggerComponent.cs (2)
1-1
: LGTM!The addition of the using directive is necessary to use types from the
Content.Shared.StepTrigger.Prototypes
namespace.
62-63
: Approve the addition of theTriggerGroups
property.The new
TriggerGroups
property enhances the functionality of theStepTriggerComponent
by allowing it to associate with multiple trigger groups. This change aligns with the provided AI-generated summary.The property is appropriately annotated with the
[DataField]
and[AutoNetworkedField]
attributes for data serialization and network synchronization.The default value of
default!
is used to suppress nullable warnings, as the property is declared as nullable (StepTriggerGroup?
).Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (1)
129-143
: LGTM!The new logic flow for checking the
StepTriggerImmuneComponent
and its whitelist is implemented correctly and effectively refines the conditions under which step triggers can be activated. It enhances the control flow by allowing for selective exclusion of entities with specific immunity based on a whitelist.The code segment is well-structured and readable, making it easier to understand and maintain.
2024-09-13.15-39-24.mp4Works fine |
LiquidPlasma actually was a lava analog, just with plasma. Fixing it |
There was a problem hiding this 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
Outside diff range and nitpick comments (1)
Resources/Prototypes/Entities/Tiles/bananium.yml (1)
50-52
: LGTM! The change introduces a useful grouping mechanism for step triggers.The addition of the
triggerGroups
property allows step triggers to be associated with specific types, enabling more nuanced interactions and behaviors. In this case, theBanana
type suggests that stepping on this tile will trigger banana-related effects, which aligns with the PR objective of adjusting entity interactions.Consider documenting the available trigger group types and their intended behaviors to maintain clarity and consistency across the codebase. This will help other developers understand and utilize the grouping mechanism effectively.
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (19)
- Content.Shared/StepTrigger/Components/StepTriggerComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs (2 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1 hunks)
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (2 hunks)
- Resources/Prototypes/Entities/Effects/chemistry_effects.yml (2 hunks)
- Resources/Prototypes/Entities/Mobs/Player/ipc.yml (1 hunks)
- Resources/Prototypes/Entities/Mobs/Species/harpy.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Devices/mousetrap.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Devices/pda.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Materials/shards.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Misc/land_mine.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/bananium.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/chasm.yml (4 hunks)
- Resources/Prototypes/Entities/Tiles/lava.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/liquid_plasma.yml (1 hunks)
- Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml (1 hunks)
- Resources/Prototypes/Traits/skills.yml (1 hunks)
Files skipped from review due to trivial changes (1)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs
Files skipped from review as they are similar to previous changes (8)
- Content.Shared/StepTrigger/Components/StepTriggerComponent.cs
- Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs
- Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs
- Resources/Prototypes/Entities/Mobs/Player/ipc.yml
- Resources/Prototypes/Entities/Tiles/chasm.yml
- Resources/Prototypes/Entities/Tiles/lava.yml
- Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml
Additional comments not posted (9)
Resources/Prototypes/Entities/Tiles/liquid_plasma.yml (1)
16-18
: LGTM!The addition of the
triggerGroups
property with theLiquid
type is a valid and meaningful change for theFloorLiquidPlasmaEntity
. This categorization allows the entity to be recognized as a liquid trigger, which is consistent with its nature as a liquid plasma floor tile.The change is properly implemented without introducing any syntax errors or inconsistencies in the YAML structure.
Resources/Prototypes/Entities/Objects/Misc/land_mine.yml (1)
43-45
: LGTM!The addition of the
triggerGroups
property with theLandmine
type is a valid change that allows the land mine to be categorized under a specific trigger group. This change is consistent with the provided summary and follows the existing code style.Resources/Prototypes/Entities/Objects/Devices/mousetrap.yml (1)
16-18
: LGTM!The addition of the
triggerGroups
property to theStepTrigger
component is a valid enhancement. Categorizing the trigger under theMousetrap
type allows for more refined control and interaction with other components in the system.The code change is syntactically correct and aligns with the PR objective of improving the StepTriggerSystem.
Resources/Prototypes/Entities/Effects/chemistry_effects.yml (1)
80-82
: LGTM!The addition of the
triggerGroups
property with theLiquid
type under theStepTrigger
component is a valid change. It categorizes the step trigger as a liquid type, which could affect its interaction with other game mechanics or entities that recognize liquid types.The syntax and structure of the added code are correct.
Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml (1)
27-29
: LGTM!The addition of the
triggerGroups
property with theSoap
type is a valid and consistent change that enhances the functionality of theStepTrigger
component by linking it to a specific category. This categorization may influence the behavior of the trigger in the game environment, as accurately described in the AI-generated summary.Resources/Prototypes/Entities/Objects/Materials/shards.yml (1)
67-69
: LGTM!The addition of the
triggerGroups
property with theShard
type aligns with the PR objective of adjusting the damage modifier for IPC interacting with glass shards. This change allows for more refined control over how triggers are processed in relation to shards.Resources/Prototypes/Entities/Mobs/Species/harpy.yml (1)
122-127
: LGTM! Thewhitelist
addition enhances the flexibility of theStepTriggerImmune
component.The introduction of the
whitelist
section in theStepTriggerImmune
component configuration allows for fine-grained control over which types can trigger the component. By explicitly listing the allowed types (Shard
,Liquid
,Landmine
, andMousetrap
), the component can selectively ignore triggers from other types. This change enhances the flexibility and customization of theStepTriggerImmune
component for theharpy
entity, enabling more precise control over its behavior.The specified types seem reasonable and aligned with the expected behavior of the
harpy
entity. The indentation and formatting of the added lines are also consistent with the existing code style.Great work on implementing this enhancement!
Resources/Prototypes/Traits/skills.yml (1)
273-278
: LGTM!The addition of the
whitelist
property to theStepTriggerImmune
component of theTrapAvoider
trait is a valid enhancement. It allows the trait to provide immunity to specific types of step triggers, namelyShard
,Liquid
,Landmine
, andMousetrap
. This change is consistent with the purpose of the trait and follows the correct syntax and structure.Resources/Prototypes/Entities/Objects/Devices/pda.yml (1)
275-277
: LGTM!The addition of the
triggerGroups
property to theStepTrigger
component of theClownPDA
entity looks good. It aligns with the overall enhancements being made to the step trigger system, allowing theClownPDA
to respond to the newSoap
trigger type.
There was a problem hiding this 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
Outside diff range and nitpick comments (1)
Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml (1)
163-165
: Consider using a consistent property name.The addition of the
triggerGroup
property under theStepTrigger
component is implemented correctly. However, for consistency with theSoap
entity, consider using the plural formtriggerGroups
instead of the singulartriggerGroup
.Apply this diff to use a consistent property name:
- triggerGroup: # WD EDIT + triggerGroups: # WD EDIT
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (2)
- Resources/Prototypes/Entities/Objects/Consumable/Food/produce.yml (1 hunks)
- Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml (3 hunks)
Files skipped from review as they are similar to previous changes (1)
- Resources/Prototypes/Entities/Objects/Consumable/Food/produce.yml
Additional comments not posted (2)
Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml (2)
27-29
: LGTM!The addition of the
triggerGroups
property under theStepTrigger
component is implemented correctly. Associating theStepTrigger
with theSlipEntity
category aligns with the PR objectives and may enhance the trigger's functionality in the game environment.
207-209
: LGTM!The addition of the
triggerGroups
property under theStepTrigger
component is implemented correctly. Associating theStepTrigger
with theSlipEntity
category aligns with the PR objectives and may enhance the trigger's functionality in the game environment.
Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this 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
Outside diff range and nitpick comments (1)
Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1)
27-32
: Make theTypes
property setter private.The
DataDefinition
,Serializable
, andNetSerializable
attributes are correctly specified for theStepTriggerGroup
class. TheTypes
property is also correctly defined to hold a list ofStepTriggerTypePrototype
identifiers.However, consider making the
Types
property setter private to prevent unintended modifications from outside the class.[DataField] -public List<ProtoId<StepTriggerTypePrototype>>? Types = null; +public List<ProtoId<StepTriggerTypePrototype>>? Types { get; private set; } = null;
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (6)
- Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1 hunks)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs (1 hunks)
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs (2 hunks)
- Resources/Prototypes/Entities/Mobs/NPCs/silicon.yml (1 hunks)
- Resources/Prototypes/Entities/Tiles/chasm.yml (4 hunks)
- Resources/Prototypes/StepTrigger/StepTriggerTypes.yml (1 hunks)
Files skipped from review due to trivial changes (1)
- Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs
Files skipped from review as they are similar to previous changes (4)
- Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs
- Resources/Prototypes/Entities/Mobs/NPCs/silicon.yml
- Resources/Prototypes/Entities/Tiles/chasm.yml
- Resources/Prototypes/StepTrigger/StepTriggerTypes.yml
Additional comments not posted (1)
Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs (1)
1-7
: LGTM!The using directives are correctly specified and seem relevant to the
StepTriggerGroup
class implementation.
# Description This is a port of WWhiteDreamProject/wwdpublic#53 from White Dream. This PR improves the StepTriggerImmune component by making it operate on a more granular Blacklist system, such that StepTriggerImmune entities can further clarify via prototypes which kinds of floor traps they are immune to, such as landmines/mousetraps, and not have blanket immunity to everything. Because it turns out things like Lava and Soap also were caught by the immunity, when really we just wanted Harpies & Felinids to not trigger landmines. <details><summary><h1>Media</h1></summary> <p> > # Описание > Необходимо настроить модификатор урона, чтобы IPC не получали урон от осколков стекла. > > Иммунитет StepTriggerImmuneComponent доработан. Теперь имеются несколько типов (types): Lava - тип тайла, наступив на который появляется урон. Это собственно лава и LiquidPlasma Landmine - мины. Chasm - дырка в карте, куда можно провалиться Mousetrap - Мышеловка SlipTile - Все, что должно подскальзывать игроков, имеющее размер тайла SlipEntity - Все, что должно подскальзывать игроков, имеющее развер энтити. Разделено для баланса. Самые ловки могут игнорировать мелкие предметы (энтити), т.е. уворачиваться от них. Но большие по площади вещи (тайлы по типу разлитой воды, бананиума) просчитываются отдельно. > > # Изменения > * [x] Улучшить StepTriggerSystem (Immune) > * [x] Добавлены типы триггера. - Lava Landmine Shard Chasm Mousetrap SlipTile SlipEntity > * [x] Исправить осколки у IPC > * [x] Исправить отсутствие урона от лавы и падение в дыры у фелинидов и гарпий. > > 🆑 Hell_Cat > > * Feature: StepTriggerSystem is improved | Улучшена StepTriggerSystem > * fix: IPC: Immunity for shards and SpiderWeb | Иммунитет осколкам. > * fix: Felinid | Фелиниды : Immunity for Shard Landmine Mousetrap SlipEntities | Иммунитет для осколков, жидкости, мин, мышеловок, мыла и бананов. > * fix: Harpy | Гарпия : Immunity for Shards Landmine Mousetrap | Иммунитет для осколков, жидкости, мин и мышеловок. > * fix: Mice | Мыши : Don't blow up on landmines | Мыши не подрываются на минах. </p> </details> # Changelog :cl: Hell_Cat Feature: StepTriggerSystem has been improved with new StepTriggerGroups. Additionally, the StepTriggerImmune component now allows declaring for specific StepTriggerGroups for a given entity to be immune to. Some examples may be, Felinids, Mice, and Harpies being unable to set off Landmines. --------- Signed-off-by: VMSolidus <[email protected]> Co-authored-by: Ivan <[email protected]> Co-authored-by: FoxxoTrystan <[email protected]>
# Description This is a port of #53 from White Dream. This PR improves the StepTriggerImmune component by making it operate on a more granular Blacklist system, such that StepTriggerImmune entities can further clarify via prototypes which kinds of floor traps they are immune to, such as landmines/mousetraps, and not have blanket immunity to everything. Because it turns out things like Lava and Soap also were caught by the immunity, when really we just wanted Harpies & Felinids to not trigger landmines. <details><summary><h1>Media</h1></summary> <p> > # Описание > Необходимо настроить модификатор урона, чтобы IPC не получали урон от осколков стекла. > > Иммунитет StepTriggerImmuneComponent доработан. Теперь имеются несколько типов (types): Lava - тип тайла, наступив на который появляется урон. Это собственно лава и LiquidPlasma Landmine - мины. Chasm - дырка в карте, куда можно провалиться Mousetrap - Мышеловка SlipTile - Все, что должно подскальзывать игроков, имеющее размер тайла SlipEntity - Все, что должно подскальзывать игроков, имеющее развер энтити. Разделено для баланса. Самые ловки могут игнорировать мелкие предметы (энтити), т.е. уворачиваться от них. Но большие по площади вещи (тайлы по типу разлитой воды, бананиума) просчитываются отдельно. > > # Изменения > * [x] Улучшить StepTriggerSystem (Immune) > * [x] Добавлены типы триггера. - Lava Landmine Shard Chasm Mousetrap SlipTile SlipEntity > * [x] Исправить осколки у IPC > * [x] Исправить отсутствие урона от лавы и падение в дыры у фелинидов и гарпий. > > 🆑 Hell_Cat > > * Feature: StepTriggerSystem is improved | Улучшена StepTriggerSystem > * fix: IPC: Immunity for shards and SpiderWeb | Иммунитет осколкам. > * fix: Felinid | Фелиниды : Immunity for Shard Landmine Mousetrap SlipEntities | Иммунитет для осколков, жидкости, мин, мышеловок, мыла и бананов. > * fix: Harpy | Гарпия : Immunity for Shards Landmine Mousetrap | Иммунитет для осколков, жидкости, мин и мышеловок. > * fix: Mice | Мыши : Don't blow up on landmines | Мыши не подрываются на минах. </p> </details> # Changelog :cl: Hell_Cat Feature: StepTriggerSystem has been improved with new StepTriggerGroups. Additionally, the StepTriggerImmune component now allows declaring for specific StepTriggerGroups for a given entity to be immune to. Some examples may be, Felinids, Mice, and Harpies being unable to set off Landmines. --------- Signed-off-by: VMSolidus <[email protected]> Co-authored-by: Ivan <[email protected]> Co-authored-by: FoxxoTrystan <[email protected]> # Conflicts: # Content.Shared/StepTrigger/Components/StepTriggerComponent.cs # Content.Shared/StepTrigger/Components/StepTriggerImmuneComponent.cs # Content.Shared/StepTrigger/Prototypes/StepTriggerGroup.cs # Content.Shared/StepTrigger/Prototypes/StepTriggerTypePrototype.cs # Content.Shared/StepTrigger/Systems/StepTriggerSystem.cs # Resources/Prototypes/Entities/Effects/chemistry_effects.yml # Resources/Prototypes/Entities/Mobs/NPCs/animals.yml # Resources/Prototypes/Entities/Mobs/Player/ipc.yml # Resources/Prototypes/Entities/Mobs/Species/harpy.yml # Resources/Prototypes/Entities/Objects/Devices/mousetrap.yml # Resources/Prototypes/Entities/Objects/Devices/pda.yml # Resources/Prototypes/Entities/Objects/Fun/dice.yml # Resources/Prototypes/Entities/Objects/Materials/shards.yml # Resources/Prototypes/Entities/Objects/Misc/land_mine.yml # Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml # Resources/Prototypes/Entities/Tiles/bananium.yml # Resources/Prototypes/Entities/Tiles/chasm.yml # Resources/Prototypes/Entities/Tiles/lava.yml # Resources/Prototypes/Entities/Tiles/liquid_plasma.yml # Resources/Prototypes/Nyanotrasen/Entities/Mobs/Species/felinid.yml # Resources/Prototypes/Traits/skills.yml
Описание
Необходимо настроить модификатор урона, чтобы IPC не получали урон от осколков стекла.
Иммунитет StepTriggerImmuneComponent доработан.
Теперь имеются несколько типов (types):
Lava - тип тайла, наступив на который появляется урон. Это собственно лава и LiquidPlasma
Landmine - мины.
Chasm - дырка в карте, куда можно провалиться
Mousetrap - Мышеловка
SlipTile - Все, что должно подскальзывать игроков, имеющее размер тайла
SlipEntity - Все, что должно подскальзывать игроков, имеющее развер энтити.
Разделено для баланса. Самые ловки могут игнорировать мелкие предметы (энтити), т.е. уворачиваться от них. Но большие по площади вещи (тайлы по типу разлитой воды, бананиума) просчитываются отдельно.
Изменения
🆑 Hell_Cat