Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 18, 2008, 10:58:46 PM (17 years ago)
Author:
landauf
Message:

did some first (and very unfinished) steps to deal with different players on server and client

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/objecthierarchy/src/core/ClassFactory.h

    r1747 r1940  
    5555    {
    5656        public:
    57             static bool create(const std::string& name);
     57            static bool create(const std::string& name, bool bLoadable = true);
    5858            BaseObject* fabricate();
    5959
     
    6868    /**
    6969        @brief Adds the ClassFactory to the Identifier of the same type and the Identifier to the Factory.
     70        @param name The name of the class
     71        @param bLoadable True if the class can be loaded through XML
    7072        @return Always true (this is needed because the compiler only allows assignments before main())
    7173    */
    7274    template <class T>
    73     bool ClassFactory<T>::create(const std::string& name)
     75    bool ClassFactory<T>::create(const std::string& name, bool bLoadable)
    7476    {
    7577        COUT(4) << "*** ClassFactory: Create entry for " << name << " in Factory." << std::endl;
    7678        ClassIdentifier<T>::getIdentifier(name)->addFactory(new ClassFactory<T>);
     79        ClassIdentifier<T>::getIdentifier()->setLoadable(bLoadable);
    7780        Factory::add(name, ClassIdentifier<T>::getIdentifier());
    7881
Note: See TracChangeset for help on using the changeset viewer.