Project
TargetSpy
Is your feature request related to a problem? Please describe.
Right now there is no easy way to simply replace one of the four special class types.
Describe the solution you'd like
Since they're actors, they're subject to CheckReplacement (near the bottom), which is called whenever GetReplacement is called.
Here's what I suggest...
- The mod will set up as normal and initialize everything, and then it will call
GetReplacement().
- If the replacement has a suitable function to it, it'll simply use that actor's functions instead and is affected by the CVar associated with the original, so people don't have to fiddle around with disabling/enabling as much on a per-mod basis.
- Name tags that match the replacement's name will be used if found in LANGUAGE, otherwise it sticks to the original.
If this is doable, it'll solve all my problems. Modders would only need to set up replacements on their end via event handlers.
This example will be perfect because it's not mod dependent thanks to Names.
class EV : StaticEventHandler
{
override void CheckReplacement(ReplaceEvent e)
{
Name rpe = e.Replacee.GetClassName();
Switch (rpe)
{
Case 'tsGetter_Health':
e.Replacement = 'tsGetter_SLN_Health'; break;
Case 'tsGetter_HealthBar':
e.Replacement = 'tsGetter_SLN_HealthBar'; break;
}
}
}
Project
TargetSpy
Is your feature request related to a problem? Please describe.
Right now there is no easy way to simply replace one of the four special class types.
Describe the solution you'd like
Since they're actors, they're subject to CheckReplacement (near the bottom), which is called whenever GetReplacement is called.
Here's what I suggest...
GetReplacement().If this is doable, it'll solve all my problems. Modders would only need to set up replacements on their end via event handlers.
This example will be perfect because it's not mod dependent thanks to Names.