this is wierd. i've never seen somthing like this before. if i compile the following class i get a message that i'm using "string" as a class, but it isn't defined as a class.
if i take out the irr' 'include' and 'usings' it compiles fine. cant find anything on google. anyone know what is going on ?
You include string from STL, but Irrlicht has also it's own string class. So how compilator can guess which one you want to use. Try following (if STL string is what you want):
You can don't use "using namespace core;" but then you will have to use "core::" before all the stuff from this namespace. Or you can stop using STL string, and use Irrlicht one
But i strongly suggest to familiarize with namespaces. It might be annoying adn messy in the begining but later you will understand how helpful they are.
yeah, i understand namespaces. just never seen this prob before. and i was hoping there was a way to tell the compiler "assume i'm using namespace 'std'"
sorry, buggered that up, i meant i wanted to tell it that in the case of a collision of multiple difinitions i wanted it to assume i was reffering to 'std'
You could do a define statement at the top of your code so that you do not have to type stl::string everytime like this but I mean you are still just saving three letters. I guess that could add up a lot of time if you have trouble typeing "::"