Difference between revisions of "Location Hierarchy"

384 bytes added ,  05:06, 7 August 2017
m
fixed typo
imported>Terra Nova2
(Created this page with info regarding locations. Work in progress.)
 
imported>Lisselli
m (fixed typo)
 
(4 intermediate revisions by one other user not shown)
Line 1: Line 1:
This page is created to share my findings on the hierarchy of locations in the game. This came about during my discovery of '''[[isChild - Location]]''' not returning false if Tamriel is called on it, if it is in fact '''not''' the "true" parent of a location, but instead the "last" in most cases. This can be misleading to anyone wanting to get the ACTUAL parent of a location. In short, that function can lie to you. Detailed explanation on this will be provided. After extensive testing I have outlined all the important locations that have a "hierarchy" of locations. At the present time this doesn't cover DLC locations.
This page is created to share my findings on the hierarchy of locations in the game. This came about during my discovery of '''[[isChild - Location]]''' not returning true if Tamriel is called on it, when it is in fact '''not''' the "true" parent of a location, but instead the "last" in most cases. This can be misleading to anyone wanting to get the ACTUAL parent of a location. In short, that function can lie to you. Detailed explanation on this will be provided. After extensive testing I have outlined all the important locations that have a "hierarchy" of locations. At the present time this doesn't cover DLC locations.


== City Locations ==
== City Locations ==
Line 71: Line 71:
Location property AzurasStarInteriorLocation auto<br>
Location property AzurasStarInteriorLocation auto<br>


== Findings on IsChild - Location ==
== Nested Locations ==
 
While working with locations in the Creation Kit, I have noticed a pattern with locations. City Interiors have three "parents". This is usually a location representing the city, and then the location representing the hold, and finally, Tamriel. This isn't always true in the case of The Winking Sheever which has SolitudeWellsLocation instead of SolitudeLocation like the other interiors. And example of what I mean is this:
Now an example of [[isChild - Location]] lying. If you do this:
* '''Riverwood Trader''' > ''' RiverwoodLocation''' > '''WhiterunHoldLocation''' > '''TamrielLocation'''
<source lang="papyrus">
For Dungeon interiors, they mostly contain two "parents". Example:
Location property TamrielLocation
* '''Embershard Mine''' > '''FalkreathHoldLocation''' > '''TamrielLocation'''
 
There are a few locations that do not have a parent, and the vast majority of wildernesses do not have locations. Finally all cells within a worldspace that is not Tamriel so far, may have a 'nested location' as well. Take the worldspace for Bloated Man's Grotto for example:
Bool Function SomeFunction()
* '''BloatedMansGrottoLocation''' > '''FalkreathHoldLocation''' > '''TamrielLocation'''
    if DawnstarLocation.isChild(TamrielLocation)
--[[User:Terra Nova2|Terra Nova2]] ([[User talk:Terra Nova2|talk]]) 2016-02-16T10:04:53 (EST)
        return true
    else
        return false
    endif
EndFunction
</source>
 
This will return true. '''But this is not true.''' The parent of DawnstarLocation is '''PaleHoldLocation'''.  This is because the function skips any locations in the lower hierarchy and returns whatever is the highest in the list. In this case that's always TamrielLocation.
 
Now if you call [[isChild - Location]] on PaleHoldLocation, while passing in TamrielLocation, it will correctly return true, because '''Tamriel is the parent of all holds.'''
Anonymous user