Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Mar 5, 2008, 1:29:47 AM (16 years ago)
Author:
landauf
Message:

several changes:

  • XMLPort is now theoretically able to load something (but still buggy)
  • Expanded Convert with several partial template specializations
  • Expanded all MultiTypes with new functions, mostly to convert values
  • Expanded SubString with a new functionality: chars inside parentheses aren't split

It's not yet working as it should (at least not in all cases - loading the objects name works)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core/src/util/MultiTypeMath.h

    r834 r848  
    8888        bool operator!=(const MultiTypeMath& mtm) const;
    8989
    90         inline operator orxonox::Vector2()     const { return this->vector2_;     }
    91         inline operator orxonox::Vector3()     const { return this->vector3_;     }
    92         inline operator orxonox::ColourValue() const { return this->colourvalue_; }
    93         inline operator orxonox::Quaternion()  const { return this->quaternion_;  }
    94         inline operator orxonox::Radian()      const { return this->radian_;      }
    95         inline operator orxonox::Degree()      const { return this->degree_;      }
     90        operator orxonox::Vector2()     const;
     91        operator orxonox::Vector3()     const;
     92        operator orxonox::ColourValue() const;
     93        operator orxonox::Quaternion()  const;
     94        operator orxonox::Radian()      const;
     95        operator orxonox::Degree()      const;
    9696
    9797        using MultiTypeString::setValue;
     
    103103        inline void setValue(const orxonox::Degree&      value) { this->type_ = MT_degree;      this->degree_      = value; }
    104104        void setValue(const MultiTypeMath& mtm);
     105
     106        inline orxonox::Vector2     getVector2()     const { return this->vector2_;     }
     107        inline orxonox::Vector3     getVector3()     const { return this->vector3_;     }
     108        inline orxonox::ColourValue getColourValue() const { return this->colourvalue_; }
     109        inline orxonox::Quaternion  getQuaternion()  const { return this->quaternion_;  }
     110        inline orxonox::Radian      getRadian()      const { return this->radian_;      }
     111        inline orxonox::Degree      getDegree()      const { return this->degree_;      }
    105112
    106113        inline orxonox::Vector2&     getVector2()     { return this->vector2_;     }
     
    119126        inline void getValue(orxonox::Degree*      variable) const { (*variable) = orxonox::Degree      (this->degree_);      }
    120127
     128        std::string toString() const;
     129        bool fromString(const std::string value);
     130
    121131    protected:
    122132        orxonox::Vector2      vector2_;
Note: See TracChangeset for help on using the changeset viewer.