Clean up logging
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using AppleHills.Data.CardSystem;
|
||||
using BookCurlPro;
|
||||
using Core;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
using Tween = Pixelplacement.Tween;
|
||||
@@ -67,17 +68,12 @@ namespace UI.CardSystem
|
||||
|
||||
private void OnButtonClicked()
|
||||
{
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] BookTabButton.OnButtonClicked() - Tab: {gameObject.name}, Zone: {zone}, TargetPage: {targetPage}");
|
||||
|
||||
if (book == null)
|
||||
{
|
||||
Debug.LogWarning($"[BookTabButton] No BookPro reference assigned on {gameObject.name}");
|
||||
Debug.LogError($"[PAGE-NAV-DEBUG] BOOK REFERENCE IS NULL! Cannot flip page.");
|
||||
Logging.Warning($"[BookTabButton] No BookPro reference assigned on {gameObject.name}");
|
||||
return;
|
||||
}
|
||||
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] Book reference valid. Current book page: {book.CurrentPaper}");
|
||||
|
||||
// Notify all tabs that this one was clicked
|
||||
OnTabClicked?.Invoke(this);
|
||||
|
||||
@@ -85,18 +81,11 @@ namespace UI.CardSystem
|
||||
BookCurlPro.AutoFlip autoFlip = book.GetComponent<BookCurlPro.AutoFlip>();
|
||||
if (autoFlip == null)
|
||||
{
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] AutoFlip component not found, adding new component");
|
||||
autoFlip = book.gameObject.AddComponent<BookCurlPro.AutoFlip>();
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] AutoFlip component found, enabled: {autoFlip.enabled}");
|
||||
}
|
||||
|
||||
autoFlip.enabled = true;
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] Calling autoFlip.StartFlipping({targetPage})");
|
||||
autoFlip.StartFlipping(targetPage);
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] Page flip initiated to page {targetPage}");
|
||||
}
|
||||
|
||||
private void OnAnyTabClicked(BookTabButton clickedTab)
|
||||
@@ -128,7 +117,6 @@ namespace UI.CardSystem
|
||||
// Public method to programmatically trigger this tab
|
||||
public void ActivateTab()
|
||||
{
|
||||
Debug.Log($"[PAGE-NAV-DEBUG] ActivateTab() called on {gameObject.name} (Zone: {zone}, TargetPage: {targetPage})");
|
||||
OnButtonClicked();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user