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

Rename Stances to Relationships in the yaml api #18678

Merged
merged 3 commits into from Dec 11, 2020

Conversation

abcdefg30
Copy link
Member

Follow-up to #18677.

[Desc("What diplomatic stances can this actor disguise as.")]
public readonly PlayerRelationship ValidStances = PlayerRelationship.Ally | PlayerRelationship.Neutral | PlayerRelationship.Enemy;
[Desc("Player relationships the owner of the disguise target needs.")]
public readonly PlayerRelationship ValidRelationships = PlayerRelationship.Ally | PlayerRelationship.Neutral | PlayerRelationship.Enemy;
Copy link
Member

Choose a reason for hiding this comment

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

ValidOwnerRelationships / ValidPlayerRelationships I think would be better.
I can't think of any reasons to leave out the Player part when it is the most important (especially since docs aren't necessarily front-and-center when reading/writing MiniYaml).

Copy link
Member Author

Choose a reason for hiding this comment

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

The value is a PlayerRelationship, which imo makes it clear that we're talking about players here. (I'm actually not sure which other relationships there might be?)

Copy link
Member

@pchote pchote Nov 14, 2020

Choose a reason for hiding this comment

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

I agree that the "*Relationships" naming may not be ideal, but i'm not immediately sure of a better suggestion.

Using Player or Owner does seem clearer, but probably means using multiple different conventions e.g. ValidTargetOwners: Ally, Neutral here and in many other places, but then something like CreatesShroud.ShroudPlayers: Enemy in others. Is this better or worse?

Copy link
Contributor

Choose a reason for hiding this comment

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

Is this better or worse?

IMO better, but I'd keep the generic wording: ValidActorOwners for the trait in question and others, and perhaps AffectedActorOwners or simply AffectedPlayers for remaining traits CreatesShroud, InfiltrateForDecoration, VoiceAnnouncement, WithTextDecoration, WithRangeCircle, WithDecoration, WithBuildingRepairDecoration, AppearsOnRadar, TooltipDescription, RevealsShroud.

IMO the term "valid" is not really fitting for the second group because the event in question will happen anyway (provided any relation is defined), the question is only to whom it happens while for the first group of traits any event can only happen when the actor owner is in the right condition (indirectly true for ProximityExternalCondition and GrantExternalConditionPower since the condition is granted anyway, however the actor owner relation condition decides if any further event develops).

not sure

I don't know if introducing this separation is desirable though from the coder point of view.

EDIT: Well actually the relationship must be valid for the second group too...

@abcdefg30
Copy link
Member Author

Rebased.

@pchote pchote added this to the Next Release milestone Nov 14, 2020
Copy link
Member

@pchote pchote left a comment

Choose a reason for hiding this comment

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

LGTM, but holding off a 👍 until the discussion about maybe changing *Relationships has reached a conclusion.

@pchote
Copy link
Member

pchote commented Nov 22, 2020

FWIW my comment wasn't asking for changes, as IMO what we have here is okay. It was asking to make sure that we are all happy with that and don't have better ideas first.

@reaperrr reaperrr merged commit 7899c52 into OpenRA:bleed Dec 11, 2020
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.

None yet

5 participants