Esempio n. 1
0
    /*
     * a hint is basically like a change in the text; it has the same subgraph as the node from which the hint is accessed
     * so users can access the same subgraph from the hint node as they could from the parent. the hint node also inherits the parent's hints,
     * minus itself.
     *
     * in the actual game, when the user fails to match a transition, hints will be delivered before free transitions.
     *
     * */
    public void AddHint(StoryNode hint)
    {
        //note that hints don't take the entire hint set of this;
        //each hint should only take the hints that -would follow it- in the queue of its parent,
        //so the specific hints that any one will get depends on what's added afterwards.
        hint.TakeTransitionsOf(this);
        hint.TakeFreeTransitionsOf(this);
        hints.Add(hint);

        //notify subscribers who also want to take this hint
        HintAddedToStory(hint);
    }