Vehicle Additions Pack (Updated December 8)

The body rams are pretty fucked up anyway. I would recommend getting rid of them, it’s not nearly as fun as I thought to mount zombies on my car.

I’d vote cut it. Cool idea, but not worth hassle/bugs. I’m keeping an eye on this topic btw, so let me know when you feel it’s ready for another update once you’ve got some time to pay with balancing.

Avoid hacks. That way you could keep PRing it into the main repository, rather than forcing anyone interested to reinstall it with every update.

Better cut it out than have to deal with it constantly breaking.

What about the non-rotary one? Did it get non-zero storage?

Additionally:
Having rocks as ammo causes problems for people who craft with rocks. It would be better if you didn’t override the regular rock and instead created something like “smooth rock” or “big pebble” created from a rock, with rock-like properties, but separate from the regular non-stacking rock.

Having metal splinters use disassembly recipes rather than crafting ones is annoying. It would be better to have them appear in crafting menu than in butcher menu.

I like the idea of rocks, have a crafting recipe that takes a couple minutes to make ammo rocks. And also I want to be able to batch-craft metal splinters.

Hm, alright. Body ram is now removed.

The newer experimentals have a fix where ammunition with tool qualities work properly. If you’d still prefer the recipe, I’ll consider it.

More stat balancing. Turrets now hit more and graze less (dispersion still disperses). Range to target is still a huge part of this.

Splintergun ammo now has a crafting recipe. I removed rebar from the recipe, but you can use metal lumps/chunks.

Removed solar panels from the energy turrets. I deemed it unnecessary.

Yes, it can now hold 4 spears. It’s also a fair bit stronger than the rotary version.

Link in OP is updated as always.

Yeah, leave the rocks as-is as we fixed that on our side.

What about a straight up acid gun? Just a big fire-hose that squirts acid?

Or a turret that burns tainted meat to conceal your car in a hazy cloud of poison smoke?

Probably impossible but would be neat if you could ‘armor’ the car with a few paint buckets worth of tainted meat/Z-pheromones to keep Zeds from scent tracking you.

Or if you could craft an anti-robot disruption turret out of direction EMP cbms and a few radios.

[quote=“Logrin, post:87, topic:7616”]What about a straight up acid gun? Just a big fire-hose that squirts acid?

Or a turret that burns tainted meat to conceal your car in a hazy cloud of poison smoke?

Probably impossible but would be neat if you could ‘armor’ the car with a few paint buckets worth of tainted meat/Z-pheromones to keep Zeds from scent tracking you.

Or if you could craft an anti-robot disruption turret out of direction EMP cbms and a few radios.[/quote]

If Blaze solves the problem with getting turrets to take liquids, there’s a pumper-truck PR that needs some love.

[quote=“Logrin, post:87, topic:7616”]What about a straight up acid gun? Just a big fire-hose that squirts acid?

Or a turret that burns tainted meat to conceal your car in a hazy cloud of poison smoke?

Probably impossible but would be neat if you could ‘armor’ the car with a few paint buckets worth of tainted meat/Z-pheromones to keep Zeds from scent tracking you.

Or if you could craft an anti-robot disruption turret out of direction EMP cbms and a few radios.[/quote]
First one is not possible as a json yet, but if my PR merges, it will be possible to feed a turret from any kind of fuel tank (fuel tanks aren’t limited to fuels, plutonium reactor is also a fuel tank) that contains ammo-type items. Fuel tanks are easy to add as a json.
My PR is here: https://github.com/CleverRaven/Cataclysm-DDA/pull/10532 and it’s much bigger than just allowing liquid shooting turrets. I noticed that liquid shooting turrets are very easy to implement (more like “enable” than “implement” actually), so I added it.
One thing it lacks is checking the level of liquids that aren’t hardcoded in veh_interact.

All others aren’t doable and won’t be doable anytime soon with jsons alone. The EMP turret would be rather easy to code, though. Just a special on-hit effect.

Even before throwing the idea in here, I’m suspecting that it’s way more coding needed to make it possible.
My thought was to give the vehicle turrets a customizable fire angle by forcing line of sight on them and similarly installing them like how a headlight is installed.
That would force them to select targets within the alloted angle and it would be possible to make them unable to shoot the car they are installed on.

[quote=“Ivefan, post:90, topic:7616”]Even before throwing the idea in here, I’m suspecting that it’s way more coding needed to make it possible.
My thought was to give the vehicle turrets a customizable fire angle by forcing line of sight on them and similarly installing them like how a headlight is installed.
That would force them to select targets within the alloted angle and it would be possible to make them unable to shoot the car they are installed on.[/quote]

