示例#1
0
 Model::Node* NodeReader::onWorldspawn(const Model::EntityAttribute::List& attributes, const ExtraAttributes& extraAttributes) {
     Model::Entity* worldspawn = m_factory->createEntity();
     worldspawn->setAttributes(attributes);
     setExtraAttributes(worldspawn, extraAttributes);
     
     m_nodes.insert(m_nodes.begin(), worldspawn);
     return worldspawn;
 }
示例#2
0
        void MapReader::createEntity(const size_t line, const Model::EntityAttribute::List& attributes, const ExtraAttributes& extraAttributes) {
            Model::Entity* entity = m_factory->createEntity();
            entity->setAttributes(attributes);
            setExtraAttributes(entity, extraAttributes);

            const ParentInfo::Type parentType = storeNode(entity, attributes);
            stripParentAttributes(entity, parentType);
            
            m_currentNode = entity;
            m_brushParent = entity;
        }