Please give me a comment telling me what you think.
Also, don't forget to give me tutorial requests!
Learn how to use the info_node entity to enable NPCs on your maps to navigate properly.
Posted by Silverfisk on - Intermediate Mapping/Technical
Thanks for the tutorial, it great!
Very interesting although I would love to have had a simple explanation on how the entire AI system works with nodes. You've explained how to do it but not how it works which I feel is the most important part. Although I can gather that some how Source builds the node graph using it's own algorithms and then when an NPC is supposed to move to a node destination it uses the node graph to pick which nodes to use to travel.
(I did not mean to reply to the freaking dog guy. I hate that dog it always stares me in the face like a ******* freak as if it wishes to take my very soul)
Lol, yeah, Gino tends to do that when he wants food. I also noticed that I didn't put an S at the word "it"...
Thanks NullSoldier!
I felt that the part I had most problems with myself when learning this was how to actually place the nodes.
The AI works with the nodes like this:
1. Get a destination.
2. Find the closest node to self and destination.
3. Calculate path between destination and closest node.
4. Go the path.
* It avoids collision with dynamic (physics for example) objects by doing colission test in front of itself all the time, if an object is in the way it will try to go around it.
Is that what you wanted to know?
Thank you Croco!
@Silverfisk
Good Tutorial good Voice.
If you like you can use the information given below.
@NullSoldier - LOL, it's just a little dog!
The AI-Nodes are connected when the map is loaded for the first time or when the nodes have changed. Connected means that each node is targeting each other and so on as long as they are in valid range of 249 units.
When the AI is placed outside of the connected node field the AI should be able to get to the target-destination or closest node if there are no blocking objects.
Nodes which are not connected will not work!
The AI does not follow the nodes strictly unless it is instructed to, it uses the shortest path between the connected nodes and avoids objects which are in the way by orientating on the nearest node leading to the target destination.
30 unites distance(or slightly more) from each object is ideal, because the Bounding-box of the AI is used for collision detection(with walls and other entities) and if the floor is not exactly plain, as for example if there are stairs, the AI should be able to use stairs which are under 32 units in height.
This is how it works in ef2, I'm pretty sure it's the same with hl2, maybe the nodes distance has changed, but the rest shouldn't have.
Thanks man!
Doesn't look like you had much use of it though. ;D
Nice explaining!
Well, I did I learned that the nodes get drooped to the floor, that never occurred to me before. :)
thx also from moddb
Very nice tutorial
You might also want to create a tutorial that shows people how they can place and move props in game then have it save it in hammer
Thanks!
That's for another tutorial though, this one was just about navigation.
Dont forget to say, that autosaving has to be off for that to work!! :D
Oh, and maybe I can just tell you my request here: I'd like to get flying npcs to work, but I dont know how...
That's a good point.
Thank you for the request also!
excellent.
I also have a request - couldn't figure out how custom animations for custom NPCs can be implemented in the game (for a better description please follow this link: halflife2.net/forums/showthread.php?t=168469). I really don't need a tutorial for this problem but couldn't find anything about it on the net, so if you'aware of the problem I'd appreciate even a simple text explanation :)
Thanx!