Talk:IsChild - Location

From the CreationKit Wiki
Revision as of 06:04, 7 August 2017 by imported>Lisselli (Undo revision 48374 by Lisselli (talk))
Jump to navigation Jump to search

If you call this on Tamriel, it will always return true - unless the cell has no location, or that location's parent doesn't have Tamriel as the "final" parent, to which this function will return none. IsChild() doesn't check for locations between the caller and the passed in, if the caller is Tamriel. --Terra Nova2 (talk) 2016-02-05T09:24:07 (EST)

An example to this would be.. Riverwood has the location RiverwoodLocation. The parent location for its location form is WhiterunHoldLocation. However if you write this code:
TamrielLocation.isChild(RiverwoodLocation)

It will return true, even though it's actually WhiterunHoldLocation. Additional coding is needed if you want to get the true parent location of a location. Lisselli (talk) 2017-04-23T07:55:42 (EDT)

In other words, this function is not useful on its own if you want to find out which holdlocation is the parent location of a location. Lisselli (talk) 2017-04-23T08:02:37 (EDT)
Correction: To check if a hold is the parent of a location or not, just call this function on a hold location property. Lisselli (talk) 2017-04-24T00:26:26 (EDT)