Пример #1
0
    public bool OnInteractionBoxPressed(JournalPiece piece)
    {
        /* Was the left or right page clicked on? */
        if (piece == journalLeft)
        {
            return(pages.FlipLeft());
        }
        else if (piece == journalRight)
        {
            return(pages.FlipRight());
        }

        /* We don't care about this for whatever reason */
        return(false);
    }
Пример #2
0
    protected override bool OnInteractionBoxPressed(InteractionBox box, HandManager hand)
    {
        /* Is this a journal piece? */
        if (!(box is JournalPiece))
        {
            return(false);
        }

        /* We have to have a journal */
        if (currentJournal == null)
        {
            Debug.LogError("PlayerJournalManager: Why do we not have a journal to manage?");
            return(false);
        }

        /* Convert the interaction box to a journal piece */
        JournalPiece piece = (JournalPiece)box;

        /* Let the journal check to see if this event is for us */
        return(currentJournal.OnInteractionBoxPressed(piece));
    }