UI换了很多,spine主视觉停用
This commit is contained in:
@@ -326,7 +326,7 @@ public class UI_Panel_Mail : MonoBehaviour
|
||||
|
||||
bool ShouldUseServerMail()
|
||||
{
|
||||
return fetchMailsFromServer && Application.isPlaying;
|
||||
return fetchMailsFromServer && Application.isPlaying && OnlineModeSettings.IsOnlineEnabled;
|
||||
}
|
||||
|
||||
void OnMailRead(mailSlotPrefab slot, mail_so mail)
|
||||
@@ -359,7 +359,7 @@ public class UI_Panel_Mail : MonoBehaviour
|
||||
{
|
||||
if (!MailRewardGrantService.TryGrantAll(mail, out string failureMessage))
|
||||
{
|
||||
gNotice.error.display(string.IsNullOrWhiteSpace(failureMessage) ? "\u90ae\u4ef6\u5956\u52b1\u9886\u53d6\u5931\u8d25" : failureMessage);
|
||||
gNotice.error.display(string.IsNullOrWhiteSpace(failureMessage) ? LocalizationService.Get("mail.claim_failed", "邮件奖励领取失败") : failureMessage);
|
||||
return;
|
||||
}
|
||||
mail.isReceived = true;
|
||||
@@ -1021,6 +1021,11 @@ public class MailHttpService : MonoBehaviour
|
||||
|
||||
public void SetServerModeEnabled(bool enabled)
|
||||
{
|
||||
if (OnlineModeSettings.IsLocalOnlyMode)
|
||||
{
|
||||
enabled = false;
|
||||
}
|
||||
|
||||
if (_serverModeEnabled == enabled)
|
||||
{
|
||||
if (enabled && _pollCoroutine == null)
|
||||
@@ -1050,7 +1055,7 @@ public class MailHttpService : MonoBehaviour
|
||||
|
||||
public void RequestRefresh()
|
||||
{
|
||||
if (!_serverModeEnabled || _isRefreshing)
|
||||
if (!_serverModeEnabled || _isRefreshing || OnlineModeSettings.IsLocalOnlyMode)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -1157,7 +1162,7 @@ public class MailHttpService : MonoBehaviour
|
||||
|
||||
public async System.Threading.Tasks.Task NotifyMailClaimedAsync(int mailId)
|
||||
{
|
||||
if (!_serverModeEnabled || mailId <= 0)
|
||||
if (!_serverModeEnabled || mailId <= 0 || OnlineModeSettings.IsLocalOnlyMode)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -1193,7 +1198,7 @@ public class MailHttpService : MonoBehaviour
|
||||
|
||||
private async System.Threading.Tasks.Task SyncClaimedMailStateAsync()
|
||||
{
|
||||
if (!_serverModeEnabled || _cachedMails.Count == 0)
|
||||
if (!_serverModeEnabled || _cachedMails.Count == 0 || OnlineModeSettings.IsLocalOnlyMode)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user