forked from crawl/crawl
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
A clua monster method for finding its summoner
The crawl UI highlights a monster's summoner in LOS examination mode, but there was previously no way to determine a monster's summoner from clua. This commit adds a summoner_pos() method to the monster info table that returns a pair of LOS coordinates of the monster's summoner. It returns nil if the monster's isn't summoned or it the monster or its summoner are not in LOS. I've copied the summoning monster's mid into the monster_info class and updated the examination mode UI to use this information. This way we have a centralized check for whether the summoner is valid to reveal, at least regardless of LOS concerns.
- Loading branch information
Showing
4 changed files
with
41 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters