Desynced

Desynced

Not enough ratings
[Outdated maybe] Sample base maid and auto deconstructor all in one
By Mathazzar
This House Mouse design scoops up dropped items in your power grid. If any buildings are giving off a specific signal, it will go and deconstruct them for you too.
2
   
Award
Favorite
Favorited
Unfavorite
Introduction
Hello,

I've never created a guide before, but I saw this topic come up on the discussion boards a few times.

This little guide goes over a sample base maid and building deconstructor all in one. It will search debris to pickup in the power grid first. If it fails to find anything needing picking up, it will deconstruct any building with the red signal. You can change this signal if you like.

I'm no expert at this. I'm pretty new at these types of games, but I figured why not? Maybe someone is struggling too.

Edit: 2023/08/30 - added the battery check to a subroutine, inspired by Zarek in the comments, so you can call it up across multiple builds easily. It'll send the bot to the nearest power grid or to the store in case of emergencies. I'm unable to figure out a pathfinding logic. The quickest way to fix this is to build base maids on opposite sides of impassible features, I suppose.

You can also set one of the radar conditions to VALLEY or PLATEAU. So it'll only go if the target is in whatever terrain you want it to be in.
Setting up for success
For this little cake we're baking, we'll need a few things.
  1. A bot
  2. A radar
  3. A Deconstructor
  4. A behavior chip
  5. And somewhere you want to drop things off at

Here's where it took a bit of experimenting for me. I'm not very good at this, but it works for me. There are simpler ways to make a base maid (Just a radar and setting the GOTO to the result of the radar for example) but I wanted this to also deconstruct.

First, I do a little housekeeping programing. This part is optional.



This program calls a subroutine for checking battery level and returning for charging if the battery level is too low. You can create a subroutine by creating a Behavior in the library like usual, I just call it Battery Subroutine.
  1. It will get the battery percentage and assign it to variable A.
  2. It will compare Variable A to 30% (My cut off for return to base parameters)
  3. If it has less than or equal to 30% battery remaining, it checks the radar for the nearest power grid location for charging. If first checks its battery again to see if it has more than 1% power to run the radar, if not, it just heads to the STORE target.
  4. If there is a nearby power grid, it will move to that power grid for charging.
  5. If there is no nearby power grid or battery is too low to run the radar, it will go to the STORE location to wait for charging.
  6. If battery level is above 30%, it'll continue out of the subroutine just fine.

On other units, I also check for full hp before it goes out but I'm not expecting the maid to get caught out in combat very often.

You may also want to add a Wait Tick command after the MOVE to power grid to make sure it doesn't get stuck at a loop at the edge of 30% and 31%. I haven't had an issue with it going to the STORE for charging because it'll usually be in the power grid for a large portion of its travel at that point.

Programming
With housekeeping out of the way it's time to get into the full programming of the House Mouse. You will need to add a parameter (at the top of the behavior screen).



  1. Call the Battery Subroutine to do its thing of checking the battery level and charging if it's too low.
  2. Check for inventory space if battery is good to go. If not, head home to drop them off in STORE.
  3. Check radar for any dropped items in the power grid area. If there is, it will head over to it by uploading directly into the GOTO parameter. It will automatically pick it up.I set my filters as 1. Dropped Items and 2. Power Grid.
  4. If no result comes back on radar for dropped items in the power grid, it will check for anything giving out the red SIGNAL. It first looks for the closest one via LOOP SIGNAL. This compares each signal against every other of the same signal. Each time one of the signals is found to be closer, it updates the PARAMETER 1 slot.
  5. Once all the red SIGNALs are done being compared and the closest one is determined and in the PARAMETER 1 slot, it outputs this to the move command.
  6. It will head over to the building to be demolished using the Move (ASYNC) command so its checking for closer things and its battery the entire time. It gets this location from PARAMETER 1.

It may be better to not use ASYNC commands, but this is how I have it going.
Let it run.


If you added a parameter in the programming section, you're good to go here, just some linking.

We will want to set parameter 1 (Next to the behavior chip) to feed into the target of the Deconstructor. You could set this as feeding from GOTO parameter, but I decided not to in case it accidentally messed up picking up objects.

Set your STORE parameter to a box for drop off and sorting.

Then release the mouse. You will need to hit the Start behavior button to the right of the inventory slots.