They can’t shoot the car they’re on, at least not with weapons that have no AoE. Try it with a debug char - they will deal no damage to own vehicle.
Angle-restricted turrets would be easy and it’s one of the few things I want to implement once the PR in my earlier posts gets in. The other things would be manual turret aiming (with a tag for turrets that can be only fired manually) and limiting burst size for the turrets.

Looks like the new turret control commit just popped in, I’ll have to do a pretty significant rewrite.

The turret control affects 3 things:

  • Enables limiting turrets to 1 shot rather than burst
  • Enables per-turret on/off/burst
  • Fixes energy, plasma and gasoline turret fuel usage (you set it with weapon tags rather than it being hardcoded)
  • Enables generic fuel tanks to be used by turret

The last means that you can make an acid turret or even water turret, though it will still need an ammo type for it, so the “turret water” would have to be a different object from “real water”.

Generic fuel tanks aren’t yet finished because you can only view their contents by sawing them off and because of the above (the ammo requirement), but it’s already workable.

probably an idiot question but i have to ask this:

Is it possible to code some turret to have a manual targeting system?
Today they are all automatic, it could be nice to have some which can be controled, be able to choose target etc …
It could be really nice to choose a wall or some things to shoot with slingshot, or an area to burn with burning ammo …

It is possible, but it will require code, not just moding.
I’ll write something like this soon, but first I need to figure out a good way to store turret’s state to prevent manual firing from allowing extra shoots.

Blaze created a bunch of turrets that require manual reload, so I guess those are supposed to be fired manually too. I’ll add a tag for turrets that will allow creating manual-only turrets that won’t aim by themselves.

…Blaze created a bunch of turrets that require manual reload, so I guess those are supposed to be fired manually too…[/quote]

No, it’s why i ask this question;

I play with a fortress-mobile style, i used 8 laser turret in this way, it’s really efficient in defense, but i would have turret with AoE to managed, as i say before, to target precise Z or élément.
In this way i tried slingshot, which is a manual-reload turret, but it shoot automaticaly the nearest ennemy and it’s impossible to shoot something precise. finally we can only work on when it shoot, not who or where…

all my apologize for this english whish could be really ugly :confused:

My attempt at coding aim-able turrets ended in failure unfortunately.

I could make it so that you could use those single-shot turrets like larger crossbows, but it’d be far more difficult to balance. Giving them the mounted tag would make them require some nearby support, but the damage is HUGE compared to similar weapons; I’d have to make the recoil nearly take your shoulder off or something.

In any case, I’m thinking of making the following changes:

  • Turrets will be easier to make and install.
  • Turrets will have significantly smaller ammo capacity (for those that use ammo).
  • You’ll need to craft and then install an “auto-loader” for specific ammo types.
  • Autoloaders contain ammo which then feeds all the turrets using that ammo.
  • Autoloaders can take up either a fuel source or center spot on a vehicle tile.
  • You can install multiple autoloaders to hold more ammo.
  • Autoloaders can be filled the same way you pour gas into a car.
  • This may not affect all turrets.

Does anyone have any suggestions to add to this?

[quote=“Blaze, post:97, topic:7616”]My attempt at coding aim-able turrets ended in failure unfortunately.

  • You can install multiple autoloaders to hold more ammo.
  • Autoloaders can be filled the same way you pour gas into a car.[/quote]

My attempt didn’t. It didn’t got merged yet, but I think it’s relatively solid.
If it gets merged, turrets with “MANUAL” tag will not acquire targets by themselves.
It will be a new menu in the vehicle. It goes like this: vehicle controls->manual aim->turret->(uses aiming menu like shooting)pick target->wastes some time->turret shoots the target (or doesn’t, if it can’t).

About autoloaders: if you implemented them using current code, they wouldn’t be very satisfying to use or even mod. You’d have to make them fuel tanks and fuel tanks only accept and dispense the default ammo type from a given category (for example, autoloader for 9mm would only accept plain 9mm, not 9mm +P).

If you think you can code them, it may be worth a try. If you can’t code them, I may implement them later on.
My idea of autoloader is as follows: a part with cargo that by itself does nothing, but some parts can get items from their cargo as if they were in own cargo. Possibly with a limitation that only the first item (on the stack in loader’s cargo) is viewed or that only nearby autoloaders are used.

Hasn’t been merged because you’re self-conflicting IIRC and BevapDin isn’t thrilled with some of your code. :-/

I sent one PR as a “queue for merging” PR (the manual fire one), and one just for review because it conflicts the other one.

If one of them gets in, I’ll quickly clean up the other one and make it mergeable.

I see no criticism under my manual turret aiming PR. If there’s something wrong with it, I’d like to know.