PneumaticCraft: Repressurized

PneumaticCraft: Repressurized

50M Downloads

Feature Request: Drones protection from IE cable damage

duncanwebb opened this issue ยท 12 comments

commented

I'm playing a mod pack with pollutions of the realm in and would like to be able to break grass and flowers that the pollution makes.

I reckon that the simplest would to use a dig area or harvest puzzle pieces with filters attached.

Thanks, it's real fun playing this mod.

commented

Hi, that works just great. Many thanks.

I wonder what I was doing wrong, as I tried the dig piece and then became a little more complicated as shown. I reckon that I'd messed up the areas. I don't yet fully understand the flow control, it there a detailed description how this works?

image

commented

Hi, glad you're enjoying it.

What you want can be done already using a Dig piece and the right item filters. I created a tiny program to test this which you can import from here (use the Pastebin button on the left of the programmer GUI): https://pastebin.com/EiL9pjYh

Notes:

  • Grass needs to be matched by block because it doesn't drop itself (the item filter for Dig normally matches by the item that would be dropped, but seeds don't drop reliably from grass). It also needs ignore meta set.
  • The two other filters match all vanilla flowers; all vanilla flowers share only two block ID's so I just set those to ignore meta (note to future self: this will need reworking in 1.13.2 :) You might need some extra item filters if you have other modded flowers.
  • You will of course need to adjust the working area, and the program doesn't do any gathering of the dropped items.

Anyhow, let me know if that does what you need.

commented

Not sure which version of PNC you have, and if Patchouli is in the pack, but if you install the latest version (0.9.3) and add Patchouli, you'll get a detailed guidebook including a section on programming which includes an entry detailing how flow control works. If it's not feasible to do that, you can always take a look at the JSON source for the entry at https://github.com/TeamPneumatic/pnc-repressurized/blob/master/src/main/resources/assets/pneumaticcraft/patchouli_books/book/en_us/entries/programming/flow_control.json

The program you have there looks OK although I can't tell for 100% certain without it loaded into a local programmer.

commented

I playing https://minecraft.curseforge.com/projects/real-tech and has version 1.12.2-0.9.3-324. Doen't have patchouli but I will add it. I did some more testing with your program, adding picking up putting into a chest, putting the drone in sleep mode and bonemealing some more grass it worked great as I expect.

It might be the selection of grass, in this case I used ore dictionary but has used other types, a lot of test cases so I can't remember which was used. https://pastebin.com/Q0p0wkQd.

I hope the drones don't despawn as they some fly into immersive engineering HV cable and die.

commented

Hmm, HV cables would be a danger, and the drones will despawn like any other item after 5 minutes. I could raise that, though - losing a fully-programmed drone would not be much fun.

Does the HV zap instakill them or just hurt them? If the latter, I'd recommend sticking some Item Life upgrades (up to 10) in your drone - then they'll repair any damage they take.

commented

Not 100% sure but I think they don't die instantly. six hearts of damage per hit and I'm usually not fast enough to realize what happened, and blitz myself :-).

I'll add the life upgrades and see what happens. Many thanks for the tip.

As you join my channel, a big welcome, next episode is about logistic drones and you see one get zapped at the beginning.

commented

I'll have a look and see if it's possible to make drones avoid IE cables. Not sure how easy/difficult that'll be since I don't know how IE implements them. Time for a bit of source code browsing :)

Or it might be easier just to make drones invulnerable to IE wire damage...

commented

It might be the selection of grass, in this case I used ore dictionary but has used other types, a lot of test cases so I can't remember which was used. https://pastebin.com/Q0p0wkQd.

I hadn't fully understood what you meant by match by block and metadata unticked until now now it's clear.

commented

Flying around wires that sag more that a block would indeed be tricky. Invulnerability would would be nice as I guess that they are intended to take an route that avoids obstacles.

Of course I could run the HV cables underground to the compressor.

commented

I have a plan for IE cable protection: adding a Security Upgrade to a Drone will prevent electrical damage from cables, but will cost some air, proportional to the damage. For LV, that cost will be trivial, but for HV protection it will be quite significant (in current testing, it will take a drone from 10 bar to 1 bar in under 20 seconds if it doesn't move away from a HV cable).

Similarly, a Security Upgrade in the Pneumatic Chestplate will protect players from electrical damage, at the same air cost.

I'm thinking there should still be some knockback, though.

commented

These ideas sound great, a knockback would good, it should push the drone away so it can take another path.

In the chestplate sounds just great, I cannot say how many times HV wires have killed me, with leggings speed it is really easy to catch a wire, get knocked back and walk straight back into the wire, it all happens very fast.

commented

Added in 0.10.4 release.