From db7414e822ccfdbb1daa3b2e134b02aa4c86a194 Mon Sep 17 00:00:00 2001 From: abcdefg30 Date: Mon, 7 Jan 2019 13:02:53 +0100 Subject: [PATCH] Include a note about the necessity of AnnounceOnSeen for OnDiscovered --- OpenRA.Mods.Common/Scripting/Global/TriggerGlobal.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OpenRA.Mods.Common/Scripting/Global/TriggerGlobal.cs b/OpenRA.Mods.Common/Scripting/Global/TriggerGlobal.cs index 98c783a2ee..983c7a6108 100644 --- a/OpenRA.Mods.Common/Scripting/Global/TriggerGlobal.cs +++ b/OpenRA.Mods.Common/Scripting/Global/TriggerGlobal.cs @@ -442,7 +442,7 @@ namespace OpenRA.Mods.Common.Scripting [Desc("Call a function when this actor is discovered by an enemy or a player with a Neutral stance. " + "The callback function will be called as func(Actor discovered, Player discoverer). " + - "The player actor needs the 'EnemyWatcher' trait.")] + "The player actor needs the 'EnemyWatcher' trait. The actors to discover need the 'AnnounceOnSeen' trait.")] public void OnDiscovered(Actor a, LuaFunction func) { GetScriptTriggers(a).RegisterCallback(Trigger.OnDiscovered, func, Context); @@ -450,7 +450,7 @@ namespace OpenRA.Mods.Common.Scripting [Desc("Call a function when this player is discovered by an enemy or neutral player. " + "The callback function will be called as func(Player discovered, Player discoverer, Actor discoveredActor)." + - "The player actor needs the 'EnemyWatcher' trait.")] + "The player actor needs the 'EnemyWatcher' trait. The actors to discover need the 'AnnounceOnSeen' trait.")] public void OnPlayerDiscovered(Player discovered, LuaFunction func) { GetScriptTriggers(discovered.PlayerActor).RegisterCallback(Trigger.OnPlayerDiscovered, func, Context);