9 votes

What did you do this week?

As part of a weekly series, these topics are a place for users to casually discuss the things they did — or didn't do — during their week. Did you accomplish any goals? Suffer a failure? Do nothing at all? Tell us about it!

10 comments

  1. [3]
    DMBuce
    Link
    I started a project to overhaul the Minecraft loot tables, then took a detour to set up a templating system for that project. Started by writing my own simple template script that just replaces...

    I started a project to overhaul the Minecraft loot tables, then took a detour to set up a templating system for that project. Started by writing my own simple template script that just replaces {{foo}} in a template with the $foo environment variable if it exists or the contents of file ./foo if it doesn't.

    When I started using the script for the loot table project I realized my needs were more complex than that. I needed support for list- and dictionary-like data structures, and the ability to iterate over them, so I went looking for a real templating system. After considering a bunch of options including mustache, pyratemp, and gomplate, I ended up landing on jinja2 with j2cli.

    Now I've got all the vanilla Minecraft chest loot tables written up in YAML with a jinja template + makefile that turns them into json and bundles them up into a datapack. From here it shouldn't be too hard to implement the huge text document of ideas I have into something that works.

    5 votes
    1. [2]
      AugustusFerdinand
      Link Parent
      And what are some of those ideas? I've played Minecraft for a couple of hours, not my bag, but I can see the appeal.

      From here it shouldn't be too hard to implement the huge text document of ideas I have into something that works.

      And what are some of those ideas? I've played Minecraft for a couple of hours, not my bag, but I can see the appeal.

      2 votes
      1. DMBuce
        (edited )
        Link Parent
        A lot of the vanilla chest loot is usually not that great once you've established yourself somewhat and most of my ideas are basically just "make loot more exciting to find." So, to that end: The...

        A lot of the vanilla chest loot is usually not that great once you've established yourself somewhat and most of my ideas are basically just "make loot more exciting to find." So, to that end:

        • The enchanted books in vanilla loot usually spawn with one random enchantment of a random level. I'm going to make most of them spawn with a 50% chance to be enchanted as if at an enchanting table so that they can have multiple enchants. Enchanted books found in libraries and map rooms will have the other 50% spawn as a treasure enchant instead of a random enchant.
        • The soul speed books and gear normally found in nether chests will have a random treasure enchant instead, and more nether chests will have such books.
        • Most armor & tools will be enchanted at an enchantment level determined by the area the structure spawns in. Aboveground structures will have gear be enchanted at levels 15-20, underground and ocean structures at levels 20-25, nether structures at levels 25-30, and end structures at levels 25-39.
        • More chests will spawn music discs, and it will be possible to find every music disc in a chest instead of just Cat and 13 (and I think one or two others, I forget exactly)
        • Custom explorer maps that lead to other structures. For example, Woodland Mansion chests will have a chance to spawn a Reconnaissance Map that leads to a Pillager Outpost, and the chest in the outpost will have a chance to spawn a Swamp Exploration Map that leads to a Witch Hut. Maps found in Nether Fortresses will lead to Piglin Bastions, and vice versa. End City chests have a chance to spawn a map leading to another End City. Desert Pyramids might lead you to a Jungle Temple. And so on.
        • When exploring, items such as wheat and bread are only really useful as food. I'm replacing stuff like that with potatoes and carrots, which act as both food and seeds; or pie and cookies, which are usually too difficult to craft to be worthwhile. Food is also going to reflect the area you're in a bit -- potatoes and carrots mostly generate in underground structures, while pie and cookies are found in villager and illager buildings.
        • The two most difficult to find structures, End Cities and Woodland mansions, will have their seeds replaced with what I call "treasure seeds". Treasure seeds are an entry on the loot table that generates seeds of a type that you haven't used yet. So e.g. you'll have a chance to find berries if you haven't eaten or planted berries yet. I'm using the word "seed" loosely here, the entry will include everything from wheat seeds and potatoes to cactus, bamboo, and rose bushes. Basically any plantable vegetation that you might want to farm. The entry also has a small chance to spawn Suspicious Stew at first so that once you've collected all the treasure seeds, you'll get Suspicious Stew instead of just nothing.
        • Not sure if I'm going to keep this, but I want to try including a light sprinkle of materials in places where you wouldn't normally have access to those materials. The odd Ender Eye found in overworld chests most likely won't let you skip straight to The End (and if it does how cool would that be?), but would let you make an Ender Chest before going to The Nether. A few bits of quartz found in a Ruined Portal will let you make a redstone component or two, but you'll still need to go to the nether for enough quartz to build large redstone contraptions or big quartz buildings. I think/hope stuff like that in very limited quantity would make a particular playthrough feel a bit more special / memorable.
        • Blocks will generate in loot chests more often. Stopping to mine up more blocks so you can bridge to wherever is kinda annoying when you're out exploring.
        • (EDIT: Remembered a few more things) Saddles, horse armor, nametags and leads will be craftable and removed from the loot tables to make room for the above. I don't want to change the rarity of some entries like ore ingots, and the easiest way to do that is to make sure that everything I add is a replacement for something I removed.
        • Mythic items that generate incredibly rarely and aren't obtainable in normal survival. Things like armor that increases health, elytra that provide a bit of armor, gear with two mutually exclusive enchants on them, boots that increase speed, etc. The idea is that getting one of these items will make your world truly unique, and they should be rare enough that you're only likely to see a handful of them in a long-lived world. Probably this feature will be a separate add-on pack.
        • Also potentially an add-on pack, decorative player heads that look like mini blocks with names like Little Cobblestone, Little Netherrack, etc.

        Keep in mind most of this is subject to change after playtesting, but that's the plan for now anyway. If anyone is interested in more info about the project, you can check out this repository: https://github.com/dmbuce/bucepack . The recent commits have a more detailed, structure-by-structure breakdown of what I've changed so far, and eventually the readme will have more info. Shameless plug while I'm at it, if you scroll down you can check out my other Minecraft resource packs / data packs.

        5 votes
  2. [3]
    AugustusFerdinand
    Link
    Played some 2077, continued working in the garage on the Tercel project. Started with power washing the years of old oil and dirt off the transmission, engine bay, and various components like the...

    Played some 2077, continued working in the garage on the Tercel project. Started with power washing the years of old oil and dirt off the transmission, engine bay, and various components like the oil pan and motor mounts. Warning: If you're looking for /r/powerwashingporn levels of eye candy you'll be disappointed, this was about cleaning it enough to be able to service it without being completely covered in gunk. It still probably weighs at least a pound or two less than it did before the cleaning. There's more to be done on the cleaning side, but I ran out of fuel in the pressure washer and it started raining nearly simultaneously; while it doesn't technically matter as I was already soaked from the pressure washing it's more a matter of getting soaked on my terms.

    Guess that means it's time to continue working on the head. The lost valve retainer has been replaced with new stock, and I can (mostly) reassemble the head to check valve clearances and order new shims if needed. Spoiler alert: I need some new shims. Start by gathering the valve bucket/shim combos in your wife's discarded bakeware and your feeler gauges, add assembly lube to the underside and circumference of the bucket, and put them back where they originally came while grabbing the camshafts for the next step. Lubricate all contact surfaces of the camshafts and shims, place into the head with the exhaust cam at bottom dead center1 and the intake cam at top dead center so they can be torqued down in as close to a neutral position as possible and aren't fighting the valve springs. Cam caps have, very light, indicators on each to tell you their orientation and position as they've been matched to the camshaft journal clearances at the factory2 and are to be placed back in those positions after a little lubrication of course.

    Put in the bolts and torque them down to spec, 130kg/cm, in several even passes working from the center outward not to bend the camshafts. Once torqued down spin the camshaft a few times to ensure there's no binding and then check valve clearances with your feeler gauge.3 If clearances are too small (tight) there won't be enough oil between the surfaces to provide adequate protection, if they are too large (loose) the oil can't properly bridge the gap and protection again fails.4 There's more to it than that as there are oil weights, temperature, additives, forces on components so on and so forth to contend with, but we won't get into that here. Either way there is a range kindly provided by Toyota and that's what we're aiming for. On older cars, such as where this head came from, valve adjustment (what this act of checking clearances and replacing shims is called) was a regular maintenance item just like changing your oil, spark plugs, and timing belt. Check clearances, if out of spec, take measurements of the shims you have, pop down to the auto parts store (or dealership) and buy correctly sized shims, reinstall them and you've adjusted the valves! I'm confident this head has had zero valve adjustments made by the previous owner (see old posts in Timasomo for reference), so I was unsurprised to find that of the 16 valves this head has, 11 are out of spec (one tight, ten loose). Record the clearances and continue to replacement.

    If you want to be pedantic, only five of the valves are out of spec, but six others are on the borderline and I'd like to bring them closer to the middle. Take the camshafts back out and using a screwdriver pop the valve shims off, then admire the beautiful patterns Toyota left while machining the buckets. Keeping the shims in order, measure their thickness to determine the thickness of the new shims you'll order (or move around from one valve to another). Intake valve clearances should be between 0.15 and 0.25mm, exhaust from 0.20 to 0.30mm. The formula to determine new shim thickness is pretty simple: New Shim = Old Shim + (Current Clearance - Desired Clearance)
    Now that you know the new shim thickness you need for each valve you can go buy new ones right? Well yes, if you like throwing away money. Shims are no longer available over the counter at most auto part stores (nor can they even order them), most dealerships don't carry a stock of parts and even if they do they don't like to sell you only a few of things like valve shims so you'll have to buy them in packs, typically of the number of valves your engine has. Did I mention that from the dealer these shims will set you back about $10 each? So for each size of shim you need you'll have to pony up $160 ($10 x 16 valves). In my case I'd need six different sizes (they only come in 0.05mm increments) so I'd be out $960 just for shims! Not interested. Instead you go to the aftermarket and buy either a range of shims in several sizes as a kit for about $175 or individually for about $5 each before shipping. I'm doing the latter, but to minimize cost even further we can swap old shims from one valve to another if the needed thickness matches (or is close enough) as it does in six of my valves.5 Swap the shims around as needed, put those that are to be replaced in a bag (with a little coating of oil so they don't rust) as you might need them during a future valve adjustment, and move on to the next task.

    This has already become longer than I was expecting, but bare with me because now there's dry ice and fire!

    An impressive gif or video (à la @mat's knife making) would have been fun, but my wife was at work, I only have two arms despite the constant radioactive isotope bombardment, and honestly it's just a propane torch and not all that impressive a display, you'll have to settle for photos. In this part we'll be mating floating wrist pins and pistons into press fit rods. A wrist pin is the horizontal pin that connects the piston to the rod. A floating wrist pin rides on a layer of oil in both the piston and rod allowing it to rotate and move laterally a small amount while kept within the piston via circlips. A press fit wrist pin is forced into place (via a press) on the rod and captured there by an interference fit (one of the few times metal on metal contact is permitted in an engine) not allowed to rotate or move as it is held stationary by the rod. Floating is better for making power and lasting longer, press fit is cheaper to produce. I'm using a combination because the pistons would normally be in an engine that uses floating pins, but the rods are from an engine that uses press fit. Yay parts bin engineering!

    The setup: Take the griddle, that you didn't think you'd use all that often but surprisingly do, given to you by your sweet grandmother and (after placing aluminum foil on top to keep the surface from getting automotive oil on it) put your pistons, already loaded with circlips on one side, on it while setting the temp to low so they'll warm to about 175C. Take the wrist pins and put them on dry ice. You want the pistons to expand with heat and the wrist pins to contract from the cold so it's easier to combine the two with the rods. When the pistons have reached temp and the dry ice has stopped screaming from the rapid boiling, take the torch to the small end of the rods for 10-12 seconds to get them to the 275-300C range.

    In quick succession you need to grab one of the hot pistons (you're wearing your welding gloves right?), put it into a vise with the circlipped side facing your non-dominant hand, grab a rapidly warming/expanding wrist pin, hold the hot rod centered in the piston correctly oriented (because the direction the rods and pistons face matters), and push the wrist pin through the rod all the way against the circlip in the piston, then put a couple of drops of assembly lube on the wrist pin near the rod so capillary action will suck it in between the two. You have about three seconds to accomplish all of this or the rod will contract, the pin will expand, and you'll be stuck looking like a fool with a pin sticking a little too far (or a lot too far) out of the piston and have to use mechanical means to get it into place. Mechanical means being a grade 8 threaded rod, nuts, washers, and piece of angle iron to use the wonderful simple machine known as a screw to "press" the pin into place on the rod because your actual hydraulic press is in your storage shed as you don't have room for it in your current garage and haven't had the new detached garage built yet and instead dream of having adequate space to work on the 4.33 cars you now own.

    After you've done that, and fixed your poorly timed mistakes, you can then become frustrated by the fact that you can't continue to work on the block because you've either lost or never purchased the piston rings you need to gap (file the small opening to within spec) in order to install the new pistons and rods into the shortblock. On the one hand you could have sworn you had piston rings already, on the other the part number for the pistons you purchased doesn't have rings listed as one of the included pieces and you have no record of ever buying rings in the first place. So instead you make a long winded post on Tildes, order the rings and valve shims, crack open a beer, and see what others have posted.

    1 Top dead center is when the piston would be at the top of it's stroke with all valves closed on cylinder 1, effectively the moment when the spark plug would ignite the fuel/air mixture in the cylinder when the engine is running. Bottom dead center is the end of the power stroke, 180 degrees of crankshaft rotation later, right before the exhaust valves would open to let the burnt mixture out.
    2

    Technically speaking I should also be checking (among other things) the journal clearances beneath the cam caps as well as the thrust clearance (forward/back movement) on the camshafts, but...

    1. I don't have the proper tools to check thrust clearance, although I could manage with what I do have it'd just be really annoying.
    2. The journals have no signs of abnormal wear despite the mistreatment by the previous owner.
    3. If the thrust, journal, or any other clearance I'm not checking is out of spec the solutions range from replacing the cams to replacing the entire head. None of which I'm willing to do at this point and the lack of wear that would be indicators that these are out of spec says I'm far more likely to be fine than not. So we'll go forward on blind faith in Toyota's reliability and good old fashioned "ignorance is bliss".
    3

    A feeler gauge is a set of precisely machined strips of metal of varying thicknesses to determine the amount of space between two precision machined surfaces. It's called a feeler gauge because you need to feel the thin strips of metal as you probe the clearance area. If the strip is too large it either won't fit in the gap being checked or, if it's close, you'll have to apply significant force to get it into the space. If too thin it'll just slide into the gap with no resistance. You're looking for the strip with a thickness that when probing the gap feels like a knife going into room temperature butter.

    4

    Fun fact: Inside an engine, with very few exceptions, there is no metal on metal contact at all! Everything rides on a thin layer of oil between surfaces that lubricates the movement and cushions all the forces taking place as things spin and get jerked in varying directions thousands of times per minute. Which is amazing when you think about it! You have a chamber, that when filled with fuel and air, holds in an explosion that pushes downward on a surface with enough force that even at idle can outperform the maximum work output of a horse, all without any physical contact whatsoever. And it happens thousands of times per minute even when you're just sitting idle in your driveway having an existential crisis as you contemplate why you do the same thing day after day in a world that does not care about or notice you and in which you'll likely have no long-lasting positive impact whatsoever, therefore disappearing into dust and being forgotten by a universe hurtling toward its own inevitable heat death ...ahem... letting your car warm up.

    Speaking of letting your car warm up, you should. Your car burns the most fuel when it first starts as it needs a fuel rich mixture to start and to get the catalytic converters (the part of your car that does the most work to clean the emissions from the burning of fuel) up to temperature. Also think of oil like molasses, it flows slowly at low temperatures and more easily at high temperatures. The better it flows the better lubrication it provides and the better protection you engine will have. Your car is probably one of the most expensive things you won, or are paying for, and you want it to last as long as possible. So treat it right by getting oil changes regularly (oil breaks down, gets contaminated, and cannot do it's job of protecting your expensive vehicle if you don't change it regularly) and let your car warm up a bit before driving. This betters your fuel economy, lowers emissions, and makes your car last longer. You don't have to wait long at all, just until the needle in your temp gauge has moved to the first line. Note: Temp gauges are becoming more and more rare for some reason (I lament the death factory of the oil temp and pressure gauges), so yours may not have one of these but it will have some way to tell you it's cold, if you're not sure ask me and I'll let you know what to look for (or read your owner's manual).

    5

    Black/bold valves are those out of spec, gray are in spec and don't need replacing, matching colors between columns "Old Shim" and "New Shim" are shims that can be moved from one valve to another to bring them into spec, the two pairs of matching colors that are centered and italicized are shims that can be moved because they're close enough to the desired new shim thickness and will be in spec when moved. Since shims come in 0.05 increments I'm ordering two 3.00mm, one 3.05mm, and two 3.10mm thickness.

    Also worth noting that when a valve adjustment is done normally the head is still on the engine and in the car, so you wouldn't take the camshafts out to change the shims, you'd have a pair of special tools to compress the valve spring and hold it in place while you pop the shim out, but it's a pain in the ass to do so and it's really only one more step to just take the damn camshafts out if you're doing all the expected maintenance at the same time you'd be doing a valve adjustment.

    4 votes
    1. [2]
      Atvelonis
      Link Parent
      This is incredibly detailed, and I promise I'll read it all when I have a moment this weekend. Do you have a blog where you write about car projects or something?

      This is incredibly detailed, and I promise I'll read it all when I have a moment this weekend. Do you have a blog where you write about car projects or something?

      2 votes
      1. AugustusFerdinand
        Link Parent
        Do let me know if you have any questions and feel free to check out the Timasomo thread with links to previous detailed breakdowns on the build if you'd like. Nope. I post in various automotive...

        Do let me know if you have any questions and feel free to check out the Timasomo thread with links to previous detailed breakdowns on the build if you'd like.

        Do you have a blog where you write about car projects or something?

        Nope.

        I post in various automotive forums for project updates and community feedback from interested parties on my niche vehicles, but Tildes is an odd middle ground (that I'm admittedly enjoying) of interested parties that are overall unaware of how things like this are done. I wouldn't make this post in the forums because it'd be met with something along the lines of "Why are you telling us how you did a valve job?" as it's a common knowledge in those circles, like reading a recipe for a basic cake to a baker.

        4 votes
  3. monarda
    Link
    Our household celebrated Christmas on Monday. I didn't put up lights or a tree this year, but we spent the day baking cookies, listening to music, and playing games. We capped the day off with a...

    Our household celebrated Christmas on Monday. I didn't put up lights or a tree this year, but we spent the day baking cookies, listening to music, and playing games. We capped the day off with a dinner of bacon cheeseburgers, homemade mac and cheese, and a movie. It ended up being one of the most pleasant Christmases I've had in a long time. This is the first time in 20 years that I didn't host my exes family, so thanks, Mr. Corona Virus.

    New Years Eve I was just falling asleep when the phone rang at about 11:45 which was very odd. I picked up and it was my happily drunk son calling to wish me a Happy New Years. They were having a small party, and we just chatted about all kinds of things. He put me on speaker as they counted down so I got to enter the new year with him, his closest friends and family. It made me feel so loved and hopeful for 2021.

    Seed catalogues started rolling in this week too!

    4 votes
  4. autumn
    Link
    My partner and I spent three nights in a cabin near Asheville, NC. I was hoping we’d be able to do some decent hikes, but everything we looked at was either blocked because the Blue Ridge Highway...

    My partner and I spent three nights in a cabin near Asheville, NC. I was hoping we’d be able to do some decent hikes, but everything we looked at was either blocked because the Blue Ridge Highway is closed or the trail heads appeared to be on private property, and we didn’t want to risk that. We did do some hiking, and it was nice to be away from the city for a little while. We went to a couple of outdoor seated breweries our second day, and that was really nice, too.

    Once we got back, I’ve been doing a lot of walking/running/indoor biking. Headed out to do some outdoor biking later today since the weather isn’t terrible.

    3 votes
  5. [2]
    Kuromantis
    Link
    My parents went to a relative's house to celebrate the new year and see people shoot fireworks from their homes. (People do that in São Paulo). Unfortunately we went there at 9 PM and there wasn't...

    My parents went to a relative's house to celebrate the new year and see people shoot fireworks from their homes. (People do that in São Paulo). Unfortunately we went there at 9 PM and there wasn't much to do other than dance to generic pop music from a loud speaker they have (which my parents absolutely enjoyed but anyway), eating and playing with a dog that's too active for me, so waiting for midnight was pretty boring for me. Still, when midnight came, the fireworks were nice to hear and see, and to announce the end of 2020, although it quickly got boring for me after the fireworks ended.

    After leaving, we passed through a street where other, closer relatives of mine lived and they were there, so we stopped to meet them. Personally, I enjoyed spending a smaller amount of time talking with them and hearing them talk about stuff quite a bit, and wasn't really sleepy at the time because of that.

    After that, we went back home, I brushed my teeth, upvoted some stuff and went to sleep.

    2 votes
    1. AugustusFerdinand
      Link Parent
      They do that here in Texas as well, even though it's illegal to do so. I don't know what it is, or if there's a specific name for it, but talking to interesting people or people I care about makes...

      people shoot fireworks from their homes. (People do that in São Paulo).

      They do that here in Texas as well, even though it's illegal to do so.

      Personally, I enjoyed spending a smaller amount of time talking with them and hearing them talk about stuff quite a bit, and wasn't really sleepy at the time because of that.

      I don't know what it is, or if there's a specific name for it, but talking to interesting people or people I care about makes me forget time and tiredness. It's one of those nice things about the friends I have, we frequently stay up far too late together because we lose track of time entirely.

      2 votes