Difference between pages "Quest Tracking Preferences" and "Compiling from Source"

From Kolmafia
(Difference between pages)
Jump to navigation Jump to search
imported>Bale
 
(Update Linux / Mac instructions to be more consistent about fetching updates from the remote repository.)
 
Line 1: Line 1:
{{TOCright}}
+
=== GREAT BIG NEWS ===
KoLMafia internally tracks progress for a number of quests. These are stored as preferences in settings\[charactername]_prefs.
 
  
==Quests Granted by Familiars==
+
==KoLmafia has migrated to the GitHub repository and we are retooling for GIT and gradle builds.==
===questF01Primordial===
+
The Windows, Linux and macOS instructions have been updated, and might have been lightly tested
=unstarted
 
===questF02Hyboria===
 
=unstarted
 
===questF03Future===
 
=unstarted
 
===questF04Elves===
 
=unstarted
 
===questF05Clancy===
 
=unstarted
 
  
==Guild Quests==
+
The good news is that the IDE setup is a lot easier.  The bad news is you'll need to take some steps to build anything.  In addition, we are discussing changing to a newer required JDK, so even these instructions will not be permanent.
===questG01Meatcar===
 
Possible values: unstarted, started
 
  
===questG02Whitecastle===
+
To contribute to the Mafia project, you'll need to be able to install the Java Development Kit, connect to the git repository, and be comfortable writing Java Code. Instructions for the first two are included below:
=unstarted
 
===questG03Ego===
 
=started
 
===questG04Nemesis===
 
=started
 
===questG05Dark===
 
=unstarted
 
===questG06Delivery===
 
=unstarted
 
  
==Quests Granted by Items==
+
==Windows==
===questI01Scapegoat===
+
# Download Tools
=unstarted
+
## Download and install Java Development Kit 11 or newer, available from [https://adoptium.net/installation.html Adoption].  The current recommended version is Java 17.
===questI02Beat===
+
## Download and install GIT following the instructions from [https://www.atlassian.com/git/tutorials/install-git#windows Atlassian's GIT install page.]
=unstarted
+
## Download and install Tortoise GIT (if needed) from https://tortoisegit.org
 +
# Configure Windows Environment Variables[[File:Environment vars.jpg|thumb|Win 10 Environment Variable Editor]]
 +
## Windows 10
 +
### Go to settings
 +
### type 'enviro' in the search
 +
### click on the 'edit environment variables' suggestion
 +
### add or edit JAVA_HOME, and PATH variables<br>''PATH should include JAVA_HOME''</br>If the JAVA installer has already set these variables, they can be updated or left alone.
 +
# Open a new Command Prompt (or Powershell) window and navigate to the directory to which you wish to create kolmafia (e.g. <code>cd %USERPROFILE%\projects</code>, or some similar directory)
 +
# Clone the source code for the KoLmafia Project.<br>
 +
##''If you have a github account:''<syntaxhighlight lang="bash">
 +
git clone git@github.com:kolmafia/kolmafia.git</syntaxhighlight>
 +
##''If not:''<syntaxhighlight lang="bash">git clone https://github.com/kolmafia/kolmafia.git</syntaxhighlight>
 +
# Compile KoLmafia with the Gradle wrapper ''<syntaxhighlight lang="bash">cd kolmafia && gradlew.bat runShadow</syntaxhighlight>''
  
==Council Quests==
+
=== Optional ===
===questL02Larva===
+
If you intend to commit code to GitHub, you will need to follow GitHub's instructions for [https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token adding a Personal Access Token (PAT)]
=finished
+
==Linux==
===questL03Rat===
 
=finished
 
===questL04Bat===
 
=finished
 
===questL05Goblin===
 
=finished
 
===questL06Friar===
 
=finished
 
===questL07Cyrptic===
 
=finished
 
===questL08Trapper===
 
=finished
 
===questL09Lol===
 
=unstarted
 
===questL09Topping===
 
