LuaGears: Special IsHogLocal behaviour
authorWuzzy
Tue, 08 Oct 2019 17:10:51 +0100
changeset 1986 399ccb203f0d
parent 1985 39daa8abac0b
child 1987 d1f476f458e8
LuaGears: Special IsHogLocal behaviour
LuaGears.wiki
--- a/LuaGears.wiki	Tue Oct 08 17:06:52 2019 +0100
+++ b/LuaGears.wiki	Tue Oct 08 17:10:51 2019 +0100
@@ -592,7 +592,11 @@
      RestoreHog(gear) -- Restore the newly hidden gear.</code>
 
 === `IsHogLocal(gearUid)` (0.9.23) ===
-Returns `true` if the specified hedgehog gear is controlled by a human player on the computer on which Hedgewars runs on (i.e. not over a computer over the network). Also returns `true` if the hog is a member of any of the local clans. Returns `false` otherwise. Returns `nil` if `gearUid` is invalid.
+Returns `true` if the specified hedgehog gear is controlled by a human player on the computer on which Hedgewars runs on (i.e. not over a computer over the network). Also returns `true` if the hog is a member of any of the local clans. Returns `false` otherwise.
+
+If the game has a mission team (see `AddMissionTeam`), this function behaves a little different: It only may return `true` for hogs in the same clan as the mission team and always returns `false` for hogs from other clans.
+
+Returns `nil` if `gearUid` is invalid.
 
 This is perfect to hide certain captions like weapon messages from enemy eyes.