[A12] BeanTek Mods (Refrigerated Food Storage/Blast Door)

Started by beany_for_ever, April 16, 2015, 12:10:28 PM

Previous topic - Next topic

beany_for_ever

Refrigerated Food Storage

Description:
Replaces the vanilla hopper with a refrigerated one.
Adds a Food Tray Rack that keeps prepared meals fresh.
Thanks to skullywag for the rack artwork.



How to install:
- Unzip the contents and place them in your RimWorld/Mods folder.
- Activate the mod in the mod menu in game.

Compatibility:
This should work with any mod that doesn't overwrite the original hopper.

Notes:
The Hopper/Rack simply sets the rot to 0 and health to max of any rottable item stored. It's a little unfair since you can place damaged items in the hopper and it will restore them to 100%, however the power requirement makes it more efficient to build a walk in freezer than an array of these hoppers/racks.

If you just want the Rack then delete the file Buildings_Production.xml from the Defts\ThingDefs\ folder - you will keep the vanilla hopper then.

I give my permission to include this in any modpacks (with credit please).

Change Log:
1.0 - Initial Alpha 10 release
1.1 - Added food tray rack
1.11 - Compiled against Alpha 10b
1.11 - Compiled against Alpha 11 - major code change was that object SlotGroupParent became an interface ISlotGroupParent along with lots of XML changes - no changes needed for Alpha 12

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;         // Always needed
using Verse;               // RimWorld universal objects are here (like 'Building')
using RimWorld;            // RimWorld specific functions are found here (like 'Building_Battery')

namespace BeanTek
{
    class Building_RefrigeratedStorage : Building_Storage, ISlotGroupParent
    {
        public CompPowerTrader powerComp;

        public override void SpawnSetup() {
            base.SpawnSetup();
            this.powerComp = this.GetComp<CompPowerTrader>();
        }

        public override void TickRare() {
            if (this.powerComp.PowerOn) {
                CompRottable aCompRot;
                foreach (ThingWithComps aThing in this.slotGroup.HeldThings) {
                    foreach (ThingComp aComp in aThing.AllComps) {
                        if (aComp.GetType() == typeof(CompRottable)) {
                            aCompRot = (CompRottable)aComp;
                            aCompRot.rotProgress = 0;
                            aThing.HitPoints = aThing.MaxHitPoints;
                        }
                    }
                }
            }
        }
    }
}


Blast Door

Description:
A re-creation of the blast door from the Alpha 7 TTM mod into a stand-alone mod. I plan for this mod to evolve into a Fallout style vault door with remote terminals.

WATCHOUT that the open door makes the inside count as the outdoors, consider it a Fallout style Vault door.


  • The blast door is not animated, instead it magically opens with a puff of smoke.
  • It has a 6 second closing/opening delay so you can't open the door, fire out a couple of shots and duck back behind your massive front door ;)
  • When damaged there is a chance it will jam when closing, you will then have to either wait for it to un-jam itself or send someone to repair it back to full health. While jammed it acts like an open door.

Thanks to Minami for the original work and I hope he returns to the scene soon.

Closed/Opened/Jammed


How to install:
- Unzip the contents and place them in your RimWorld/Mods folder.
- Activate the mod in the mod menu in game.

Compatibility:
This should work with any mod since it is a standalone new item.

Notes:

I give my permission to include this in any modpacks (with credit please).

Change Log:
1.0 - First release
1.1 - Alpha 11

[attachment deleted due to age]

HBKRKO619


Igabod

I like the idea of this. I'll probably end up making a refrigerator texture (or more likely just borrowing one from somewhere else) and making a new item for my own personal use. I would set it up to accept only meals so I can just put a refrigerator in the dining area with 10 meals in it and then store the rest in the walk in freezer. I don't intend on releasing that as a mod myself, but it would probably be a nice addition to this mod.

beany_for_ever

I've added a screenshot, it uses the vanilla texture so I did a screenshot showing that it now requires a power hookup

beany_for_ever

I'm just waiting for permission to re-use someone else's texture then I have a meal tray rack ready to add.

cy-one

@Igabod: I would really like that :D
@beany_for_ever, would the meal tray rack still override the hopper?
And, does the "refridge hopper" work without power like a normal hopper (without refridging), or would it stop working alltogether?

beany_for_ever

The tray rack would be a separate piece of furniture. With the vanilla nutrient paste machine code it only accepts ingredients from the vanilla hopper, I originally created a new hopper to work alongside the original but the paste machine wouldn't use it.

Without power the hopper becomes an expensive to build normal hopper - raw food starts to rot (unless you have the hopper in a freezer but that kinda misses the point of this mod).


Kaballah

Plantable trees is already obsolete, Tynan turned it back on in today's update.


dareddevil7

I messed with the tray rack texture a bit and came up with something i tried to make look like one of those big 2 door freezers, did it turn out well?

[attachment deleted due to age]

LanMc

This is very cool!  Going to try this out with Alpha 10!  Thanks!

Lan
Hi, my name is Lan and I am a Rimworld addict...


dareddevil7


dareddevil7