|
derefed wrote:
I've just recently picked up Lua and have been exploring its potential as a possible game scripting engine for any future projects. For better integration with C++ I've chosen to play around with Luabind. So far, I've been quite impressed with its capabilities and ease of use. I have, however, run into a seemingly minor problem that I cannot, for the life of me, figure out.
std::vector::at is an overloaded method (for const containers), so a function pointer to it is ambiguous. You need to explicitly cast it to the type you want:
... .def("at",(int&(std::vector<int>::*)(size_t))&std::vector<int>::at) ...I'm going from memory on the above code, but it (or something like it) should work.
- Jim