I'm trying to find the target entity of a trigger_teleport (the info_teleport_destination or info_target which players are teleported to). I searched around and found out the entity property for trigger_teleport targets is "m_target" so I set this up:
PHP Code:
public Event_RoundStart(Handle:event, const String:name[], bool:dontBroadcast)
{
HookEntityOutput("trigger_teleport", "OnStartTouch", Output_TeleStartTouch);
}
public Event_RoundEnd(Handle:event, const String:name[], bool:dontBroadcast)
{
UnhookEntityOutput("trigger_teleport", "OnStartTouch", Output_TeleStartTouch);
}
public Output_TeleStartTouch(const String:output[], caller, activator, Float:delay)
{
decl String:teleTarget[32];
GetEntPropString(caller, Prop_Data, "m_target", teleTarget, sizeof(teleTarget));
PrintToChatAll("Teleport target: %s", teleTarget);
}
This gives me the error:
Code:
L 03/22/2015 - 19:55:47: [SM] Native "GetEntPropString" reported: Property "m_target" not found (entity 121/trigger_teleport)
L 03/22/2015 - 19:55:47: [SM] Displaying call stack trace for plugin "combatsurf.smx":
L 03/22/2015 - 19:55:47: [SM] [0] Line 106, C:\workspace-sourcemod\addons\sourcemod\scripting\combatsurf.sp::Output_TeleStartTouch()
I guess m_target isn't supported in GO. Has anyone worked with trigger_teleports in CS:GO and has a solution?
Thanks