Difference between revisions of "GetInCell"

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
imported>JOG
(The parameter needs to be a complete CellName)
imported>QQuix
(Clarifying the required use of EditorIDs)
 
(7 intermediate revisions by 6 users not shown)
Line 1: Line 1:
'''Syntax:'''
'''Syntax:'''
   [''ActorID''.]GetInCell ''CellName''
   [''ActorID''.]GetInCell ''CellID''
'''Example:'''
'''Example:'''
   GetInCell Chorrol  
   GetInCell Chorrol  


Returns true if the actor current is in the specified "CellName".  
Returns true if the actor's current cell includes "CellID" as the first part of its EditorID (not the cell name!). Again, this not exactly "any" part of its EditorID, it has to be the first part of its EditorID ... Chorrol will match Chorrol, Chorrol01, ChorrolFarm, etc.  but using "Farm" would result in never finding ChorrolFarm.  


'''Notes:'''
'''Notes:'''
*The parameter needs to be a complete cellname. Due to the use of numeric [[FormID]]s instead of verbose IDs, you can't specify just parts of the cell-name like in Morrowind.
*The CellID has to be a valid [[Interior_cells|interior cell]] EditorID. This function will not compile if CellID is an [[Exterior cells|Exterior cell]] EditorID. In some cases, it is necessary to create a "dummy" interior cell (e.g. Chorrol) in order to use GetInCell for a set of related interior and exterior cells (e.g. all the ChorrolXXX cells).
 
*The CellName has to be a valid [[Interior_cells|interior cell]] name. [[Exterior cells]] will not work. In some cases, it is necessary to create a "dummy" interior cell (e.g. Chorrol) in order to use GetInCell for a set of related interior and exterior cells (e.g. all the ChorrolXXX cells).  




Line 18: Line 16:


[[Category: Functions]]
[[Category: Functions]]
[[Category:Functions (CS)]]
[[Category: Functions (CS 1.0)]]
[[Category:Actor Functions]]
[[Category:Actor Functions (CS 1.0)]]
[[Category: Actor State Functions]]
[[Category: Actor State Functions]]
[[Category: Actor State Functions (CS 1.0)]]
[[Category: Condition Functions]]
[[Category: Condition Functions]]
[[Category:Actor Functions]]
[[Category: Condition Functions (CS 1.0)]]
 
<!-- Begin Search Terms
Get
In
Cell
End Search Terms -->

Latest revision as of 21:04, 2 May 2011

Syntax:

 [ActorID.]GetInCell CellID

Example:

 GetInCell Chorrol 

Returns true if the actor's current cell includes "CellID" as the first part of its EditorID (not the cell name!). Again, this not exactly "any" part of its EditorID, it has to be the first part of its EditorID ... Chorrol will match Chorrol, Chorrol01, ChorrolFarm, etc. but using "Farm" would result in never finding ChorrolFarm.

Notes:

  • The CellID has to be a valid interior cell EditorID. This function will not compile if CellID is an Exterior cell EditorID. In some cases, it is necessary to create a "dummy" interior cell (e.g. Chorrol) in order to use GetInCell for a set of related interior and exterior cells (e.g. all the ChorrolXXX cells).


See Also[edit | edit source]