From 7f3b6f7a87a92180e6e9d984cae0c654c46ae7f4 Mon Sep 17 00:00:00 2001 From: Mayberry Date: Thu, 17 Oct 2024 14:02:47 -0400 Subject: [PATCH] Rename ActorLink to BrfldLink and hint it in follow_link argument --- src/mercury_engine_data_structures/formats/brfld.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mercury_engine_data_structures/formats/brfld.py b/src/mercury_engine_data_structures/formats/brfld.py index b26d70b..fd9f6e5 100644 --- a/src/mercury_engine_data_structures/formats/brfld.py +++ b/src/mercury_engine_data_structures/formats/brfld.py @@ -20,7 +20,7 @@ logger = logging.getLogger(__name__) -ActorLink = str +BrfldLink = str class ActorLayer(str, Enum): @@ -72,7 +72,7 @@ def all_actors_in_actor_layer( for actor_name, actor in sublayer.dctActors.items(): yield sublayer_name, actor_name, actor - def follow_link(self, link: str) -> Any | None: + def follow_link(self, link: BrfldLink) -> Any | None: """ Gets the object a link is referencing @@ -86,7 +86,7 @@ def follow_link(self, link: str) -> Any | None: def link_for_actor( self, actor_name: str, sublayer_name: str = "default", actor_layer: ActorLayer = ActorLayer.ENTITIES - ) -> ActorLink: + ) -> BrfldLink: """ Builds a link for an actor @@ -104,7 +104,7 @@ def actor_groups_for_actor_layer(self, actor_layer: ActorLayer = ActorLayer.ENTI returns: each actor group in the actor layer""" yield from self.raw.Root.pScenario[actor_layer].dctActorGroups.keys() - def get_actor_group(self, group_name: str, actor_layer: ActorLayer = ActorLayer.ENTITIES) -> list[ActorLink]: + def get_actor_group(self, group_name: str, actor_layer: ActorLayer = ActorLayer.ENTITIES) -> list[BrfldLink]: """ Gets an actor group