Rename fix (#31654)
* Localize RenameCommand and delegate most of the process to MetaDataSystem.SetEntityName() * Make renaming rely on the EntityRenamedEvent. Fix issue where renaming would keep old Examine text Requires engine change * Fix localisation strings * Make PDA search be based on a renamed entity's Uid instead of its old name To do this the pda component now has an PdaOwner field which gets assigned when it is given as a loadout to a player * Fix bad merge??? huh * Use AllEntityQuery
This commit is contained in:
@@ -37,6 +37,10 @@ namespace Content.Shared.PDA
|
||||
[ViewVariables] public bool FlashlightOn;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)] public string? OwnerName;
|
||||
// The Entity that "owns" the PDA, usually a player's character.
|
||||
// This is useful when we are doing stuff like renaming a player and want to find their PDA to change the name
|
||||
// as well.
|
||||
[ViewVariables(VVAccess.ReadWrite)] public EntityUid? PdaOwner;
|
||||
[ViewVariables] public string? StationName;
|
||||
[ViewVariables] public string? StationAlertLevel;
|
||||
[ViewVariables] public Color StationAlertColor = Color.White;
|
||||
|
||||
Reference in New Issue
Block a user