Example #1
0
bool SoundFX::GetInfoString(uint32 line, PString &description, PString &value)
{
	// Is the line number out of range?
	if (line >= 4)
		return (false);

	// Find out which line to take
	switch (line)
	{
		// Song Length
		case 0:
		{
			description.LoadString(res, IDS_SFX_INFODESCLINE0);
			value.SetUNumber(songLength);
			break;
		}

		// Used Patterns
		case 1:
		{
			description.LoadString(res, IDS_SFX_INFODESCLINE1);
			value.SetUNumber(maxPattern);
			break;
		}

		// Supported/Used Samples
		case 2:
		{
			description.LoadString(res, IDS_SFX_INFODESCLINE2);
			value = "31";
			break;
		}

		// Actual Speed (BPM)
		case 3:
		{
			description.LoadString(res, IDS_SFX_INFODESCLINE3);
			value.SetUNumber(GetBPMTempo());
			break;
		}
	}

	return (true);
}
Example #2
0
bool JamCracker::GetInfoString(uint32 line, PString &description, PString &value)
{
	// Is the line number out of range?
	if (line >= 3)
		return (false);

	// Find out which line to take
	switch (line)
	{
		// Song Length
		case 0:
		{
			description.LoadString(res, IDS_JAM_INFODESCLINE0);
			value.SetUNumber(songLen);
			break;
		}

		// Used Patterns
		case 1:
		{
			description.LoadString(res, IDS_JAM_INFODESCLINE1);
			value.SetUNumber(patternNum);
			break;
		}

		// Used Instruments
		case 2:
		{
			description.LoadString(res, IDS_JAM_INFODESCLINE2);
			value.SetUNumber(samplesNum);
			break;
		}
	}

	return (true);
}