Difference between revisions of "Talk:GetCombatTarget"

227 bytes added ,  00:17, 5 October 2008
imported>Antares
(Possible Solution (this instance) for combat targets and the player.)
imported>Shademe
Line 6: Line 6:
:Right now the only thing I can think of would be to indirectly script the player (as directly scripting the player is messy business). Let me elaborate, you could possibly add a scripted ability to the player that retrieves any NPC's within a certain proximity as references. Once that has been done you can check their combat targets then process the appropriate code. You probably won't want to be running the script every frame of gamemode so you could see this article [[Making a GameMode script run at second intervals | here]]. I believe you may also find [[Casting Spells From An Activator | this]] article to be helpful. Hope it all goes well for you.
:Right now the only thing I can think of would be to indirectly script the player (as directly scripting the player is messy business). Let me elaborate, you could possibly add a scripted ability to the player that retrieves any NPC's within a certain proximity as references. Once that has been done you can check their combat targets then process the appropriate code. You probably won't want to be running the script every frame of gamemode so you could see this article [[Making a GameMode script run at second intervals | here]]. I believe you may also find [[Casting Spells From An Activator | this]] article to be helpful. Hope it all goes well for you.
:[[User:Antares|Antares]] 00:09, 5 October 2008 (EDT)
:[[User:Antares|Antares]] 00:09, 5 October 2008 (EDT)
::That was my first thought as well :o but walking through nearby references requires OBSE or a rather long spell of scripts to work - Both of which I'm trying to avoid. -- [[User:Shademe|shademe]] 01:17, 5 October 2008 (EDT)
Anonymous user