IsDescendantOf (Function): Difference between revisions

From Legacy Roblox Wiki
Jump to navigationJump to search
>LPGhatguy
No edit summary
>ArceusInator
Wrong name
Line 1: Line 1:
{|
#REDIRECT [[IsDescendantOf (Method)]]
|<onlyinclude>{{Function|
name                  = IsDescendantOf
|arguments            = [[Instance]] Ancestor
|returns              = [[Boolean]] Is descendant
|description          = Returns whether the object is a descendant of '''Ancestor'''.
|object              = Instance
|}}
</onlyinclude>|}
 
==Description==
 
Tells whether one of the Parents of the Parents of etc.. of the calling object is the argument
 
==Example==
<pre>
a = Instance.new("Part") --> put a part in workspace
a.Parent = game.Workspace
 
print(a:IsDescendantOf(game)) --> prints true
</pre>

Revision as of 15:55, 31 March 2011