Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 20, 2010, 7:38:53 PM (14 years ago)
Author:
dafrick
Message:

Resolved issue with the Questsystem causing a segfault when a level with Quests was loaded twice. The issue still persists, but not with the Questsystem anymore and it will be addressed with my next commit.
Also removed restrictions to the number of characters a quest/hint identifier must have.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation3/src/modules/questsystem/QuestItem.cc

    r6417 r6940  
    4646    QuestItem::QuestItem(BaseObject* creator) : BaseObject(creator)
    4747    {
     48        this->registered_ = false;
     49       
    4850        RegisterObject(QuestItem);
    4951    }
     
    7981    void QuestItem::setId(const std::string & id)
    8082    {
    81         if(!isId(id)) //!< Checks whether the id is a valid id.
     83        if(id.compare(BLANKSTRING) == 0) //!< Checks whether the id is a valid id.
    8284        {
    8385            COUT(2) << "Invalid id. QuestItem id {" << id << "} could not be set." << std::endl;
     
    8890    }
    8991
    90     /**
    91     @brief
    92         Checks whether an input id is of the required form.
    93     @param id
    94         The id to be checked.
    95     @return
    96         Returns true if the string is likely to be of the required form.
    97     */
    98     /*static*/ bool QuestItem::isId(const std::string & id)
    99     {
    100         return id.size() >= 32;
    101     }
    102 
    10392}
Note: See TracChangeset for help on using the changeset viewer.