diovbc Posted February 5, 2017 Share Posted February 5, 2017 How could i code my character to be always prioritized by hounds when near one? I mean, if it enters the hounds 'FOV', the hound will switch target to this character, and attack that character until it dies. Link to comment Share on other sites More sharing options...
R1ncewind Posted February 6, 2017 Share Posted February 6, 2017 as i remember hounds code, they targeting player by default( are we talking about hounds from event?), but if hound get attacked by anything else he broadcasting such information in some radius and other able to target new threat. short answer - it's all about brains (which you don't need to change in your case) and about functions for combat component. Take a look for (i didn't code for a while, but can show direction which might help) OnAttacked() or OnGetAttacked() in combat component. There also OnAttack(). You can set up your custom functions for hounds prefab to force them not change target if they targeting player. Link to comment Share on other sites More sharing options...
diovbc Posted February 12, 2017 Author Share Posted February 12, 2017 Nice. But how could i change that and implement into the game? I mean, i should create a new hound brain component and implement into the game through my character.lua? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.