Are you a Level Designer? Are you looking for help/support or other level designers? Then this is the group for you! Doesn't matter what you map for, if your a beginner or a professional this is the group for you.
After reading this tutorial, you will know how can have NPCs searching the player in the whole map ! You can apply as well as for zombies as combines.
Posted by Bioko on Nov 18th, 2010
In this tutorial, we will see how we can make that an NPC, once he spawns, search the player via an aiscripted_schedule. This method can be useful if you want to make a "survival" map, where for instance, the zombies must search by themselves the player who is hiding in a town or a forest. What is cool here is that you don't have to create a complex path where the NPCs will patrol and spend time scripting the whole shit... No here the NPC will search the player wherever he is ! You will also learn how to use the entity called aiscripted_schedule.
So first, you will need to create a template NPC who will be spawned on the map and who will search the player. It can be a combine, a zombie, a vortigaunts, a rebel... It is very important that once you placed your npc, you convert it to a template NPC (take a tour to the "Flags" tab) and that you give to him a name (I will use NPC_Seeker here) ! Or else, it won't work !
Create somewhere in a map an entity called aiscripted_schedule and name it (I will name it AISchedule_Seeker). You must also enter in the field called "Target NPC" the name of your template NPC (since mine is named NPC_Seeker, I will write NPC_Seeker).
Then be sure that the rest of the fields are like those above :
The last thing to do is to be sure that in the flags, the case "Repeatable" is checked and the other don't.
Okay so now we have an aiscripted_schedule who will order the Template NPC to search the player ! But there is still something who is missing... You don't have any idea ? Well, how are we going to spawn an npc if there is no any npc_template_maker on the map ? The answer ; Create a npc_template_maker !
So now let's stop joking and finish the job we started here. Create somewhere a npc_template_maker this is where the NPC will spawn) and write the name of your Template NPC in the field "Name of the Template NPC" (I may write NPC_Seeker). You can also configure the other options who fit you the best. When you have done, go to the Output Tab and add a new output with these parameters :
Once you finish that, then congratulation ! You may now have NPCs searching you in the whole map ! If you want to see what does it looks like in-game, I use this method in a map of Alien Wave called "Frozen Hell". You can download this mod at my website (section "Mods)". Anyway, I hope this tutorial would have been helpful for the community of Source mappers !
SOURCE : Biokoxomodding.tk