Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 12, 2008, 4:28:06 PM (17 years ago)
Author:
landauf
Message:

added a variadic macro to ConfigValueIncludes.h:
ModifyConfigValue(varname, modifier, …) calls 'modifier' (which is a function like set, tset, update, reset, add, remove) and … are the possible arguments (or nothing). i'm not sure if this works on all compilers.
http://en.wikipedia.org/wiki/Variadic_macro

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core2/src/orxonox/objects/test3.cc

    r1030 r1033  
    8787        for (unsigned int i = 0; i < this->vector_vector3_.size(); i++)
    8888        std::cout << "vector<vector3>: " << i << ": " << this->vector_vector3_[i] << std::endl;
     89
     90        ModifyConfigValue(value_int_, tset, "100");
     91        std::cout << std::endl;
     92        std::cout << "int:             " << this->value_int_ << std::endl;
     93
     94        ModifyConfigValue(value_int_, update);
     95        std::cout << std::endl;
     96        std::cout << "int:             " << this->value_int_ << std::endl;
    8997    }
    9098
Note: See TracChangeset for help on using the changeset viewer.