Quest Tracking Preferences: Difference between revisions

From Kolmafia
Jump to navigation Jump to search
imported>Paladinwhite
booPeakProgress and chasmBridgeProgress data
imported>Bale
Line 27: Line 27:
=0.00
=0.00
==twinPeakProgress==
==twinPeakProgress==
=15
twinPeakProgress is a nibble bitmask with least significant bit set for the first choice and the most significant for the fourth. You can parse this with bitwise operators. Here's some code that demonstrates how to use it.
 
<syntaxhighlight>
void comma(buffer b, string s) {
if(length(b) > 0)
b.append(", ");
b.append(s);
}
 
boolean mysterious(int progress, int c) {
return (progress & (1 << c)) == 0;
}
 
string twinPeak() {
int p = get_property("twinPeakProgress").to_int();
buffer need;
if(mysterious(p, 0)) need.comma("4 Stench Resistance");
if(mysterious(p, 1)) need.comma("+50% Item Drop");
if(mysterious(p, 2)) need.comma("Jar of Oil");
// Only check for final if first three complete
if(length(need) == 0) {
if(mysterious(p, 3))
return "Need +40% Initiative";
return "Twin Peak Completed";
}
return "Need " + need;
}
</syntaxhighlight>
 
==warProgress==
==warProgress==
=unstarted
=unstarted
==wineCellarProgress==
==wineCellarProgress==
=3
=3

Revision as of 05:48, 13 February 2014

KoLMafia internally tracks progress for a number of quests. These are stored as preferences in settings\[charactername]_prefs.

booPeakProgress

This preference tracks the hauntedness level of A-boo Peak. A value of 18, for instance, indicates that A-boo Peak is 18% haunted.

Possible values: 0-100

chasmBridgeProgress

This preference tracks the player's progress in building a bridge across the Orc Chasm. A value of 10, for instance, indicates that the bridge is 10 planks long.

Possible values: 0-30

gnasirProgress

=11

hiddenApartmentProgress

=8

hiddenBowlingAlleyProgress

=8

hiddenHospitalProgress

=8

hiddenOfficeProgress

=8

hiddenOfficerogress

=8

mothershipProgress

=0

oilPeakProgress

=0.00

twinPeakProgress

twinPeakProgress is a nibble bitmask with least significant bit set for the first choice and the most significant for the fourth. You can parse this with bitwise operators. Here's some code that demonstrates how to use it.

void comma(buffer b, string s) {
	if(length(b) > 0)
		b.append(", ");
	b.append(s);
}

boolean mysterious(int progress, int c) { 
	return (progress & (1 << c)) == 0;
}

string twinPeak() {
	int p = get_property("twinPeakProgress").to_int();
	buffer need;
	if(mysterious(p, 0)) need.comma("4 Stench Resistance");
	if(mysterious(p, 1)) need.comma("+50% Item Drop");
	if(mysterious(p, 2)) need.comma("Jar of Oil");
	// Only check for final if first three complete
	if(length(need) == 0) {
		if(mysterious(p, 3))
			return "Need +40% Initiative";
		return "Twin Peak Completed";
	}
	return "Need " + need;
}

warProgress

=unstarted

wineCellarProgress

=3