Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Learn me good!
Re: Learn me good! [message #411275 is a reply to message #411274] Wed, 18 November 2009 08:09 Go to previous messageGo to previous message
reborn is currently offline  reborn
Messages: 3231
Registered: September 2004
Location: uk - london
Karma:
General (3 Stars)
Hex wrote on Wed, 18 November 2009 10:06

Hand written so some parts prob wrong

class PresetList
{
public:
	static char Preset[256];
	static float Points;
};

void PresetList()
{
	char Dir[64];	
	char Preset_[256];
	float Points_;
	GetCurrentDirectory(64, Dir);
	strcat(Dir, "\\Presets.ini");
	INIClass *ini = Get_INI(Dir);
	if(!ini)
	{
		return 0;
	}


	ini->Get_String("Presets", "Preset", "ERR", Preset_, 256);
	ini->Get_Float("Presets", "Points", "ERR", Points_, 256);

	strcpy(Preset,Preset_);
	Points = Points_;
	Release_INI(ini);
}



That's the sort of thing I was looking for, thanks man. I've only ever used the wrapper, so it was nice of you to post that. Thanks! In Love



 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: request - Nod Rocket Soldier bug
Next Topic: music not working for map
Goto Forum:
  


Current Time: Mon Dec 23 13:46:45 MST 2024

Total time taken to generate the page: 0.00729 seconds