ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Bug Reports (https://www.esoui.com/forums/forumdisplay.php?f=187)
-   -   Functions for detecting CP-disabled campaigns don't work? (https://www.esoui.com/forums/showthread.php?t=10933)

Kyzeragon 04/20/24 12:44 PM

Functions for detecting CP-disabled campaigns don't work?
 
It seems like none of the API functions I'd expect to be able to use to detect whether the player's current campaign has CP enabled are working:

1.
Code:

* DoesCurrentCampaignRulesetAllowChampionPoints()
** _Returns:_ *bool* _isNoChampionPointsCampaign_

This returns true whether I'm in CP, nonCP, Cyro, IC, or not even in PvP at all, whether my home campaign is Gray Host, Ravenwatch, Icereach, etc.
The documentation itself is doubly confusing. To me, the name DoesCurrentCampaignRulesetAllowChampionPoints would suggest that CP-enabled campaigns would return true... but _Returns:_ *bool* _isNoChampionPointsCampaign_ suggests it would return false.


2.
Code:

* GetChampionPurchaseAvailability()
** _Returns:_ *[ChampionPurchaseResult|#ChampionPurchaseResult]* _result_

* GetExpectedResultForChampionPurchaseRequest()
** _Returns:_ *[ChampionPurchaseResult|#ChampionPurchaseResult]* _result_

Both of these return 0 (for success) after I queue a simple purchase request while in a nonCP campaign. I would expect it to return nonzero, because there is a purchase result for nonCP, CHAMPION_PURCHASE_IN_NOCP_CAMPAIGN, which does get returned when the actual purchase request is sent.


The only way I've found to possibly detect nonCP is to GetCampaignRulesetId and hardcode these values into my addons, but it's hacky at best, and more would have to be added when a Cyrodiil event goes live. Am I missing something? Is this a bug with the APIs?

ZOS_DanBatson 04/22/24 11:34 AM

I think there's a bug here. Thank you for reporting this, we're looking into it.


All times are GMT -6. The time now is 12:15 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI