Skip to content
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

Plastic sheet production - Chemistry recipe #26940

Merged
merged 6 commits into from May 7, 2017
Merged

Plastic sheet production - Chemistry recipe #26940

merged 6 commits into from May 7, 2017

Conversation

FantasticFwoosh
Copy link
Contributor

@FantasticFwoosh FantasticFwoosh commented May 5, 2017

🆑 Moonlighting Mac
Experiment: Due to budget cuts and oil synthesis replacing expensive processes of digging up haunted primeval ashwalker burial grounds, Nanotransen has taught chemists how to make plastic from chemicals in the hopes that new plastic products can reduce expenditure on metal and glass.
add: you can now make plastic sheets from chemistry out of heated up crude oil, ash & sodium chloride
/:cl:

This Pr is atomised from what was originally planned but functionally it allows a methodical way of getting plastic within the game in a usually small quantity (100 units of formula = 10 sheets), making it over and over again would be tedious to discourage mass production and still keep some value to importing a lot of it if you need it.

Look forward to more plastic products in the future to compliment this.

Nothing particularly fancy about it, toxic to consume (obviously not a great idea) compliments its crafting recipe which is far more interesting.
Now compiles and runs correctly, has been tested and works as expected (a little charcoal residue if there is leftover heated oil & ash but that's a nice touch) issues mostly down to my own silly little errors. 100 units in the reagent ratio = 10 sheets of plastic.
@tgstation-server tgstation-server added the Feature Exposes new bugs in interesting ways label May 5, 2017
@FantasticFwoosh FantasticFwoosh changed the title Plastic sheet production - Chemistry recipie Plastic sheet production - Chemistry recipe May 5, 2017
M.adjustToxLoss(1, 0)
. = 1
..()

Copy link
Member

Choose a reason for hiding this comment

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

So is this reagent ever actually made?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was a bit of a oversight post testing and realizing it was there. I left it in there in the case the recipe changes later (if people want to make glitter) or somehow people manage to cheat to get the reagent. It should be generic toxic (its not like i want people chugging it) anyway but its dead code not worth bothering about.

Didn't quite realise the action to make the plastic sheet actually consumed it instantly. Oops.

Short answer is in its liquid form it is not, futureproofing i guess.

Copy link
Member

Choose a reason for hiding this comment

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

Don't put in reagents that are producible "just in case", just take it out. You literally described it as dead code.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Well that's just my working excuse but since you mention it, sure ill just remove it before a maintainer blocks me with a crate of oranges requesting changes.

@lordpidey
Copy link
Contributor

I like it. I especially like how it's possible to make some without using a chem dispenser.

Burn paper for ash
Salt shaker from bar
Scoop up oil from maint


/datum/chemical_reaction/plastic_polymers/on_reaction(datum/reagents/holder, created_volume)
var/location = get_turf(holder.my_atom)
for(var/i = 1, i <= created_volume, i++)
Copy link
Contributor

Choose a reason for hiding this comment

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

not how we do loops fam

Copy link
Contributor Author

Choose a reason for hiding this comment

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

P.S - that's borrowed from the cheese making recipe, so your irks are probably demanded there. It works anyway. (edit - soap is identical, it didn't compile at first so i adapted it in line with the other recipes on the crafting page)

What exactly did i do wrong papa goof.

Copy link
Contributor

Choose a reason for hiding this comment

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

read the contributing guidelines

Copy link
Contributor

Choose a reason for hiding this comment

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

don't be rude goof he is learning!

Copy link
Contributor

Choose a reason for hiding this comment

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

if you are going to copypaste, use the Plasma solidification / Gold solidification as a base

Copy link
Contributor

Choose a reason for hiding this comment

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

oh my god you idiot I want you to fix the for loop formatting to

go by the guidelines I told you to read

Copy link
Contributor

Choose a reason for hiding this comment

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

which you obviously didn't read by the way

