Hey guys,
My group for my HS group project is having some strange errors attempting to run SFML (specically the "Clock" tutorial under the installation page) on the the crappy school computers which are running VS 6++ (VS98). For some reason, we're getting the following errors:
--------------------Configuration: GroupP - Win32 Debug--------------------
Compiling...
Test.cpp
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(82) : error C2535: '__thiscall sf::Unicode::Text::sf::Unicode::Text(const unsigned short *)' : member function already defined or declared
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(80) : see declaration of 'Text::Text'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(86) : error C2629: unexpected 'class sf::Unicode::Text ('
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(86) : error C2238: unexpected token(s) preceding ';'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(87) : error C2629: unexpected 'class sf::Unicode::Text ('
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(87) : error C2238: unexpected token(s) preceding ';'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(88) : error C2629: unexpected 'class sf::Unicode::Text ('
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(88) : error C2238: unexpected token(s) preceding ';'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(98) : error C2027: use of undefined type 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(45) : see declaration of 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(99) : error C2027: use of undefined type 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(45) : see declaration of 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(99) : error C2535: '__thiscall sf::Unicode::Text::operator`class std::basic_string<unsigned short,struct std::char_traits<unsigned short>,class std::allocator<unsigned sho
rt> >'(void) const' : member function already defined or declared
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(97) : see declaration of 'operator`class std::basic_string<unsigned short,struct std::char_traits<unsigned short>,class std::allocator<unsigned short> >''
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(100) : error C2027: use of undefined type 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(45) : see declaration of 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(107) : error C2027: use of undefined type 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(45) : see declaration of 'Unicode'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(241) : error C2039: 'size_t' : is not a member of 'std'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(253) : error C2039: 'size_t' : is not a member of 'std'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.hpp(265) : error C2039: 'size_t' : is not a member of 'std'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.inl(422) : error C2039: 'size_t' : is not a member of 'std'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.inl(442) : error C2039: 'size_t' : is not a member of 'std'
c:\program files\microsoft visual studio\vc98\include\sfml\system\unicode.inl(471) : error C2039: 'size_t' : is not a member of 'std'
Error executing cl.exe.
GroupP.exe - 18 error(s), 0 warning(s)
Any reason as to why this is happening? I've changed the _MBCS preprocessor definition to _UNICODE, which hasn't helped. I'm not even sure if that was a solution, but gave it a shot.
All help is appreciated! Thanks,
Bonafide
Here is the code:
#include <SFML/System.hpp>
#include <iostream>
#include <windows.h>
using namespace std;
int main()
{
sf::Clock Clock;
while (Clock.GetElapsedTime() < 5.f)
{
cout << Clock.GetElapsedTime() << endl;
sf::Sleep(0.5f);
}
return 0;
}