In-code keypress handling system - This whole system is heavily based off of forum_account's keyboard library.
Thanks to forum_account for saving the day, the library can be found
here!
content/Merchant System Modpack - This modpack contains the systems for Merchants. The modpack does not contain any merchant content, meaning that there are no merchants included. Instead, a merchant content modpack, such as Standard Merchants, must also be included in order for players to be able to buy and sell things to merchants.
Modpack Compatibility System - This folder exists as a way to work around the fact that the previous system for modpack cross-compatibility, define-gating, is sensitive to include order. This resulted in a lot of boilerplate, like having to emit warnings if modpacks were included in the wrong order. This meant that you could also introduce cyclical dependencies, where no matter what it would emit a warning and content would be missing.
decompose_matrix - Datum which stores information about a matrix decomposed with decompose().
diploma_details - Details used by the diploma plaques for display.
effect/effect/system/trail - ///// Attach an Ion trail to any object, that spawns when it moves (like for the jetpack)
just pass in the object to attach it to in set_up
Then do start() to start it and stop() to stop it, obviously
and don't call start() in a loop that will be repeated otherwise it'll get spammed!
steam - Attach a steam trail to an object (eg. a reacting beaker) that will follow it
padding - An extension that unifies padding state and interactions.
scent - Scent extensions
Usage:
To add:
set_extension(atom, /datum/extension/scent/PATH/TO/SPECIFIC/SCENT)
This will set up the extension and will make it begin to emit_scent.
To remove:
remove_extension(atom, /datum/extension/scent)
generated_fauna_template - An internal template to generate randomized planet fauna that's adapted to where it was generated to spawn on.
grid_load_metadata - Fill a given tile with its area/turf/objects/mobs
Variable model is one full map line (e.g /turf/unsimulated/wall{icon_state = "rock"}, /area/mine/explored)
level_data - Keeps details on how to generate, maintain and access a zlevel.
planetoid - Base level data for levels that are subordinated to a /datum/planetoid_data entry.
A bunch of things are fetched from planet gen to stay in sync.
exoplanet - Level data for generating surface levels on exoplanets
grass - Surface of a grass exoplanet
underground - Level data for generating underground levels on exoplanets
planetoid - Base map template for planetoids, which need to instantiate a planetoid data object early during template spawn.
Can be used to load a planetoid from a map file.
random - A randomly generated "tempate" for an planet-like objects. Meant to standardize how random planets are generated so it behave like all other map templates.
exoplanet - Random map generator for exo planets
barren - Template for spawning a randomly generated barren exoplanet.
grass - Map template for generating a grass exoplanet
memory - Memories
merchant - Represents an NPC which the crew (or others) can trade with.
bakery - A bakery that sells baked goods, such as cakes and pies.
Like most other retail-themed merchants, the price is static for everyone.
books - A very eccentric merchant who sells a wide array of skill books.
Compared to most other merchants, they are quite bad at holding firm on a desired price point.
With a combination of financial acumen, shrewed negotiation, and sweet words, it's fairly simple to cheat them out of a lot of credits.
dogan - A mysterious trading beacon, presumably managed by a simple algorithm that communicates with pre-recorded phrases that were added by "Mr. Dogan".
Because of that, there is no ability to negotiate with the beacon, making the prices set in stone.
Most of the products are of very dubious quality.
drugstore - A merchant who sells devices, odds and ends, and some basic medical supplies.
Like most other retail-themed merchants, their prices are set in stone and they don't buy anything.
grocery - A grocery store. In space, for reasons. They sell basic food and ingredients for cooking, such as eggs and milk.
Like other retail-themed merchants, their prices are static and they don't buy anything.
medical - An unscrupulous merchant with an alleged medical background. They sell a wide array of medical supplies,
and in return, ask for booze, tobacco, and occasionally organs.
They are often the only game in town when it comes to medicine, and their prices reflect that.
mining - An AI-managed smelting platform which buys ores and sells some material sheets and mining supplies.
Like other AI-themed merchants, they have a higher than average skill level, yet they do not change their prices based on disposition, and can't really get annoyed.
pizzaria - A non-descript pizzaria that somehow is able to sell pizza to spacefarers for a modest price.
Like other retail-themed merchants, prices cannot be influenced.
trading_beacon - A trading outpost managed by a fairly sophisticated artificial intelligence. They ask for a wide range of random things, and sell products within their particular focus.
Like other AI-themed merchants, they are highly skilled in trade and are likely to have an advantage in negotiations.
They will also not play favorites, and will not consider disposition as a factor in pricing.
They also essentially have infinite patience and won't care about most things that might offend merchants made out of flesh.
transient - Subtype for merchants which appear randomly at trade hubs as the round goes on, and disappear after enough time has passed.
chinese_restaurant - A chinese restaurant, in space.
clothing_shop - Sells various kinds of clothes.
This one in particula rsells shirts, pants, dresses, and jumpsuits.
hats_gloves_accessories - This merchant sells hats, gloves, and some accessories (for people, not accessories for hats or gloves).
shoes - This merchant sells exclusively shoes.
damaged_ship - A ship that suffered an unspecified incident and is willing to buy supplies, mainly engineering related, but also some medication.
electronics_store - Sells electronic components and some consumer electronics.
energy_gun_shop - A merchant who sells some high tech weapons, and batteries, for some reason.
gun_shop - A merchant who sells firearms. What it says on the tin.
pet_shop - Buys and sells various kinds of animals and animal accessories.
prank_shop - A very calm merchant who sells things that clowns would enjoy, if they still existed.
rare - Subtype for merchants which should only show up at trade hubs rarely, and disappear after enough time has passed.
severance - A rare merchant who trades rifles for 'long pork'.
replica_shop - A weird merchant who sells a mix of fantasy themed costumes and actual weapons, for whatever reason.
robot_seller - A traveling merchant who sells basic robotics.
smuggler - A sneaky 'merchant' who requires a bribe for be tradeable (usually).
When that happens, they stop being a temporary merchant (temporarily), however they will instead leave quickly after completing any transaction.
This allows someone to form a plan in order to make a big sale, or accumulate enough cash to buy something coveted and presumably illegal.
toy_shop - A merchant who sells games, plushies, and other toys.
They buck the trend with retail-themed merchants. They seek to complete their collection of action figures, and can be haggled with.
vox - A cheeky Vox merchant who sells mostly junk, in exchange for shiny things. They don't want cash.
xeno_shop - A merchant who seeks to collect alien lifeforms, and is willing to sell the supplies used to capture them.
They also might sell surplus space carp. The fish are untamed, so beware.
Any potential creatures that they ask for must be brought back alive.
merchant_commodity - This holds information about a particular thing a merchant wants to buy or sell.
Generally these will be created in bulk by one or more /decl/merchant_potential_commoditiess held by a merchant instance's potential_[supply|demand] lists,
and then placed inside that merchant's active_[supply|demand] lists.
mil_branch - Datums for military branches and ranks
planet_flora - Contains data about the flora found on a planetoid, and facilities to pick and spawn them randomly.
This base type is meant to be used on its own only for fixed flora lists defined at compile time.
random - A randomly generating planet_flora data datum
grass - Flora data for a grass exoplanet
planetoid_data - Data for a planetoid. Used by SSmapping for keeping track of a lot of details about specific planetoids.
random - A randomly generating planetoid_data, used by random planet map_templates
Timed Event - This is the actual timer, it contains the callback and necessary data to maintain
the timer.
trade_hub - Essentially a container for merchants.
overmap - These trade hubs are represented by an object on the overmap.
To interact with them, players' vessels need to be within the same tile as the overmap object.
singleton - Used for legacy maps, maps without an overmap, or maps that don't want to use the overmap hubs.
It is unconditionally accessible anywhere on the map (overmap or otherwise).
crystalline - This is NOT to be used in place of ORGAN_PROP_CRYSTAL.
It doesn't handle crystalline logic, only setting up organs as crystalline
on their initial creation.
accumulated - This material type has mob effects based on accumulated dose.
If the drug has been in your system enough to accumulate a dose,
and the level of it in your bloodstream drops below a certain volume,
you will get discontinuation effects.
If it is above that volume or hasn't been in your system long enough to accumulate,
you will get the positive effects.
solid/organic/plantmatter/pith - Used for plant products that aren't quite wood, but are still tougher than normal plant matter.
memory_options - Memory Options
merchant_commodity_requirement - Used to impose criteria that the merchant can use to compare against to determine if they want to accept a possible transaction involving a specific commodity instance.
This is generally only used for items attempting to be sold to merchants. The most basic form of this is generally 'is this the correct type?', but other requirements can also be used to add more complexity.
empty - Requires that an object which can hold gases be empty.
Primarily exists to have the requirement read better. "empty canister" vs "canister containing nothing".
Also stops people from scamming merchants who are asking for stuff like portable scrubbers, where players could fill them with expensive gas and sell them for extra.
Parameter-less.
ratio - Require that an object which can hold gas have a certain ratio of gases contained.
Parameters are an assoc list of gas material decls as well as the desired ratio.
If only one gas is listed, the object must have only that gas inside, or in other words, it must be pure.
If multiple gases are listed, it is allowed to deviate very slightly from the required ratio. Unlisted gases are not allowed.
temperature - Require that an object which can hold gas have it be close to a specific temperature.
Parameter is a numeric value representing the desired temperature of the gas, in kelvin.
material - Require that an object be made out of a specific material.
Parameter is a single material decl type path.
mobs
is_alive - Require that a mob be either alive or dead. Unconsciousness counts as living.
Parameter is a single value that is TRUE or FALSE. TRUE requires that mobs are alive, while FALSE requires that mobs are dead.
synth - Functions identically to the regular requirement but with robotic flavor.
species - Require that a mob being sold be of a particular species.
Parameters are a list of species decls that are wanted.
reagents
empty - Requires that an object which can hold reagents be empty.
Primarily exists to stop people from scamming merchants by selling them beakers filled with expensive chemicals that they never asked for.
Parameter-less.
has_reagents - Require that an object which can hold reagents have one or more of the reagents wanted.
Parameters are a list of desired reagent decls.
ratio - Require that an object which can hold reagents have specific reagents at at certain ratio.
Parameters are an assoc list of reagent decls along with the wanted ratios.
type - Contains all forms of type checks.
This will generally be the most common requirement used.
anything - Essentially allows anything to pass.
Useful if you want a merchant that buys almost anything, or if you want to restrict by other criteria besides type.
Parameterless.
exact_type - Basic type check which requires the type to be the exact same.
Parameter is the type to be checked against.
type_or_subtype - Basic type check which allows matching types or subtypes to pass.
Parameter is the type to be checked against.
legacy - Attempts to mimic the old merchant inventory behavior, but reaches the terminal state instantly instead of over time.
offer_everything - Makes everything be on the active list unconditionally, i.e. they will always sell (or buy) everything they could.
Use with care for merchants that offer or want a lot of different things.
percentage - Moves a certain percentage of items to the active list on merchant init, permanently.
rotate_over_time - Shifts a number of items between the two lists every so often.
If the merchant is allowed to exist for long enough, they will eventually complete a full cycle and bring back things they 'put away', and vice versa.
merchant_potential_commodities - Determines what things a merchant might buy or sell, by creating /datum/merchant_commodity instances in bulk.
Place inside of a merchant's potential_[supply|demand] list for them to offer to buy or sell things listed in the decl.
These can be reused between different distinct merchants.
gases - Variant which creates gas commodities.
Only works with demand.
materials - Easily creates a lot of demands with distinct material demands, such as material stacks, which would otherwise run into issues with map-spawn instances conflicting with instances created 'natually' in-round.
Only works with demand.
reagents - Variant which easily creates reagent commodities.
Only works with demand.
disposition - Multiplies the value by the input, scaled linearly based on the merchant's current disposition, capping out at /datum/merchant::MAX_DISPOSITION_THRESHOLD.
Negative disposition will scale in the opposite direction.
flat - Adds the input to the value as a flat amount unconditionally.
legacy_skill_disparity - Modifies the price based on the relative skill levels between the user and merchant, with the aim of having parity with the old system if the same inputs are used.
demand - Modifies the price of items the merchant buys based on relative skills while using the same equations as the old system.
supply - Modifies the price of items the merchant sells based on relative skills while maintaining the same prices as the old system.
percentage - Multiplies the value by the inputted input unconditionally. A common use for this is to be the base markup for a merchant. E.g. /decl/merchant_price_modifier/percentage = 1.2 makes the merchant charge 20% extra.
merchant_quantity_method - Used to direct how a particular commodity should be counted when a merchant is buying it.
instances - Counts potential items by counting instances, and in the case of item stacks, how much is in that stack.
This is the default method, and should work in most cases.
moles - Counts potential items by the total amount of moles inside of them.
This should be used if a merchant is intended to buy a certain amount of gas, so they count what's inside the container and not the container itself.
reagent_units - Counts potential items by the total reagent volume inside of them.
This should be used if a merchant is intended to buy a certain amount of reagents, so they count what's inside the container and not the container itself.
merchant_speech - A decl which holds dialogue strings used by merchants.
vox/fellow_vox - Vox merchant switches to this when hailed by another Vox.
mob_modifier - Instanced 'modifiers' that sit on top of a mob and can expire over time or linger until dispelled.
Some are purely visual, others have associated modifiers.
standard_merchants - Includes a number of generic merchants, to be used either as the main content for the Merchants modpack, or as reference material for making new merchants elsewhere.
reagent_data_field/extra_color - An extra colour used for things like additional reagent overlays on soups, so that you can have noodle soup with veggie bits a different colour than the main soup.
error - State that occurs if there is a problem with the drill setup, such as lacking braces.
finished - State which occurs when there is no more ore to mine from the surrounding tiles.
idle - Starting state for drills that are turned on or recovered from an issue.
mining - State where the drill is actively mining a specific turf.
scanning - State that follows the starting state, where it determines which turfs to mine, and gives a visual effect of it scanning the surrounding ground.
storage_full - State which occurs when the ore storage is full, and the player needs to unload the ore for it to resume mining.
switching_target - State which occurs when the currently mined turf is depleted, and there is another turf to mine from,
thus the drill visually targets the next spot and provides some feedback to the player on how fast the mining is going.
unpowered - Unpowered state. Occurs when the battery dies or when turned off.
sign - Item form of the sign structure. Stores a sign structure type, and creates that structure upon install.
Takes on the appearence and properties of whatever sign structure type it contains.
dungeon_bookcase - This spawns either a normal bookcase (20%), a damaged normal bookcase (60%), or a lootable decaying bookcase (20%).
There's also 20% chance to just spawn nothing.
deck - A sign for indicating what level is the current level vertically
directions - Signs for showing the way to passerby. The dir of the sign is the direction it points towards. The icon of the sign itself is always south facing.