go read them

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I wish they had big font text like your posts. (You mean this part right?) just linking it would have been more helpful for somebody learning like myself.

All i wanted to do was make some plastic and i get caught up in demands for changes as to what i can gather that should have been applied to the entire spaghetti file.

'Muh Legacy' oldcode. Any more news about Remie @ExcessiveUseOfCobblestone? Contact me on the forums or the IRC if you can.

Copy link
Contributor

Choose a reason for hiding this comment

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

@FantasticFwoosh
for(var/i = 1, i <= created_volume, i++)
->
for(var/i in 1 to created_volume)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I noticed it too late @Militaires , ill fix it up.

@RemieRichards is this a explanation of the change or are you requesting that i should change it again because yours is more optimal?

Listening to feedback removing dead code for a chem that won't be seen, and a minor description change.
/datum/reagent/plastic_polymers
name = "plastic polymers"
id = "plastic_polymers"
description = "the petroleum based components of plastic, contact a coder if you can actually see this"
Copy link
Contributor

Choose a reason for hiding this comment

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

I want to say you can see this in the chem master so probably not best to have this breaking the meta wall.

Copy link
Member

Choose a reason for hiding this comment

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

Although you shouldn't define an unobtainable reagent anyway

Copy link
Contributor

Choose a reason for hiding this comment

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

oh lol yes if this isn't suppose to be made then don't have it :^)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

But you can't because the reagent is instantly consumed when it makes the plastic and is therefore inaccessible. If you can see it and have it stablised in a beaker to study it in such a position, its a bug.

Copy link
Contributor

Choose a reason for hiding this comment

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

if I get my github functioning on my desktop i'll set this up for you bb.

If you want to do it scrap it all and have it setup JUST LIKE the gold/plasma solidification.

https://github.com/FantasticFwoosh/tgstation/blob/83b15478140cd3e662bcf029310aa14dd31d2fd6/code/modules/reagents/chemistry/recipes/others.dm#L50

Copy link
Contributor

Choose a reason for hiding this comment

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

you can see chem descriptions, yeah

As to conform with community guidelines. Personally as a coder freshman i have no idea how this works, but half of me is glad its more compact way to type out.
@octareenroon91
Copy link
Contributor

Ash and sodium chloride make charcoal already

@FantasticFwoosh
Copy link
Contributor Author

FantasticFwoosh commented May 6, 2017

Yes, but thats why you mix the oil first, divide or create some oil to heat into ash, then add all the components to a cool beaker & heat up for plastic. It doesn't harshly overlap if you do it in a acceptable sequence.

If you make uneven amounts, it can leave residue charcoal from a hot beaker in the attempt to make plastic: Intended.

@octareenroon91
Copy link
Contributor

Then you're fighting a race condition. It's sensitive to whatever the DM and DD feel like doing.

@lordpidey
Copy link
Contributor

Hmm, it might be best to bump up the required temp for charcoal then. Right now it's at 380, which is very close to 376.

@FantasticFwoosh
Copy link
Contributor Author

FantasticFwoosh commented May 6, 2017

No its not, stop fretting.

If you put in the exact reagent formula it makes, the oil forces the plastic recipe first. (5 oil, 2 salt, 3 ash) rather than the ash & salt together in heat & add oil (because thats illogical to heat up salt), in testing practice it's been consistent with my mixing method all the while.

Im not going to change it because people want to mix to make charcoal hence are being silly about their chemistry method order.

@imtakingabreakdontatme
Copy link
Contributor

What can plastic even be used for?

Converting our infinite energy into matter never ends well

@FantasticFwoosh
Copy link
Contributor Author

FantasticFwoosh commented May 7, 2017

Right now plastic flaps & plastic golems (merged prior this post) but i plan to expand upon the system more and make it more widespread, covering some holes in production of objects.

spray bottles, blood bags etc.

That is unless you want to change oil completely and make us mine it out of the ground via mekhi pumps on lava-land.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Exposes new bugs in interesting ways
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

10 participants