=finished
 
  
====booPeakProgress====
+
Do once:
booPeakProgress tracks the hauntedness level of {{kolwiki|A-boo Peak}}. A value of 18, for instance, indicates that A-boo Peak is 18% haunted.
+
# Install git - you probably already have this. If not, follow [https://www.atlassian.com/git/tutorials/install-git#linux this guide.]
 +
# Get an appropriate JDK. If your package manager does not contain a sufficiently up-to-date version of Java, the safest and easiest way to do this is with [https://adoptium.net/installation.html#x64_linux-jdk Adoptium].
 +
# Clone the repo:
 +
## If you have a github account:<syntaxhighlight lang="bash">
 +
git clone git@github.com:kolmafia/kolmafia.git
 +
</syntaxhighlight>If not:<pre>git clone https://github.com/kolmafia/kolmafia.git</pre>
  
Possible values: 0 - 100
+
Do every session:
 +
# Set up your environment to use that JDK you just downloaded<pre> export PATH="/where/you/put/that/jdk/bin:${PATH}"</pre> (Optionally, put this in your ''.profile'' or ''.bashrc'' if you want to set and forget.)
 +
# Navigate to your cloned repository: <pre>cd /where/you/cloned/kolmafia</pre>
 +
# Get new updates with <pre>git pull</pre>  If you have local uncommitted changes, you may want to instead use ''git stash && git pull && git stash pop''.
 +
# Build the new jar: <pre>./gradlew clean shadowJar</pre>
  
====chasmBridgeProgress====
+
You have a KoLmafia jar file that can be invoked with <pre>java -jar dist/KoLmafia-*.jar</pre>
chasmBridgeProgress tracks the player's progress in building a bridge across the {{kolwiki|Orc Chasm}}. A value of 10, for instance, indicates that the bridge is 10 planks long.
 
  
Possible values: 0 - 30
+
Do other installation steps as you wish.
====oilPeakProgress====
 
oilPeakProgress tracks the remaining pressure at {{kolwiki|Oil Peak}}. It decreases as the player reduces the pressure in the zone.
 
  
Possible values: 0.00 - 310.66
+
==macOS==
* 310.66: Pressure not yet reduced
+
# Verify required packages
* 0.00: Subquest completed
+
## <code>''java --version''</code>
 +
##* if not found or less than Java 11...  Install Java Development Kit version 17 from [https://adoptium.net Adoptium Temurin]
 +
## <code>''git --version''</code>
 +
##* If not found ...  Install git:  Atlassian has a great document on [https://www.atlassian.com/git/tutorials/install-git the various ways to install Git]
 +
# Configure development environment<br>Most of these steps can be included in ''<code>.profile</code>'' or the equivalent for your terminal of choice.
 +
## In the terminal set JAVA_HOME to the java home directory. <br>''<code>/usr/libexec/java_home -V</code>'' will list all known values for java_home.<br>If you have multiple copies of java, choose the version you want to use''.'' <code>''export JAVA_HOME=`/usr/libexec/java_home -v17''</code>
 +
# Open a new terminal window and navigate to the directory to which you wish to create kolmafia (e.g. <code>cd ~/projects</code>, or some similar directory)
 +
# Clone the source code for the KoLmafia Project.<br>
 +
##''If you have a github account:''<syntaxhighlight lang="bash">
 +
git clone git@github.com:kolmafia/kolmafia.git</syntaxhighlight>
 +
##''If not:''<syntaxhighlight lang="bash">git clone https://github.com/kolmafia/kolmafia.git</syntaxhighlight>
  
====twinPeakProgress====
+
Do every session:
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>
+
# Navigate to your cloned repository: <pre>cd ~/projects/kolmafia</pre>
void comma(buffer b, string s) {
+
# Get new updates with <pre>git pull</pre> If you have local uncommitted changes, you may want to instead use ''git stash && git pull && git stash pop''.
if(length(b) > 0)
+
# Compile KoLmafia with the Gradle wrapper: ''<syntaxhighlight lang="bash">./gradlew runShadow</syntaxhighlight>''
b.append(", ");
 
b.append(s);
 
}
 
  
boolean mysterious(int progress, int c) {
+
=== Optional ===
return (progress & (1 << c)) == 0;
+
If you intend to commit code to GitHub, you will need to follow GitHub's instructions for [https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token adding a Personal Access Token (PAT)]
}
+
''[[Category:Tech Support]]''
 
 
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>
 
 
 
