View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0004209||The Dark Mod||Feature proposal||public||02.09.2015 16:17||15.02.2017 04:38|
|Summary||0004209: Add _SOURCE as an available entity for response effect scripts|
|Description||Suppose I want to write e.g. a response effect Look At, to make AI look at an entity when stimmed. An obvious use case is to have them look at the entity that stimmed them. However, the effect script would have to treat that as a special case because getTargetEntity(string targetEntityStr, entity self) doesn't test for it. I suggest adding _SOURCE as a complement to _SELF and changing getTargetEntity(string targetEntityStr, entity self) to getTargetEntity(string targetEntityStr, entity self, entity source).|
|Additional Information||A revised tdm_response_effects.script is attached. If any published mission has ever included a custom response effect script then a compatibility fix would be required.|
_SOURCE won't appear in the S/R editor's menus without a change to DR.
|Tags||No tags attached.|
tdm_response_effectsUPDATED.script (31,825 bytes)
|Uploaded an updated .script after seeing http://forums.thedarkmod.com/topic/11058-things-that-could-be-improved/?p=376629|
No published maps have included a custom tdm_response_effects.script, or have overridden getTargetEntity(), if that's the potential compatibility problem.
Trying to get my head around this. I'm not very familiar with the S/R system. Does _SELF mean that the entity that receives the stim is target of the response effect? And a named entity will make that the target of the response effect. So _SOURCE would make the stimming entity the parameter of the effect.
Sounds like a useful option.
Yes, that's right. For example, AI tend to inherit a damage response which tells them to react to STIM_DAMAGE by taking some damage. _SELF is used to do that.
(I wish I understood S/R better myself, then I could offer to improve its documentation. Some of the built-in stim types leave me wondering whether they're even used anywhere or just reserved for possible future use.)
|02.09.2015 16:17||VanishedOne||New Issue|
|02.09.2015 16:17||VanishedOne||File Added: tdm_response_effects.script|
|02.09.2015 17:15||VanishedOne||File Added: tdm_response_effectsUPDATED.script|
|02.09.2015 17:15||VanishedOne||Note Added: 0007752|
|06.09.2015 13:22||SteveL||Note Added: 0007753|
|06.09.2015 13:46||VanishedOne||Note Added: 0007755|
|03.10.2015 13:28||SteveL||File Deleted: tdm_response_effects.script|
|08.10.2015 21:45||SteveL||Assigned To||=> SteveL|
|08.10.2015 21:45||SteveL||Status||new => assigned|
||Assigned To||SteveL =>|
||Status||assigned => new|