The fishening v3: Fishing lures. (#86007)

## About The Pull Request
Over half of the line changes are merely from splitting the
fish_types.dm into several files since it was over 1k lines already.

One of the small issues with fishing right now is RNG. You want to get
some specific fish, and you go through all the micromanaging with hooks,
reels and baits only for the random number god to say "nope", and that's
only going to get worse the more fish are in the game.

However, I've a solution: (unconsumable/reusable) fishing lures, each of
which attracts different fish based on different conditions. The only
caveat is that they require to be spun at set intervals (usually 1 to 3
seconds, depending on the lure, with a second-long window). Worry not,
there're visual cues in the form of a green/red light hovering the
fishing float, so you won't get screwed up by the server slowing down or
whatever.
The whole box of lures (12 so far) can be from cargo for the fair price
of 450 credits.

I've also added 5 new fish: monkfish, plaice, pike, another punnier
variant of the pike, perch and squid. The latter is quite special
because of the ink production trait, which lets players use it to blind
others at a close range and when butchered, it yields an ink sac, which
can be processed into a can of squid ink (one less item exclusive to the
produce console), or thrown at people in a sort-of-similar fashion of
banana cream pies (except it's ink).

<details>
  <summary>Images</summary>

Fishing lures (forgot to take my cursor off the veggie one before the
screenshot):

![immagine](https://github.com/user-attachments/assets/8ba7a0f2-2a9f-4177-9c0d-ebeabd8a0ef7)

The five new fish:

![immagine](https://github.com/user-attachments/assets/1c251079-3b39-48bb-af6c-0a35623953a7)

</details>

<details>
<summary>A table of fish catchable wth each lure (excluding
holodeck)</summary>


![table](https://github.com/user-attachments/assets/dee95855-405b-4945-bfc2-70e816e46109)

</details>

A few more things in the CL, baitfish are a thing now.

## Why It's Good For The Game
There should be ways to contrast some of the RNG fishing has. After all,
it's only going to get more random the more fish are in the game.
Furthermore, I find it disappointing that a lot of food stuff is
exclusive to the ingredients console and there're no other ways to get
it.

## Changelog

🆑
add: Added fishing lures to the game. They don't get used up like baits
and let you catch specific kinds of fish, though they need to be spun
every few seconds. The whole set can be ordered from cargo for 450
credits.
balance: The magnet hook now removes dud chances.
add: Added five new fish types: perch, two types of pike, monkfish,
plaice and squid. Squids have a fairly special ink production trait,
which lets you use them (unless dead) to ink people face at close range,
and can be butchered for an ink sac, which can either be processed into
canned squid ink, or thrown at someone.
fix: Refactored throwing a little. Some items (specifically
components/elements) won't be triggered when caught. no more plates
shattering despite being caught for example.
add: Goldfish, lavaloops, needlefish and armorfish can now be used as
baits.
/🆑
This commit is contained in:
Ghom
2024-09-06 19:50:28 -04:00
committed by GitHub
parent a82fac4c7c
commit 10c2b7364e
66 changed files with 2501 additions and 1523 deletions
+3 -2
View File
@@ -45,9 +45,10 @@
shatter(source, impacted_turf)
/// Tells the parent to shatter if we are thrown and impact something
/datum/element/can_shatter/proc/on_throw_impact(datum/source, atom/hit_atom)
/datum/element/can_shatter/proc/on_throw_impact(datum/source, atom/hit_atom, datum/thrownthing/throwing_datum, caught)
SIGNAL_HANDLER
if(caught)
return
shatter(source, hit_atom)
/// Handles the actual shattering part, throwing shards of whatever is defined on the component everywhere
+2 -2
View File
@@ -27,10 +27,10 @@
/datum/element/firestacker/proc/stack_on(datum/owner, mob/living/target)
target.adjust_fire_stacks(amount)
/datum/element/firestacker/proc/impact(datum/source, atom/hit_atom, datum/thrownthing/throwingdatum)
/datum/element/firestacker/proc/impact(datum/source, atom/hit_atom, datum/thrownthing/throwing_datum, caught)
SIGNAL_HANDLER
if(isliving(hit_atom))
if(!caught && isliving(hit_atom))
stack_on(source, hit_atom)
/datum/element/firestacker/proc/item_attack(datum/source, atom/movable/target, mob/living/user)
+11 -6
View File
@@ -22,11 +22,14 @@
RegisterSignal(target, COMSIG_ITEM_ATTACK_SELF, PROC_REF(open_trash))
if(flags & FOOD_TRASH_POPABLE)
RegisterSignal(target, COMSIG_FOOD_CROSSED, PROC_REF(food_crossed))
RegisterSignal(target, COMSIG_ITEM_ON_GRIND, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_ON_JUICE, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_USED_AS_INGREDIENT, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_ON_COMPOSTED, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_SOLD_TO_CUSTOMER, PROC_REF(generate_trash))
RegisterSignals(target, list(
COMSIG_ITEM_ON_GRIND,
COMSIG_ITEM_ON_JUICE,
COMSIG_ITEM_USED_AS_INGREDIENT,
COMSIG_ITEM_ON_COMPOSTED,
COMSIG_ITEM_SOLD_TO_CUSTOMER,
COMSIG_MOVABLE_SPLAT,
), PROC_REF(generate_trash))
/datum/element/food_trash/Detach(datum/target)
. = ..()
@@ -38,7 +41,9 @@
COMSIG_ITEM_ON_JUICE,
COMSIG_ITEM_USED_AS_INGREDIENT,
COMSIG_ITEM_ON_COMPOSTED,
COMSIG_ITEM_SOLD_TO_CUSTOMER,))
COMSIG_ITEM_SOLD_TO_CUSTOMER,
COMSIG_MOVABLE_SPLAT,
))
/datum/element/food_trash/proc/generate_trash(datum/source, mob/living/eater, mob/living/feeder)
SIGNAL_HANDLER
+8 -3
View File
@@ -28,7 +28,7 @@ GLOBAL_LIST_INIT(freon_color_matrix, list("#2E5E69", "#60A2A8", "#A1AFB1", rgb(0
organ.organ_flags |= ORGAN_FROZEN
RegisterSignal(target, COMSIG_MOVABLE_MOVED, PROC_REF(on_moved))
RegisterSignal(target, COMSIG_MOVABLE_THROW_LANDED, PROC_REF(shatter_on_throw))
RegisterSignal(target, COMSIG_MOVABLE_THROW_LANDED, PROC_REF(shatter_on_landed))
RegisterSignal(target, COMSIG_MOVABLE_IMPACT, PROC_REF(shatter_on_throw))
RegisterSignal(target, COMSIG_OBJ_UNFREEZE, PROC_REF(on_unfreeze))
@@ -54,8 +54,13 @@ GLOBAL_LIST_INIT(freon_color_matrix, list("#2E5E69", "#60A2A8", "#A1AFB1", rgb(0
SIGNAL_HANDLER
Detach(source)
///signal handler for COMSIG_MOVABLE_POST_THROW that shatters our target after impacting after a throw
/datum/element/frozen/proc/shatter_on_throw(datum/target, datum/thrownthing/throwingdatum)
/datum/element/frozen/proc/shatter_on_throw(datum/source, atom/hit_atom, datum/thrownthing/throwing_datum, caught)
SIGNAL_HANDLER
if(!caught)
shatter_on_landed(source, throwing_datum)
///signal handler that shatters our target after impacting after a throw.
/datum/element/frozen/proc/shatter_on_landed(datum/target, datum/thrownthing/throwingdatum)
SIGNAL_HANDLER
var/obj/obj_target = target
if(ismob(throwingdatum.thrower))
+2 -22
View File
@@ -41,15 +41,7 @@
var/datum/fish_source/fish_source = GLOB.preset_fish_sources[configuration]
var/has_known_fishes = FALSE
for(var/reward in fish_source.fish_table)
if(!ispath(reward, /obj/item/fish))
continue
var/obj/item/fish/prototype = reward
if(initial(prototype.show_in_catalog))
has_known_fishes = TRUE
break
if(!has_known_fishes)
if(!fish_source.has_known_fishes())
return
examine_text += span_tinynoticeital("This is a fishing spot. You can look again to list its fishes...")
@@ -60,19 +52,7 @@
return
var/datum/fish_source/fish_source = GLOB.preset_fish_sources[configuration]
var/list/known_fishes = list()
for(var/reward in fish_source.fish_table)
if(!ispath(reward, /obj/item/fish))
continue
var/obj/item/fish/prototype = reward
if(initial(prototype.show_in_catalog))
known_fishes += initial(prototype.name)
if(!length(known_fishes))
return
examine_text += span_info("You can catch the following fish here: [english_list(known_fishes)].")
fish_source.get_catchable_fish_names(user, source, examine_text)
/datum/element/lazy_fishing_spot/proc/explosive_fishing(atom/location, severity)
SIGNAL_HANDLER