/tg/ Station 13 - Modules - TypesVar Details - Proc Details

fish_source

Where the fish actually come from - every fishing spot has one assigned but multiple fishing holes can share single source, ie single shared one for ocean/lavaland river

Vars

backgroundBackground image name from /datum/asset/simple/fishing_minigame
catalog_descriptionHow the spot type is described in fish catalog section about fish sources, will be skipped if null
currently_on_regenA list of stuff that's currently waiting to be readded to fish_counts
dudsText shown as baloon alert when you roll a dud in the table
explosive_fishing_scoreIf FISH_SOURCE_FLAG_EXPLOSIVE_MALUS is set, this will track of how much we're "exhausting" the system by bombing it repeatedly.
fish_count_regenAny limited quantity stuff in this list will be readded to the counts after a while
fish_countsIf a key from fish_table is present here, that fish is availible in limited quantity and is reduced by one on successful fishing
fish_tableFish catch weight table - these are relative weights
fishing_difficultyBaseline difficulty for fishing in this spot. THIS IS ADDED TO THE DEFAULT DIFFICULTY OF THE MINIGAME (15)
overlay_stateWhen selected by the fishing portal, this will be the icon_state of the overlay shown on the machine.
profound_fisher_blacklistMindless mobs that can fish will never pull up items on this list
radial_stateWhen linked to a fishing portal, this will be the icon_state of this option in the radial menu
wait_time_rangeIf set, this overrides the upper and lower bounds of how long you should wait during the waiting phase of the minigame.
weight_leveling_exponentsList of exponents used to level out the table weight differences between fish depending on bait quality.
weight_result_multiplierList of multipliers used to make fishes more common compared to everything else depending on bait quality, indexed from best to worst.

Procs

calculate_difficultyCalculates the difficulty of the minigame:
calculate_difficulty_minigameCalculates the difficulty of the minigame:
dispense_rewardGives out the reward if possible
generate_wiki_contentsCalled by /datum/autowiki/fish_sources unless the catalog entry for this fish source is null. It should Return a list of entries with keys named "name", "icon", "weight" and "notes" detailing the contents of this fish source.
get_catchable_fish_namesAdd a string with the names of catchable fishes to the examine text.
get_fish_tableReturns the fish table, with with the unavailable items from fish_counts removed.
get_modified_fish_tableBuilds a fish weights table modified by bait/rod/user properties
has_known_fishesreturns true if this fishing spot has fish that are shown in the catalog.
interrupt_challengeProc called when the challenge is interrupted within the fish source code.
level_out_fishA proc that levels out the weights of various fish, leading to rarer fishes being more common.
on_challenge_completedProc called when the COMSIG_MOB_COMPLETE_FISHING signal is sent. Check if we've succeeded. If so, write into memory and dispense the reward.
on_fishing_spot_delCalled whenever a fishing spot with this fish source attached is deleted
on_fishing_spot_initCalled when src is set as the fish source of a fishing spot component
on_start_fishingCalled below above proc, in case the fishing source has anything to do that isn't denial
pre_challenge_startedUsed to register signals or add traits and the such right after conditions have been cleared and before the minigame starts.
readd_fishCalled when releasing a fish in a fishing spot with the TRAIT_CATCH_AND_RELEASE trait.
reason_we_cant_fishCan we fish in this spot at all. Returns DENIAL_REASON or null if we're good to go
roll_mindless_rewardVersion of roll_reward() that blacklists objects that shouldn't be caught by ai-controlled mobs.
roll_rewardReturns a typepath, instance or another special value which we use for dispensing a reward later.
roll_reward_minigameComsig proc from the fishing minigame for 'roll_reward'
simple_dispense_rewardSimplified version of dispense_reward that doesn't need a fisherman.
spawn_rewardSpawns a reward from a atom path right where the fisherman is. Part of the dispense_reward() logic.

Var Details

background

Background image name from /datum/asset/simple/fishing_minigame

