Difference between revisions of "Cell Script"

From the CreationKit Wiki
Jump to navigation Jump to search
imported>Jog
imported>Svarr
m (→‎SKSE Member Functions: Corrected return type of GetWaterLevel())
 
(7 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[Category:Scripting]]
[[Category:Papyrus]]
[[Category:Script Objects]]
'''Extends:''' [[Form Script]]
'''Extends:''' [[Form Script]]


Line 12: Line 8:
</source>
</source>


== Properties ==
None


== Global Functions ==
== Member Functions ==
None
 
:'''ActorBase [[GetActorOwner - Cell|GetActorOwner]]()'''
:*Obtains the actor base object that owns this cell.
 
:'''Faction [[GetFactionOwner - Cell|GetFactionOwner]]()'''
:*Obtains the faction that owns this cell.


== Member Functions ==
:'''Bool [[IsAttached - Cell|IsAttached]]()'''
'''ActorBase Function [[GetActorOwner - Cell|GetActorOwner]]()'''
:*Is this cell currently attached?
*Obtains the actor base object that owns this cell.
 
:'''Bool [[IsInterior - Cell|IsInterior]]()'''
:*Is this cell an interior cell?
 
:'''[[Reset - Cell|Reset]]()'''
:*Flags this cell for reset on next load.
 
:'''[[SetActorOwner - Cell|SetActorOwner]](ActorBase ''akActorBase'')'''
:*Sets the actor base as this cell's owner.
 
:'''[[SetFactionOwner - Cell|SetFactionOwner]](Faction ''akFaction'')'''
:*Sets the faction as this cell's owner.


'''Faction Function [[GetFactionOwner - Cell|GetFactionOwner]]()'''
:'''[[SetFogColor - Cell|SetFogColor]](Int ''aiNearRed'', Int ''aiNearGreen'', Int ''aiNearBlue'', Int ''aiFarRed'', Int ''aiFarGreen'', Int ''aiFarBlue'')'''
*Obtains the faction that owns this cell.
:*Sets the near and far fog colors for the cell. Only works in non-sky-lit interiors.


'''bool Function [[IsAttached - Cell|IsAttached]]()'''
:'''[[SetFogPlanes - Cell|SetFogPlanes]](Float ''afNear'', Float ''afFar'')'''
*Is this cell currently attached?
:*Sets the near and far fog plane distances for this cell. Only works in non-sky-lit interiors.


'''bool Function [[IsInterior - Cell|IsInterior]]()'''
:'''[[SetFogPower - Cell|SetFogPower]](Float ''afPower'')'''
*Is this cell an interior cell?
:*Sets the fog power for this cell. Only works in non-sky-lit interiors.


'''Function [[Reset - Cell|Reset]]()'''
:'''[[SetPublic - Cell|SetPublic]](Bool ''abPublic'')'''
*Flags this cell for reset on next load.
:*Sets this cell as either public or private.


'''Function [[SetActorOwner - Cell|SetActorOwner]](ActorBase akActorBase)'''
*Sets the actor base as this cell's owner.


'''Function [[SetFactionOwner - Cell|SetFactionOwner]](Faction akFaction)'''
== SKSE Member Functions ==
*Sets the faction as this cell's owner.


'''Function [[SetFogColor - Cell|SetFogColor]](int aiNearRed, int aiNearGreen, int aiNearBlue, int aiFarRed, int aiFarGreen, int aiFarBlue)'''
:'''Int [[GetNumRefs - Cell|GetNumRefs]](Int ''formTypeFilter'')'''
*Sets the near and far fog colors for the cell. Only works in non-sky-lit interiors.
:*Returns the number of references in the cell that match the form filter (or all if formTypeFilter is 0).


'''Function [[SetFogPlanes - Cell|SetFogPlanes]](float afNear, float afFar)'''
:'''ObjectReference [[GetNthRef - Cell|GetNthRef]](Int ''n'', Int ''formTypeFilter'')'''
*Sets the near and far fog plane distances for this cell. Only works in non-sky-lit interiors.
:*Returns the specified reference in the cell that matches the form filter.


'''Function [[SetFogPower - Cell|SetFogPower]](float afPower)'''
:'''Float [[GetWaterLevel]]()'''
*Sets the fog power for this cell. Only works in non-sky-lit interiors.
:*Returns the water level of the cell. (will be -2147483648 if no water)


'''Function [[SetPublic - Cell|SetPublic]](bool abPublic)'''
*Sets this cell as either public or private.


== Events ==
[[Category:Scripting]]
None
[[Category:Papyrus]]
[[Category:Script Objects]]
[[Category:SKSE]]
[[Category:SKSE Script Objects]]

Latest revision as of 08:44, 14 July 2016

Extends: Form Script

Script for the manipulation of cells.

Definition[edit | edit source]

ScriptName Cell extends Form


Member Functions[edit | edit source]

ActorBase GetActorOwner()
  • Obtains the actor base object that owns this cell.
Faction GetFactionOwner()
  • Obtains the faction that owns this cell.
Bool IsAttached()
  • Is this cell currently attached?
Bool IsInterior()
  • Is this cell an interior cell?
Reset()
  • Flags this cell for reset on next load.
SetActorOwner(ActorBase akActorBase)
  • Sets the actor base as this cell's owner.
SetFactionOwner(Faction akFaction)
  • Sets the faction as this cell's owner.
SetFogColor(Int aiNearRed, Int aiNearGreen, Int aiNearBlue, Int aiFarRed, Int aiFarGreen, Int aiFarBlue)
  • Sets the near and far fog colors for the cell. Only works in non-sky-lit interiors.
SetFogPlanes(Float afNear, Float afFar)
  • Sets the near and far fog plane distances for this cell. Only works in non-sky-lit interiors.
SetFogPower(Float afPower)
  • Sets the fog power for this cell. Only works in non-sky-lit interiors.
SetPublic(Bool abPublic)
  • Sets this cell as either public or private.


SKSE Member Functions[edit | edit source]

Int GetNumRefs(Int formTypeFilter)
  • Returns the number of references in the cell that match the form filter (or all if formTypeFilter is 0).
ObjectReference GetNthRef(Int n, Int formTypeFilter)
  • Returns the specified reference in the cell that matches the form filter.
Float GetWaterLevel()
  • Returns the water level of the cell. (will be -2147483648 if no water)