===questL10Garbage===
 
=finished
 
===questL11MacGuffin===
 
=finished
 
 
 
====questL11Black====
 
Tracks Black Market discovery
 
 
 
====questL11Manor====
 
=finished
 
 
 
=====wineCellarProgress=====
 
=3
 
 
 
====questL11Palindome====
 
=finished
 
 
 
====questL11Pyramid====
 
=finished
 
 
 
=====gnasirProgress=====
 
gnasirProgress is a nibble bitmask with one bit for each possible way you can advance {{kolwiki|Quest_for_the_Holy_MacGuffin|Gnasir's quest}}. You can parse this with bitwise operators. Here's some code that demonstrates how to use it.
 
<syntaxhighlight>
 
int gnasirProgress = get_property("gnasirProgress").to_int();
 
buffer gnasir;
 
if((gnasirProgress & 1) == 0)
 
print("Gnasir wants a stone rose");
 
if((gnasirProgress & 2) == 0)
 
print("Gnasir wants a can of black paint");
 
if((gnasirProgress & 4) == 0)
 
print("Gnasir wants a killing jar");
 
if((gnasirProgress & 8) == 0)
 
print("Gnasir wants a 15 worm-riding manual page");
 
if((gnasirProgress & 16) == 0)
 
print("You need to use a drum machine to ride the worm");
 
</syntaxhighlight>
 
 
 
====questL11Ron====
 
Ron Copperhead
 
 
 
=====zeppelinProtestors=====
 
Tracks protesters removed
 
 
 
====questL11Shen====
 
Shen Copperhead
 
 
 
====questL11Worship====
 
=finished
 
 
 
=====questL11Business=====
 
=====questL11Curses=====
 
=====questL11Doctor=====
 
=====questL11Spare=====
 
 
 
 
 
=====hiddenApartmentProgress=====
 
hiddenApartmentProgress tracks progress through the {{kolwiki|Hidden Apartment Building}} during the Quest for the Holy MacGuffin.
 
 
 
Possible values: 0, 1, 6 - 8
 
* 0: Haven't opened the Hidden Apartment Building
 
* 1: Hidden Apartment Building is open for adventuring
 
* 6: Encountered the Protector Spirit
 
* 7: Found the stone sphere
 
* 8: Placed the stone sphere in the relevant overgrown shrine
 
 
 
=====hiddenBowlingAlleyProgress=====
 
hiddenBowlingAlleyProgress tracks progress through the {{kolwiki|Hidden Bowling Alley}} during the Quest for the Holy MacGuffin.
 
 
 
Possible values: 0, 1, 6 - 8
 
* 0: Haven't opened the Hidden Bowling Alley
 
* 1: Hidden Bowling Alley is open for adventuring
 
* 6: Encountered the Protector Spirit
 
* 7: Found the stone sphere
 
* 8: Placed the stone sphere in the relevant overgrown shrine
 
 
 
=====hiddenHospitalProgress=====
 
hiddenHospitalProgress tracks progress through the {{kolwiki|Hidden Hospital}} during the Quest for the Holy MacGuffin.
 
 
 
Possible values: 0 - 8
 
* 0: Haven't opened the Hidden Hospital
 
* 1: Hidden Hospital is open for adventuring, but haven't bowled.
 
* 2-5: Number of times bowled is 1 less than hiddenHospitalProgress
 
* 6: Encountered the Protector Spirit
 
* 7: Found the stone sphere
 
* 8: Placed the stone sphere in the relevant overgrown shrine
 
 
 
=====hiddenOfficeProgress=====
 
hiddenOfficeProgress tracks progress through the {{kolwiki|Hidden Office Building}} during the Quest for the Holy MacGuffin.
 
 
 
Possible values: 0, 1, 6 - 8
 
* 0: Haven't opened the Hidden Office Building
 
* 1: Hidden Office Building is open for adventuring
 
* 6: Encountered the Protector Spirit
 
* 7: Found the stone sphere
 
* 8: Placed the stone sphere in the relevant overgrown shrine
 
 
 
=====hiddenTavernUnlock=====
 
hiddenTavernUnlock tracks whether or not you have unlocked the {{kolwiki|Hidden Tavern}} during the Quest for the Holy MacGuffin.
 
 
 
Possible values: 0 - N
 
* When the value is equal to your number of ascensions, the Tavern is unlocked
 
* When the value is any other number, the Tavern is locked
 
 
 
===questL12War===
 
=finished
 
 
 
====warProgress====
 
Possible values for the progress of the {{kolwiki|Mysterious Island Quest|Isle War}}:
 
*unstarted: We can still visit the small version of the Mysterious Island
 
*started: The war is in progress
 
*finished: The final boss or bosses were defeated
 
 
 
====sideDefeated====
 
Which side of the {{kolwiki|Mysterious Island Quest|Isle War}} was defeated during the Level 12 quest.
 
 
 
Possible values:
 
*neither
 
*hippies
 
*fratboys
 
*both
 
 
 
===questL13Final===
 
=finished
 
 
 
==Miscellaneous Quests==
 
===questM01Untinker===
 
=finished
 
===questM02Artist===
 
=unstarted
 
===questM03Bugbear===
 
=unstarted
 
===questM04Galaktic===
 
=started
 
===questM05Toot===
 
=unstarted
 
===questM06Gourd===
 
=unstarted
 
===questM07Hammer===
 
=unstarted
 
===questM08Baker===
 
=unstarted
 
===questM09Rocks===
 
=unstarted
 
===questM10Azazel===
 
=finished
 
===questM11Postal===
 
=unstarted
 
===questM12Pirate===
 
=finished
 
===questM13Escape===
 
=unstarted
 
===questM14Bounty===
 
=unstarted
 
===questM15Lol===
 
=started
 
===questM16Temple===
 
Dakota Fanning's quest to find the Hidden Temple
 
 
 
===questM17Babies===
 
Lady Spookyraven's Babies
 
 
 
===questM18Swamp===
 
Marty and His Swamp Problems
 
 
 
===questM19Hippy===
 
Hippy Give a Hippy a Boat...
 
 
 
===questM20Necklace===
 
Lady Spookyraven's Necklace
 
 
 
===questM21Dance===
 
Lady Spookyraven's Dance
 
 
 
==Sea Quests==
 
===questS01OldGuy===
 
=finished
 
===questS02Monkee===
 
=unstarted
 
 
 
====merkinQuestPath====
 
merkinQuestPath indicates which path the player has chosen in the {{kolwiki|Mer-Kin Deepcity}}, during the {{kolwiki|Sea Monkees Quest}}.
 
 
 
Possible values:
 
* none: Player has not yet chosen a path
 
* gladiator: Player will fight Yog-Urt, Elder Goddess of Hatred
 
* scholar: Player will fight Shub-Jigguwatt, Elder God of Violence
 
* done: Player has completed the Sea Monkees Quest
 
 
 
====skateParkStatus====
 
 
 
==Bug Bear Invasion Properties==
 
 
 
===mothershipProgress===
 
mothershipProgress tracks progress of level completion in the {{kolwiki|Bugbear Mothership}}. It goes from 0 to 3 as that level is cleared.
 
 
 
Possible values: 0-3
 
 
 
===statusEngineering===
 
===statusGalley===
 
===statusMedbay===
 
===statusMorgue===
 
===statusNavigation===
 
===statusScienceLab===
 
===statusSonar===
 
===statusSpecialOps===
 
===statusWasteProcessing===
 
All of these work the same way.
 
*0-x (integers): insufficient bodata collected)
 
*open: all biodata collected and zone accessible
 
* unlocked: biodata collected but zone not yet accessible
 
* cleared: zone has been cleared
 

Revision as of 13:28, 6 December 2021

GREAT BIG NEWS

KoLmafia has migrated to the GitHub repository and we are retooling for GIT and gradle builds.

The Windows, Linux and macOS instructions have been updated, and might have been lightly tested

The good news is that the IDE setup is a lot easier. The bad news is you'll need to take some steps to build anything. In addition, we are discussing changing to a newer required JDK, so even these instructions will not be permanent.

To contribute to the Mafia project, you'll need to be able to install the Java Development Kit, connect to the git repository, and be comfortable writing Java Code. Instructions for the first two are included below:

Windows

  1. Download Tools
    1. Download and install Java Development Kit 11 or newer, available from Adoption. The current recommended version is Java 17.
    2. Download and install GIT following the instructions from Atlassian's GIT install page.
    3. Download and install Tortoise GIT (if needed) from https://tortoisegit.org
  2. Configure Windows Environment Variables
    Win 10 Environment Variable Editor
    1. Windows 10
      1. Go to settings
      2. type 'enviro' in the search
      3. click on the 'edit environment variables' suggestion
      4. add or edit JAVA_HOME, and PATH variables
        PATH should include JAVA_HOME
        If the JAVA installer has already set these variables, they can be updated or left alone.
  3. Open a new Command Prompt (or Powershell) window and navigate to the directory to which you wish to create kolmafia (e.g. cd %USERPROFILE%\projects, or some similar directory)
  4. Clone the source code for the KoLmafia Project.
    1. If you have a github account:
      git clone git@github.com:kolmafia/kolmafia.git
      
    2. If not:
      git clone https://github.com/kolmafia/kolmafia.git
      
  5. Compile KoLmafia with the Gradle wrapper
    cd kolmafia && gradlew.bat runShadow
    

Optional

If you intend to commit code to GitHub, you will need to follow GitHub's instructions for adding a Personal Access Token (PAT)

Linux

Do once:

  1. Install git - you probably already have this. If not, follow this guide.
  2. Get an appropriate JDK. If your package manager does not contain a sufficiently up-to-date version of Java, the safest and easiest way to do this is with Adoptium.
  3. Clone the repo:
    1. If you have a github account:
      git clone git@github.com:kolmafia/kolmafia.git
      
      If not:
      git clone https://github.com/kolmafia/kolmafia.git

Do every session:

  1. Set up your environment to use that JDK you just downloaded
     export PATH="/where/you/put/that/jdk/bin:${PATH}"
    (Optionally, put this in your .profile or .bashrc if you want to set and forget.)
  2. Navigate to your cloned repository:
    cd /where/you/cloned/kolmafia
  3. Get new updates with
    git pull
    If you have local uncommitted changes, you may want to instead use git stash && git pull && git stash pop.
  4. Build the new jar:
    ./gradlew clean shadowJar

You have a KoLmafia jar file that can be invoked with

java -jar dist/KoLmafia-*.jar

Do other installation steps as you wish.

macOS

  1. Verify required packages
    1. java --version
      • if not found or less than Java 11... Install Java Development Kit version 17 from Adoptium Temurin
    2. git --version
  2. Configure development environment
    Most of these steps can be included in .profile or the equivalent for your terminal of choice.
    1. In the terminal set JAVA_HOME to the java home directory.
      /usr/libexec/java_home -V will list all known values for java_home.
      If you have multiple copies of java, choose the version you want to use. export JAVA_HOME=`/usr/libexec/java_home -v17
  3. Open a new terminal window and navigate to the directory to which you wish to create kolmafia (e.g. cd ~/projects, or some similar directory)
  4. Clone the source code for the KoLmafia Project.
    1. If you have a github account:
      git clone git@github.com:kolmafia/kolmafia.git
      
    2. If not:
      git clone https://github.com/kolmafia/kolmafia.git
      

Do every session:

  1. Navigate to your cloned repository:
    cd ~/projects/kolmafia
  2. Get new updates with
    git pull
    If you have local uncommitted changes, you may want to instead use git stash && git pull && git stash pop.
  3. Compile KoLmafia with the Gradle wrapper:
    ./gradlew runShadow
    

Optional

If you intend to commit code to GitHub, you will need to follow GitHub's instructions for adding a Personal Access Token (PAT) '