Skip to content

Adds Slapcrafting #12886

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

Tsar-Salat
Copy link
Contributor

@Tsar-Salat Tsar-Salat commented Jun 11, 2025

About The Pull Request

This adds a component that lets a player craft without the use of the crafting menu interface.

A set number of objects have the component attached(pipes for pipeweapons, bones for bonearmor) and when the user applies a constituent part that is in the recipe list with that object, it will queue the user to complete that recipe.

If there is more than one it will show however many items in the radial.

Ports:

Why It's Good For The Game

It was requested.

Less reliance on the crafting menu

Testing Photographs and Procedure

Screenshots&Videos
dreamseeker_tDPdjIMtqC.mp4

Screenshot 2025-06-11 162209

Changelog

🆑 rkz, carlarctg
add: adds slapcrafting
add: adds sci sunglasses
fix: fixes examine_more
tweak: removed silkstring. All recipes that used it (2) use normal string now.
/:cl:

@Nakalon
Copy link
Contributor

Nakalon commented Jun 11, 2025

We must merge this right this instant

@mrmanlikesbt
Copy link
Contributor

While you're here can you fix pouring reagents on pizza bread? Right now it gives the balloon alert but does nothing.

@Fronsis
Copy link

Fronsis commented Jun 12, 2025

HOLY FUCK WE VANDERLIN NOW!!
Peak

Comment on lines +50 to +53
// Gotta instance it to copy the list over.
recipe = new recipe()
var/list/type_ingredient_list = recipe.reqs
qdel(recipe)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Gotta instance it to copy the list over.
recipe = new recipe()
var/list/type_ingredient_list = recipe.reqs
qdel(recipe)
var/list/type_ingredient_list = initial(recipe.reqs)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

breaks it

Comment on lines +553 to +555
if(result.len)
for(var/i in 1 to (length(result) - 1))
result[i] += "\n"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Github is being silly so I have to do two comments for some reason.
Why not just do result.Join("\n") ?

Suggested change
if(result.len)
for(var/i in 1 to (length(result) - 1))
result[i] += "\n"


to_chat(src, examine_block(jointext(result, "\n")))
SEND_SIGNAL(src, COMSIG_MOB_EXAMINATE, A)
to_chat(src, examine_block("<span class='infoplain'>[result.Join()]</span>"))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
to_chat(src, examine_block("<span class='infoplain'>[result.Join()]</span>"))
to_chat(src, examine_block(span_info(result.Join("\n")))

Comment on lines +18 to +25
/obj/item/weaponcrafting/receiver/create_slapcraft_component()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/piperifle)

AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/obj/item/weaponcrafting/receiver/create_slapcraft_component()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/piperifle)
AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)
/obj/item/weaponcrafting/receiver/Initialize(mapload)
. = ..()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/piperifle)
AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)

Comment on lines +34 to +40
/obj/item/weaponcrafting/stock/create_slapcraft_component()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/smoothbore_disabler, /datum/crafting_recipe/laser_musket)

AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/obj/item/weaponcrafting/stock/create_slapcraft_component()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/smoothbore_disabler, /datum/crafting_recipe/laser_musket)
AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)
/obj/item/weaponcrafting/stock/Initialize(mapload)
. = ..()
var/static/list/slapcraft_recipe_list = list(/datum/crafting_recipe/smoothbore_disabler, /datum/crafting_recipe/laser_musket)
AddElement(
/datum/element/slapcrafting,\
slapcraft_recipes = slapcraft_recipe_list,\
)

)
category = CAT_EQUIPMENT

/datum/crafting_recipe/scienceglassesremoval
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kind of a confusing typepath name.

Suggested change
/datum/crafting_recipe/scienceglassesremoval
/datum/crafting_recipe/science_sunglasses

Comment on lines +304 to +306
add_glasses_slapcraft_component()

/obj/item/clothing/glasses/sunglasses/advanced/proc/add_glasses_slapcraft_component()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
add_glasses_slapcraft_component()
/obj/item/clothing/glasses/sunglasses/advanced/proc/add_glasses_slapcraft_component()

desc = "A pair of tacky purple sunglasses that allow the wearer to recognize various chemical compounds with only a glance."
clothing_flags = SCAN_REAGENTS

/obj/item/clothing/glasses/sunglasses/advanced/chemical/add_glasses_slapcraft_component()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/obj/item/clothing/glasses/sunglasses/advanced/chemical/add_glasses_slapcraft_component()
/obj/item/clothing/glasses/sunglasses/advanced/chemical/Initialize(mapload)
. = ..()

@BarteG44
Copy link
Contributor

slapcrafting is superior to menus in every conceivable way honestly. the only disadvantage is not knowing all the recipes but i genuinely believe that learning them is an integral part of the ss13 experience

Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link

github-actions bot commented Jul 6, 2025

This PR has been marked as stale due to being in an unmergable state for 7 days. Please resolve any conflicts and add testing evidence, then contact a project maintainer to have the stale label removed.

@github-actions github-actions bot added the Stale label Jul 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants