Basically, tank drones are tanks. However, they’re 1 tile large. Cars are…many? Many tiles large.
Are we someday going to have to-scale hostile vehicle units like tank drones and cop car drones?
Basically, tank drones are tanks. However, they’re 1 tile large. Cars are…many? Many tiles large.
Are we someday going to have to-scale hostile vehicle units like tank drones and cop car drones?
That would be amazing, or amazingly deadly. Probably the latter. But yeah, you see a lot of automated street cleaners, but they don’t seem to be very automated at the moment. In that I mean that they just sit there, dead. It would be cool to see them roaming the streets sweepig up rubble and dead zombies or something like that.
If there was someone out there willing to take on the monstrous task of programming an AI capable of controlling a multi-tile body, and then getting it to actually drive as if it were on four wheels, or treads, or whatever, then this would be possible and make a very, very nice addition to the game as a whole.
That would all be pretty awesome. Hell, with such an AI, you could probably implement autonomous driving for survivors and bandits. Minefields and military checkpoints on roads would become a lot messier. =D
High speed chases while dodging wrecks, roadblocks, and walls of the living dead? Hell yeah! And I wonder if the targeying system from Mad Max could be implemented, where you could disable vehicles (or make them crash into each other! orgasmic breathing). Or maybe even spike strips or vehicle traps! And Spartan-like comandeering!
Too bad the game’s a bit of a mess right now to really do that, huh?
Pretty sure you can already target specific tiles of a vehicle with guns damaging the parts in that tile. There just isn’t much point to atm.
I’ve always thought it was weird, having tank boys that were only a tile big.
This seems like a decent idea, I can see it as an automated moving vehicle with “turrets” strapped on.
ai driven real vehicles would be one of the most amazing things cata:dda could add imo, then once you’ve built a deathmachine, you can give it a brain, or instead of taking apart street sweepers, you can turn them into your own personal loot-locusts.
As a rough guess, I’d say it’s going to be a far future thing. From what I know in regards to AI pathfinding (in terms of other roguelike games) having a single tile monster navigate things is pretty simple. Having a multi-tile creature do the same is not.
Would be cool though.
I wonder if they could implement it in a way that every tile was a single creature.
If this were to actually be implemented at some point I’d imagine seeing a lot of collapsed buildings at the beginning of the programing from the AI just trying to ram through them, which is amusing to me.
That was my exact thought. And there’d certainly be something both funny and terrifying about having a nine tile tank plow through half a city to get at you.
I don’t really know how Cata pathfinding is programmed (I’d assume some kind of fairly simple A* variation), but if you don’t mind that happening, it likely wouldn’t be super difficult to implement. Course, you might end up with a bunch of multi-tile things stuck on doorways if they can’t plow through. Either way, it would be a funny mess.
The problem isn’t really multi-tile part, it’s rotations and velocity.
Shoving a big square brick around would only require stretching every obstacle and treating the vehicle as a single tile.
With rotations and velocity, the pathfinding not only has to find a path - it has to find a list of actions the vehicle has to perform to get there.
For example, in normal pathfinding, your actions can be described as “go north, go north-west, go north”. In vehicle pathfinding, they are “turn 30 degrees left, accelerate 10 km/h, wait (just keep old velocity and facing), turn 30 degrees right”.
Here’s a similar problem solved by Factorio devs: https://www.factorio.com/blog/post/fff-113
In our case we’d also have velocity to take care of, meaning another dimension (literally dimension - rotations are treated as dimensions on pathfinding graph) to take care of.
@ factorio page
That’s rather interesting, thanks for sharing.
And that’s quite a bit more complex than I’d assumed it to be (though my game programming knowledge is admittedly limited to having done a couple very simple RLs in Python). I had no idea how vehicle pathfinding works in Cata. I assumed the components of a vehicle would be treated as seperate objects following one set of instructions (I hadn’t considered velocity either), not as a single one. If I understand right, that’s not the case.
but for what?
is not need to create “new unneeded kindnesses”.
any car can paint himself on the map, yes? yes! and all what you need is to teach zombie to drive the car.
i think you need new flag “car-driver” - so zombie and other monsters (critters is not a “monsters”) can not to drive… or can. and you will have a real CARmageddon because there is no save from big trucks in the houses because zombie not have “self-save sence”
under zombie i mean the AI which may be friendly and may be not.
because is what is NPC? NPC is AI-driven monster. from here we have what player-character is a “player-driven monster”
is the NPC have inventory? yes
can NPC use their inventory items? yes.
can zombie use items? hmm i think yes.
and - is the zombie is driven by the NPC-AI-subroutine or for the zombie is zombue-AI-subroutine?
but this question is - i think - need to write to developers.
At first one would think vehicle pathfinding wouldn’t be all that hard if they were simply restricted to roads, but then you realize there’s usually derelicts along them, and they would have to be maneuvered around. And then there’s large open spaces that should be accessible to AI vehicles, but they need precise maneuvering as well if you don’t want them to run into most rocks along the way.
So it seems like a pretty damn tricky scenario overall. It would be nice to have, sure, but it appears to be an immensely difficult thing to implement.
Pathfinding for vehicles could be monstrously difficult - especially because their width is variable, not just from car to car, but also when turning (because you can rotate the corners into things). This change of aspect ratio would give any attempt at A* complete fits.
If you wanted to use A* without serious modification, you’d have to treat any vehicle as being as wide as its longest axis regardless of how it is rotated. Basically even a bicycle would be treated as if it were a 3x3 wide car, in order to deal with its rotation, while a 3x3 car is (I think) treated as a 4x4 object in order to deal with all its width permutations as it turns, and so on. An RV would have trouble seeing its way down a wide open road, because its width would be treated as its maximum diagonal length, which is enormous.
Oh, and this is ignoring the concept of turning radius, which is another thing that most pathing algorithms cannot easily incorporate. Altogether the pathing for cars alone could easily make for a major implementation project - usually that sort of effort is restricted to big budget games like GTA or Halo.
These restrictions would be so great that A* would pretty much choke for anything but small vehicles on clear open roads, which means you’d have to find a bunch of clever ways to make A* smarter - which will usually make it slower, and greatly increase the implementation complexity, and could put a serious drain on constraints like working memory.
Altogether it’d be a very interesting project for a more talented programmer than me to prove their badassitude on.
[quote=“Coolthulhu, post:13, topic:13041”]The problem isn’t really multi-tile part, it’s rotations and velocity.
Shoving a big square brick around would only require stretching every obstacle and treating the vehicle as a single tile.
With rotations and velocity, the pathfinding not only has to find a path - it has to find a list of actions the vehicle has to perform to get there.
For example, in normal pathfinding, your actions can be described as “go north, go north-west, go north”. In vehicle pathfinding, they are “turn 30 degrees left, accelerate 10 km/h, wait (just keep old velocity and facing), turn 30 degrees right”.
Here’s a similar problem solved by Factorio devs: https://www.factorio.com/blog/post/fff-113
In our case we’d also have velocity to take care of, meaning another dimension (literally dimension - rotations are treated as dimensions on pathfinding graph) to take care of.[/quote]
maybe simplifying the speed an ai would try to drive a vehicle at could help?
say no matter the vehicle and it’s capabilities an ai would only try to drive it at 20km/h or some other standardized speed.
If anyone’s brave enough to tackle the problem, I’d recommend making “multi tile monsters that drop vehicle parts on death” instead of trying to make a monster that understand how to drive. I’ve always thought that chickenwalkers would make more sense as a 2x2 size monster - you could even get around most pathfinding issues by letting it step over (or plow through if aggroed) vehicles/trees etc.
For that matter, just a framework for a multi tile monster period would be fun for adding bosses and whatnot. I remember the worms in NetHack were simply a “head” with body segments trailing behind it - the pathfinding with that approach is quite simple. A monster “head” that summons tentacles / floating limbs / ground spikes could also be quite scenic (and potentially quite dangerous). Back on subject with vehicles, though, a multitile robot with individual segments (missile launcher, treads, etc) that could be targeted would be a fun albeit difficult project.