Jump to content

[XCL] Knock-off Pharmacy 0.5.2


2 Screenshots

About This File

Adds a new pharmacy to the mall for selling (non-X-Change) knock-off pills.

 

Author: usagitriplesix

 

Knock-off Pharmacy

This mod adds a new store called "Pill Poppa" to the mall.

 

While the mod doesn't include any new pills, it's been created with the intent of giving modders a place to sell non-X-Change "knock-off" pills. So, if it's not a reputable product of the X-Change corporation, this Pill Poppa is probably the place to look for it.

 

Works with X-Change Life v0.20

 

NOTE: The patches require a new game in order to work; old saves will likely not have the pills in the correct stores.

 

Instructions for Players

To use this mod, you need the core Twee file and the media file. The store does not come with any pills on it's own. These need to be added via other mods or through patches. I have included a few patches, but other creators can make their own.

 

Explanation of the available files:

  • REQUIRED: XCL u666 knockoff pharmacy CORE: TWEE and MEDIA files - These two core files  are required to add the store to the mall. All additional files will add different options to the store.

 

Patches for Pills - These patches allow pills/drugs from other mods to be sold through the Pill Poppa pharmacy

  • XCL u666 knockoff pharmacy Patch4BRpills - This is a patch for BR Pill Mod. This will move two of the non-X-Change brand pills to the knock-off pharmacy.
  • XCL u666 knockoff pharmacy Patch4PharmInc - This allows the various Pharm Inc pills (requires Drug Framework 2) to be sold in the store.

 

No Patches Required!"

  • Pill Diagnostic Kiosk - Compatibility with the Pill Poppa store is now built into the mod.
  • U666's Drugs - Compatibility with the Pill Poppa store is now built into the mods.

 

For Modders:

Chuck from the XCL Discord provided me with a solution for making Drugs/Pills show up in the Pill Poppa pharmacy if players happen to have it installed (and default to the X-Change pharmacy if not), without requiring a patch. I've included the details and samples below, if you'd like to add your own pills to the store.

 

Which pills do I feel belong here? Lore-wise, I figure the X-Change Pharmacy will sell only official X-Change-branded products, thus Pill Poppa would sell any third-party "knockoff" pills or other potentially dangerous drugs. If that sounds like what you've made, you might want to consider including it.

 

Details on how to do it in the spoiler tag:


 

Spoiler

Here's the core logic we'll be using. The idea here is that you drug/pill will show up in Pill Poppa and not in The X-Change Pharmacy if the player has this mod installed. The "if:" section is where your KO-Pharm-compatible passage should go. The "else-if:" section should remain blank (it displays for the XC Pharmacy), and the "else:" section should be the default version of your code that displays in the XC Pharmacy if the player doesn't have this mod:

 

  (if:((passage:"__mods__")'s source contains "Knockoff Pharmacy") and ($current_location is "Pill Poppa"))
    []
  (else-if:((passage:"__mods__")'s source contains "Knockoff Pharmacy"))
    []
  (else:)
    []

 

This mod adds the following passage tags that you can use for your mod:

  • ko_pharmacy_options - For adding additional options to the pharmacy
  • ko_browse_pills - For browsing the store's pill inventory
  • ko_purchase_pills - For purchasing transformable pills (see code examples for how to setup "drugs")

 

In the case of adding your pill, you'll be using both the base game's "browse_pills" passage tag, and the KO Pharm's "ko_browse_pills" tag. 

 

Here's how the code looks for my Cock-Up drug:

 

:: drug listing CockUp [browse_pills ko_browse_pills]
{==
    <!-- Drugs sold in Pill Poppa Go here-->
    (if:((passage:"__mods__")'s source contains "Knockoff Pharmacy") and ($current_location is "Pill Poppa"))
        [
            <span class='shadow'>Cock-Upâ„¢ -  $80</span> (link:"Select")
                [
                    (set:$select to "CockUp")
                    (set:$price to 80)
                    (set:$next to "drug purchase CockUp")
                    (display:"change screen")
                ]
            (nl:1)
        ]
    <!-- X-Changed Pharmacy gets an empty passage when the mod is installed -->
    (else-if:((passage:"__mods__")'s source contains "Knockoff Pharmacy"))
        []
    <!-- Without the mod, the drug should display in the base-game pharmacy -->
    (else:)
        [
            <span class='shadow'>Cock-Upâ„¢ -  $80</span> (link:"Select")
                [
                    (set:$select to "CockUp")
                    (set:$price to 80)
                    (set:$next to "drug purchase CockUp")
                    (display:"change screen")
                ]
            (nl:1)
        ]

:: drug purchase CockUp
{==
    (if:$select is "CockUp")[
        <span class='shadow'>Cock-Upâ„¢</span>
        <br/><br/>
        (print:"By: Rexor")(nl:1)
        (print:"Need a big dick for the night? Cock-Up's got you covered!")(nl:1)
        (print:"Disclaimer: Independent studies suggest frequent use of Cock-Up is associated with periodic lapses in concentration. Use with discretion.")(nl:1)

        (if:((passage:"__mods__")'s source contains "Knockoff Pharmacy") and ($current_location is "Pill Poppa"))
            [(display: "ko shop buy drug")]
        (else-if:((passage:"__mods__")'s source contains "Knockoff Pharmacy"))
            []
        (else:)
            [(display: "shop buy drug")]
    ]

 

Note that in the "drug purchase" passage, the only real difference is sending the player to the "ko shop buy drug" passage, so they stay in the correct store.

 

Edited by emes
Updated links and more information for modders.


What's New in Version 0.5.2   See changelog

Released

  • Re-Added the MEDIA file. Whoops!
  • Updated CORE file to 0.5.2 to fix issues with passage tags


×
×
  • Create New...