Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

Compile Ran Source VS2005

Skilled Illusionist
Joined
Feb 11, 2010
Messages
302
Reaction score
26
I tried to compile Ran Source with Visual Studio 2005, currently I can full compile all source, I take source from this thread

My Laptop configuration, Visual Studio 2005, DXSDK 2004, .Net 1.1, 2.0, 3.0, 3.5, 4.0, 4.5.1
In my laptop also installed VS2003, VS2010 and VS2013, but I use VS2005 to compile RanSource

As I know, C++ VS2005 does not support default int variable, like C++ 6.0 or C++ 2003, with that diferrence I got lot error because in Ran Source so many code like this
Code:
        for ( i = 0; i< 33; ++i)
	{
		strArray = new CStringArray;
		strBuff.LoadString(szID[i]);
		strArray->Add(strBuff);
		m_LauncherText.mapFlags[strID[i]] = strArray;
	}

for know I can analyze and complete the diferences between VS2005 and VS2003, but one last think I need help for this code

Code:
        std::set<int>::iterator iter_EffNum;
	iter_EffNum = m_setLandEffectNum.begin();
	for( ; iter_EffNum != m_setLandEffectNum.end(); ++iter_EffNum )
	{
		if( i >= EMLANDEFFECT_MULTI ) break;
		dropChar.nLandEffect[i] = *iter_EffNum;
	}

you can find that code at GLCharEx.cpp, RanClientLib project, line 528

I can't find any reference to "i" and what should I do with that "i", if I look that code, I almost sure, I must increment "i" but I can't get it where I can increment "i"

for now I edit that code like this

Code:
        std::set<int>::iterator iter_EffNum;
	int i=0;
	iter_EffNum = m_setLandEffectNum.begin();
	for( ; iter_EffNum != m_setLandEffectNum.end(); ++iter_EffNum )
	{
		if( i >= EMLANDEFFECT_MULTI ) break;
		dropChar.nLandEffect[i] = *iter_EffNum;
		++i;
	}

anyone can look that code and give me suggestion?
 
Joined
Mar 12, 2011
Messages
962
Reaction score
589
mine like this..

Code:
std::set<int>::iterator iter_EffNum;
iter_EffNum = m_setLandEffectNum.begin();
for( int i=0; i<EMLANDEFFECT_MULTI; ++i )
{
	for( ; iter_EffNum != m_setLandEffectNum.end(); ++iter_EffNum )
	{
		if( i >= EMLANDEFFECT_MULTI ) break;
		dropChar.nLandEffect[i] = *iter_EffNum;
	}
}

i prefer VS2008 since it support physx engine library..
hope this help..

whoops..i'm sorry for bump this old thread..didnt read the date first before reply.. X_X
 
Skilled Illusionist
Joined
Feb 11, 2010
Messages
302
Reaction score
26
oke geger, thanks for the tips, but, I message you in YM but likely you never online

Can I request your LevelEdit source?
 
Skilled Illusionist
Joined
Feb 11, 2010
Messages
302
Reaction score
26
Yes it can, you need some modification for default int variable in vc7.1

Most important is, you need change class aligment to compatible with with vc7.1

 
Back
Top