catalog_description

How the spot type is described in fish catalog section about fish sources, will be skipped if null

currently_on_regen

A list of stuff that's currently waiting to be readded to fish_counts

duds

Text shown as baloon alert when you roll a dud in the table

explosive_fishing_score

If FISH_SOURCE_FLAG_EXPLOSIVE_MALUS is set, this will track of how much we're "exhausting" the system by bombing it repeatedly.

fish_count_regen

Any limited quantity stuff in this list will be readded to the counts after a while

fish_counts

If a key from fish_table is present here, that fish is availible in limited quantity and is reduced by one on successful fishing

fish_table

Fish catch weight table - these are relative weights

fishing_difficulty

Baseline difficulty for fishing in this spot. THIS IS ADDED TO THE DEFAULT DIFFICULTY OF THE MINIGAME (15)

overlay_state

When selected by the fishing portal, this will be the icon_state of the overlay shown on the machine.

profound_fisher_blacklist

Mindless mobs that can fish will never pull up items on this list

radial_state

When linked to a fishing portal, this will be the icon_state of this option in the radial menu

wait_time_range

If set, this overrides the upper and lower bounds of how long you should wait during the waiting phase of the minigame.

weight_leveling_exponents

List of exponents used to level out the table weight differences between fish depending on bait quality.

weight_result_multiplier

List of multipliers used to make fishes more common compared to everything else depending on bait quality, indexed from best to worst.

Proc Details

calculate_difficulty

Calculates the difficulty of the minigame:

This includes the source's fishing difficulty, that of the fish, the rod, favorite and disliked baits, fish traits and the fisherman skill.

For non-fish, it's just the source's fishing difficulty minus the fisherman skill.

calculate_difficulty_minigame

Calculates the difficulty of the minigame:

This includes the source's fishing difficulty, that of the fish, the rod, favorite and disliked baits, fish traits and the fisherman skill.

This is the version to call while we are in the fishing minigame phase.

dispense_reward

Gives out the reward if possible

generate_wiki_contents

Called by /datum/autowiki/fish_sources unless the catalog entry for this fish source is null. It should Return a list of entries with keys named "name", "icon", "weight" and "notes" detailing the contents of this fish source.

get_catchable_fish_names

Add a string with the names of catchable fishes to the examine text.

get_fish_table

Returns the fish table, with with the unavailable items from fish_counts removed.

get_modified_fish_table

Builds a fish weights table modified by bait/rod/user properties

has_known_fishes

returns true if this fishing spot has fish that are shown in the catalog.

interrupt_challenge

Proc called when the challenge is interrupted within the fish source code.

level_out_fish

A proc that levels out the weights of various fish, leading to rarer fishes being more common.

on_challenge_completed

Proc called when the COMSIG_MOB_COMPLETE_FISHING signal is sent. Check if we've succeeded. If so, write into memory and dispense the reward.

on_fishing_spot_del

Called whenever a fishing spot with this fish source attached is deleted

on_fishing_spot_init

Called when src is set as the fish source of a fishing spot component

on_start_fishing

Called below above proc, in case the fishing source has anything to do that isn't denial

pre_challenge_started

Used to register signals or add traits and the such right after conditions have been cleared and before the minigame starts.

readd_fish

Called when releasing a fish in a fishing spot with the TRAIT_CATCH_AND_RELEASE trait.

reason_we_cant_fish

Can we fish in this spot at all. Returns DENIAL_REASON or null if we're good to go

roll_mindless_reward

Version of roll_reward() that blacklists objects that shouldn't be caught by ai-controlled mobs.

roll_reward

Returns a typepath, instance or another special value which we use for dispensing a reward later.

roll_reward_minigame

Comsig proc from the fishing minigame for 'roll_reward'

simple_dispense_reward

Simplified version of dispense_reward that doesn't need a fisherman.

spawn_reward

Spawns a reward from a atom path right where the fisherman is. Part of the dispense_reward() logic.