if supplied, it uses the keyword to test if the locations share a parent with that keyword, or one of the locations has the keyword and is a parent of the other.
Default:None
Examples
; Is myLocationProperty the same as MarylandLocationProperty?
if (MyLocationProperty.IsSameLocation(MarylandLocationProperty))
Debug.Trace("MyLocationProperty is MarylandLocationProperty.")
endIf
; Is myLocationProperty the same as MyOtherLocationProperty OR are both locations in the same location with the keyword "LocTypeCountry" stored in LocTypeProperty?
if (MyLocationProperty.IsSameLocation(MyOtherLocationProperty, LocTypeProperty))
Debug.Trace("MyLocationProperty is MyOtherLocationProperty or we are in the same Country (or one us is the Country the other one is in).")
endIf
; Is the player in a location that is WhiterunLocation or a location who has WhiterunLocation as a parent
; (when WhiterunProperty points to WhiterunLocation and KeywordHoldProperty points to LocTypeHold keyword)
if Game.GetPlayer().GetCurrentLocation().IsSameLocation(WhiterunProperty, KeywordHoldProperty)
Debug.Trace("Player is in WhiterunLocation, or a child of WhiterunLocation.")
endif
;Is the player and the CourierRef (stored in pCourier) in the same settlement, town, or city (ie the "LocTypeHabitation" keyword stored in)pLocTypeHabitation
if pCourier.getCurrentLocation().IsSameLocation(Game.GetPlayer().getCurrentLocation(), pLocTypeHabitation)
debug.trace("WICourierScript: Courier and player are in same habitation.")
else
debug.trace("WICourierScript: Courier and player are not in same habitation.")
endif
Returns true if the calling location is the same as the supplied location. Or, if an optional keyword is supplied it also returns true if the locations share a parent with that keyword, or one of the locations has the keyword and is a parent of the other.
Documentation String
Returns true if the calling location is the same as the supplied location - if an optional keyword is supplied, it also returns true if the locations share a parent with that keyword, or if either location is a child of the other and the other has that keyword.
; Is myLocationProperty the same as MarylandLocationProperty?if(MyLocationProperty.IsSameLocation(MarylandLocationProperty))Debug.Trace("MyLocationProperty is MarylandLocationProperty.")endIf
; Is myLocationProperty the same as MyOtherLocationProperty OR are both locations in the same location with the keyword "LocTypeCountry" stored in LocTypeProperty?if(MyLocationProperty.IsSameLocation(MyOtherLocationProperty, LocTypeProperty))Debug.Trace("MyLocationProperty is MyOtherLocationProperty or we are in the same Country (or one us is the Country the other one is in).")endIf
; Is the player in a location that is WhiterunLocation or a location who has WhiterunLocation as a parent; (when WhiterunProperty points to WhiterunLocation and KeywordHoldProperty points to LocTypeHold keyword)if Game.GetPlayer().GetCurrentLocation().IsSameLocation(WhiterunProperty, KeywordHoldProperty)Debug.Trace("Player is in WhiterunLocation, or a child of WhiterunLocation.")endif
;Is the player and the CourierRef (stored in pCourier) in the same settlement, town, or city (ie the "LocTypeHabitation" keyword stored in)pLocTypeHabitationif pCourier.getCurrentLocation().IsSameLocation(Game.GetPlayer().getCurrentLocation(), pLocTypeHabitation)debug.trace("WICourierScript: Courier and player are in same habitation.")elsedebug.trace("WICourierScript: Courier and player are not in same habitation.")endif