public override ClueItem GetItem(Noun n1, Noun n2)
    {
        string sprite = "Newspaper";
        string desc   = "";

        if (n1.Type() == NounType.Identity)
        {
            desc = "A newspaper article about " + n1.AsSubject() + ", who " + n2.AsObject() + ".";
        }
        else if (n2.Type() == NounType.Identity)
        {
            desc = "A newspaper article about " + n2.AsSubject() + ", who " + n1.AsObject() + ".";
        }
        else if (n1.Type() == NounType.Name)
        {
            desc = "A newspaper article about " + n1.AsSubject() + ", who " + n2.AsObject() + ".";
        }
        else if (n2.Type() == NounType.Name)
        {
            desc = "A newspaper article about " + n2.AsSubject() + ", who " + n1.AsObject() + ".";
        }

        ClueItem item = new ClueItem(n1, n2, Verb.Has, sprite, desc);

        return(item);
    }
Beispiel #2
0
    public override string ToString()
    {
        // To be human-readable, Name should come before identity before property.
        // Some words should be preceeded by "a" or "the"
        // For properties, it is often preceeded by "Has" not "Is"
        // When linking property to property it should be something like "The red-haired person has X"

        List <string> words = new List <string>();

        words.Add(Subject.AsSubject());
        words.Add(DirectObject.AsObject(Adverb == Adverb.True));

        return(string.Join(" ", words) + ".");
    }