[ News | About | Media | Downloads | Tutorials | Contact ]

Tutorials

Back to Tutorials

hlss_recharge_point

Even though the name gives the impression that it's only for recharging generators, it can be used to multiple of different kind of tasks. hlss_recharge_point is useful for having NPCs run tasks such as recharging generators or turning on thumpers while still fighting enemies when they try to get into the position to perform said task. It also allows to use all the civil protection characters (NPC controlled Noah, Larson, Eloise or Anders when there is no four players) as the possible Actor instead of having to have seperate schedule for each character.

Note that the recharge behavior is only enabled on the four Civil Protection characters and Alyx.

You can also make the NPC to get himself AR2 AltFire ammo before he can use the generator by checking the spawn flag and defining the Ammo Crate.

Values

Spawn Flags:
  • Start Active
  • Don't speak TLK_CP_RECHARGING. (Note: only Larson currently has the line recorded)
  • Need AR2 AltFire ammo to use
Max Distance to look for NPCs
How far away can our Actor be to allow him to start using the behavior.

Sequence name
Name of the sequence to play when the NPC is doing his task. To see different animations you can open Model Viewer from Source SDK and then opening the model of the character the recharge point is meant for. You can browse the different sequences with the drop down menu in the Sequence section.

Actor
The targetname or classname of the NPC to use this recharge point. If you want to use the four civil protection characters, you can leave this empty and select the "Unique Metrocops" from the Search Type.

Search Type
Three choices: "Entity name", "Classname", or "Unique Metrocops", where the last option makes the recharge point select the closest AI controlled Civil Protection character to do the task.

Ammo Crate
If the the spawn flag is checked, this is the name of the item_ammo_crate where the NPC needs to run if he's out of AR2 Alt Fire ammo. He can, just like players, carry three AR2 AltFire ammo at max. If the recharge point needs ammo, it prefers NPCs with AR2 Alt Fire ammo more than NPCs that don't already have any.

Input functions

Activate
Start looking for NPCs to perform the task

Deactivate
Stop looking for NPCs to perform the task and cancel the task if one is already doing it

Output functions

OnRecharge
When the NPC has finished his sequence.

Back to Tutorials

[ News | About | Media | Downloads | Tutorials | Contact ]



Valve, the Valve logo, Half-Life, the Half-Life logo, the Lambda logo, Steam, the Steam logo, Source, and the Source logo are trademarks and/or registered trademarks of Valve Software. All information is copyright their respective authors. Website designed by some guy I know.