Lol, I just copied and pasted your code for that part really. I didn't even check if it was correct.
But then, I assumed a crashing error, meaning it at least compiled, so your datatypes were at least right. That and your variable names seemed to imply the data type.
At any rate, now that I'm checking, the SDK has this to say:
// Special Target Trigger/Data
OP2 Trigger __fastcall CreateSpecialTarget(int bEnabled, int bOneShot, Unit& targetUnit /* Lab */, map_id sourceUnitType /* mapScout */, const char* triggerFunction);
OP2 void __fastcall GetSpecialTargetData(Trigger& specialTargetTrigger, Unit& sourceUnit /* Scout */);
Btw, it makes no sense to assume the trigger callback knows what trigger caused it to fire, since there are no parameters (or "this" pointer) telling what trigger object caused the trigger callback to fire. In fact, you can have more than one trigger, possibly of completely different types, that all call the same trigger callback when they fire. There is no real way to distinguish what trigger caused it to fire in that case. The best you can do, is check each trigger to see if it fired, but that's still ambiguous if two of them fire at the same tick.
I've kind of found that to be an annoying limitation of the trigger system in Outpost 2. I think the trigger callbacks would have been better if they were defined along the lines of:
Export void TriggerCallbackFunction(Trigger& trigger) { /* ... */ }
Or perhaps passed some kind of generic context value, which might very well have been cast to a Trigger reference, or used to build one from an id/index value. Or perhaps just used raw as your own index of some sort. But then, you'd also have to modify each trigger creation function to add a context parameter or add a method to the trigger class to set the context value.