Edit: How to set the demolition signal
Okay, so you want to destroy a building. Here's how.

First, select the building(s) you want to destroy. You can click drag, shift click, one at a time, it doesn't matter. You can change all of their signals at the same time, or copy paste it onto them.

Next, click the signal button.



Then, we need the information tab.



And then, pick the color red (or whatever your symbol is).

Conclusion? Outro?
Once again, I'm pretty new at this type of game and making guides in general.

If anyone else is struggling and doesn't want to watch a video, here you go.

I am thinking of replacing the descontruction Move (ASYNC) with a generic MOVE command. This is so it prevents some of the behavior of it bouncing back and forth you may see, but I havn't had it fail to deconstruct something as long as it isn't carting materials around.
21 Comments
Mathazzar  [author] 31 Oct, 2023 @ 10:37am 
May have been part of a recent update messing with it. I'm going to change this to an outdated guide.
Obiben27 31 Oct, 2023 @ 9:51am 
It gets most of the way deconstructed and then restarts for some reason. Just added a timer to the end and it fixed
Mathazzar  [author] 30 Oct, 2023 @ 9:06am 
Can you explain the loop? I didn't have it as an issue.
Obiben27 30 Oct, 2023 @ 3:29am 
Its stuck in a loop for deconstruct. How do i fix?
diablo34226 16 Sep, 2023 @ 5:43am 
How do i copy the bluprint code into my game?
Mathazzar  [author] 5 Sep, 2023 @ 12:13am 
Thanks Solsund. I apologize for my lack of response here, it's just.. Starfield came out and I have lost all self control.
Solsund 4 Sep, 2023 @ 3:27pm 
You'll still have to drag from the Behavior Module to the Deconstructor in order to get the deconstruction running.
Solsund 4 Sep, 2023 @ 3:25pm 
For anyone who wanted a blueprint code for the above code.

DSC10z1WlAKG0tiinj1ENs4y4Z0H6W2jCXx43b6o8O0KbEyl3srknd3FrCgw1tKQFr31IiGy1pijcr2eCqnv0i4F2l0zSQnq2HSJUm2Gt80P40gRcs34vVvn4NsCp12GML7d4TCJ8G20JEHy47bN9Z1XOvGo20mO2306Xio13odWLk0SXwWq0hWPmN1CWeCI4Q2ES82bFKiP1Y7ts11XwtMm48Pg1X3FMfs42wulqE151FhI3oDtib0gE8Ds0nUoeR3X1IoJ0dbdu534yA2c2xi0pa1YKKKz1xy3Ep4a07js2VV7pA0wopZr0sba9s1mjLrj1s0dO91c1Lxb4gNqBh1EnoAC0jlDE20DyCEY2Syv2Q1qykCJ3Wj7aM3bnDBj2K1RhV0ex9ND1uWAOn2GDDDb1f3DkQ2c3PPi2MEnQR3hypje2CDZrl1UH8kk1ay0r317357l1BQc7N06LZI21Ss7xT10f8UN05Yjo60suSnJ1FLML34dHhLQ39VTVP1SZe5d4Cmuai1cu7al0hYHCe1QLE6P4McsCN0BJweE1FtltS11vjLH02uwt12LbBYA2HbQIh18S8fg0HeKiU0LcIhs251BV52iKXMV3dYQFZ2N7vwo4dJbiI1mu5aC3CzhPh0MKC4242LDbN397zPD4DWDOK2tUvly0n7uVz0PnfsS4Q6kJI1X7y970ESyzb20y9XJ0Zpn8H0fc0Ef0CHgp20czmGN4C2RLf3BK5up2hZLo93ZrWjY14z2qr39jynm34QOTs31tE9d0IbaAI10xuDa1YlXjO3mP0UI374kKK2qRt3Z28S4FJ0RuLOL2qk7xu08h1PK3FHv3P4BqAaT1eBRKi0URV08128hsR06dWXe4K0vqm0q8biV0oCRT50onLGp2ysl1R3UyeAj36St1o3n0Oh32BtoSN38J
Zarek 2 Sep, 2023 @ 11:34pm 
Hicsy, its weird, but its asking if 30 is greater than battery, insteado f battery greater than 30
ben1techie 2 Sep, 2023 @ 8:33am 
Can you paste a clipboard copy of this in the comments¿