Open MonkeyFrogStudio opened 1 year ago
This is easy enough to do. It would be nice to have a default control script for it.
I am no programmer or scripter, so I am pretty sure I don't really know what I'm talking about. So, please take that with a grain of salt. I'm not talking about a script for simple flying things. I'm talking about AI using nav mesh (or a modified version of it) to intelligently hunt you through the air. Enemy NPCs on the ground can use the nav mesh to find a path to the player, avoiding obstacles, like walls, etc. Flying things, like drones, etc., would need to be able to plot a path, too, but should be able to think three-dimensionally so they can go over walls of a certain height instead of going around them like a ground-based NPC would. So, in my simple mind, there would need to be some kind of "extension" to the nav mesh system so a flying NPC could track a player and navigate to them, going over walls, etc., when able. They would also need to know that a "roof" (or whatever cover) is there so they don't attempt to go over a wall only to encounter a roof. In such a case, the AI would possibly choose an open door or window to go through.
So, to me, this seems like a bit more than a simple lua script. I mean, I know that the NPC's behaviors use lua scripts, but this seems like a bit more due to the 3D nature of it and the kinds of decisions a flying enemy NPC object would have to make in an attempt to hunt down the player (and any friendly NPCs).
How funny you made this request when I was just thinking of this earlier today, lol!
I had made an attempt of a "flying" enemy in Classic some years ago, trying to replicate the behavior of the sentinels from Halo CE as a reference point. I never got beyond making an entity float, and move towards a specified point in 3D space, since there were many problems with manipulating entities and a ton of bugs that arose, so I quickly canned the project.
The closest we've seen to a "flying" enemy in GG is AmenMoses's helicopters for Classic, but imo they're very underwhelming as actual enemies, since they slowly take off, slowly fly out to an extreme distance, and then slowly fly over in a "bombing run", only shooting at the player at a very mid-point of their run, and then they keep flying off into the distance to then circle around for another run. It left them with very predictable movement and long downtimes of just doing, nothing, that made it extremely easy to shoot them down.
I'd love to see another attempt at a "flying" enemy in GGC/GGM, one that behaves more akin to a traditional flying enemy in a game, like the aforementioned sentinels from Halo, the Apache from HL1, or the combine gunship from HL2.
However, for something more like a drone that just hovers barely above the ground, and behaves more like a soldier that happens to be able to scale tall ledges, I think that can be done with a bit of .Lua trickery, though it'd only work in situations where the drone has a clear line-of-sight to the player; otherwise some kind of "jump link" for pathfinding would be necessary (some kind of "link" generated between two navmesh areas of varying height that allows a valid path to be drawn "through" it) , then you could just specify how high a given NPC is allowed to "jump" (effectively how tall the "jump link" is allowed to be for a valid path to still be drawn through it), with the drone having a very high jump value.
This is easy enough to do.
Really? Please do tell.
The closest we've seen to a "flying" enemy in GG is AmenMoses's helicopters for Classic, but imo they're very underwhelming as actual enemies, since they slowly take off, slowly fly out to an extreme distance, and then slowly fly over in a "bombing run", only shooting at the player at a very mid-point of their run, and then they keep flying off into the distance to then circle around for another run. It left them with very predictable movement and long downtimes of just doing, nothing, that made it extremely easy to shoot them down.
So they behave like helicopters iow.
Flying enemies are really really hard to do, and not just because they have to move in 3 dimensions rather than 2. Probably the hardest part is in avoiding other objects and each other.
I could make a HL like attack drone, but I'm not sure MAX is up to the job performance wise. Feel free to send me a model and I'll see what I can do.
This is easy enough to do.
Really? Please do tell.
Well, making an entity fly is not a difficult task. Adding the ability fo find an open window on an upper floor is also not super difficult. There are a few ways I can think to do this. How I would do it personally, would be to create an invisible and non-blocking entity that gets placed over the open window that the entities use as a beacon. Or you could just use a named marker. Once the window is found and entered, pathing can commence as normal.
Did I create this request so some could debate? Or did I create this request so that possibly TGC might consider it as an option to add to MAX along with their current nav mesh system?
Did I create this request so some could debate? Or did I create this request so that possibly TGC might consider it as an option to add to MAX along with their current nav mesh system?
Well debate may very well prompt TGC to enhance the nav-mesh system so win-win.
I'd like to see things implemented in MAX to accommodate flying enemies - drones, dragons, soldiers with jet packs, etc.
Current AI relies in the nav mesh, which will be cut off by a wall, etc. However, if a wall is only 10' high, while an enemy soldier might not be able to get over it, a flying drone would. So, it seems that something would have to be added to MAX to accommodate flying enemies.
Normal walking/running enemies would have to go around an obstacle, but a flying enemy could go over it. This would add another level to the AI and increase the kinds of enemies would could employ in MAX.