Difference between revisions of "ReferenceAlias Script"

From the CreationKit Wiki
Jump to navigation Jump to search
imported>Jog
imported>CraftySentinel
m (→‎Member Functions: Formatting Change)
Line 19: Line 19:


== Member Functions ==
== Member Functions ==
'''Function [[AddInventoryEventFilter - ObjectReference|AddInventoryEventFilter]](Form akFilter)'''
*Adds an inventory event filter to this alias.


'''Function [[Clear - ReferenceAlias|Clear]]()'''
{|class="wikitable" width =100%
*Clears this alias from pointing at anything.
!style="text-align:left;"|Function
!style="text-align:left;"|Description
|-
|[[AddInventoryEventFilter - ObjectReference|'''AddInventoryEventFilter'''(Form ''akFilter'')]]
|Adds an inventory event filter to this alias.
|-


'''bool Function [[ForceRefIfEmpty - ReferenceAlias|ForceRefIfEmpty]](ObjectReference akNewRef)'''
|[[Clear - ReferenceAlias|'''Clear'''()]]
*Tries to force a reference into the alias, but only if it's already empty.
|Clears this alias from pointing at anything.
|-


'''Function [[ForceRefTo - ReferenceAlias|ForceRefTo]](ObjectReference akNewRef)'''
|[[ForceRefIfEmpty - ReferenceAlias|Bool '''ForceRefIfEmpty'''(ObjectReference ''akNewRef'')]]
*Forces this alias to use the specified [[ObjectReference Script|ObjectReference]]
|Tries to force a reference into the alias, but only if it's already empty.
|-


'''Actor Function [[GetActorReference - ReferenceAlias|GetActorRef]]()'''
|[[ForceRefTo - ReferenceAlias|'''ForceRefTo'''(ObjectReference ''akNewRef'')]]
*Alias for GetActorReference().
|Forces this alias to use the specified [[ObjectReference Script|ObjectReference]]
|-


'''Actor Function [[GetActorReference - ReferenceAlias|GetActorReference]]()'''
|[[GetActorReference - ReferenceAlias|Actor '''GetActorReference'''()]]
*Retrieves the alias's [[ObjectReference Script|ObjectReference]] cast as an [[Actor Script|Actor]].
|Alias for GetActorReference().
|-


'''ObjectReference Function [[GetReference - ReferenceAlias|GetRef]]()'''
|[[GetActorReference - ReferenceAlias|Actor '''GetActorReference'''()]]
*Alias for GetReference().
|Retrieves the alias's [[ObjectReference Script|ObjectReference]] cast as an [[Actor Script|Actor]].
|-


'''ObjectReference Function [[GetReference - ReferenceAlias|GetReference]]()'''
|[[GetReference - ReferenceAlias|ObjectReference '''GetReference'''()]]
*Attempts to retrieve the [[ObjectReference Script|ObjectReference]] that this alias is pointing at
|Alias for GetReference().
|-


'''Function [[RemoveAllInventoryEventFilters - ObjectReference|RemoveAllInventoryEventFilters]]()'''
|[[GetReference - ReferenceAlias|ObjectReference '''GetReference'''()]]
*Remove all inventory event filters on this alias.
|Attempts to retrieve the [[ObjectReference Script|ObjectReference]] that this alias is pointing at
|-


'''Function [[RemoveInventoryEventFilter - ObjectReference|RemoveInventoryEventFilter]](Form akFilter)'''
|[[RemoveAllInventoryEventFilters - ObjectReference|'''RemoveAllInventoryEventFilters'''()]]
*Remove a specific inventory event filter.
|Remove all inventory event filters on this alias.
|-


'''bool Function [[TryToAddToFaction - ReferenceAlias|TryToAddToFaction]](Faction FactionToAddTo)'''
|[[RemoveInventoryEventFilter - ObjectReference|'''RemoveInventoryEventFilter'''(Form ''akFilter'')]]
*Attempts to add the reference this alias points to to a faction
|Remove a specific inventory event filter.
|-


'''bool Function [[TryToClear - ReferenceAlias|TryToClear]]()'''
|[[TryToAddToFaction - ReferenceAlias|Bool '''TryToAddToFaction'''(Faction ''FactionToAddTo'')]]
*Attempts to clear this alias
|Attempts to add the reference this alias points to to a faction
|-


'''bool Function [[TryToDisable - ReferenceAlias|TryToDisable]]()'''
|[[TryToClear - ReferenceAlias|Bool '''TryToClear'''()]]
*Attempts to disable the reference this alias points at
|Attempts to clear this alias
|-


'''bool Function [[TryToDisableNoWait - ReferenceAlias|TryToDisableNoWait]]()'''
|[[TryToDisable - ReferenceAlias|Bool '''TryToDisable'''()]]
*Attempts to disable the reference this alias points at (the no-wait version)
|Attempts to disable the reference this alias points at
|-


'''bool Function [[TryToEnable - ReferenceAlias|TryToEnable]]()'''
|[[TryToDisableNoWait - ReferenceAlias|Bool '''TryToDisableNoWait'''()]]
*Attempts to enable the reference this alias points at
|Attempts to disable the reference this alias points at (the no-wait version)
|-


'''bool Function [[TryToEnableNoWait - ReferenceAlias|TryToEnableNoWait]]()'''
|[[TryToEnable - ReferenceAlias|Bool '''TryToEnable'''()]]
*Attempts to enable the reference this alias points at (no-wait version)
|Attempts to enable the reference this alias points at
|-


'''bool Function [[TryToEvaluatePackage - ReferenceAlias|TryToEvaluatePackage]]()'''
|[[TryToEnableNoWait - ReferenceAlias|Bool '''TryToEnableNoWait'''()]]
*Attempts to get the actor this alias points at to re-evaluate his package stack
|Attempts to enable the reference this alias points at (no-wait version)
|-


'''bool Function [[TryToKill - ReferenceAlias|TryToKill]]()'''
|[[TryToEvaluatePackage - ReferenceAlias|Bool '''TryToEvaluatePackage'''()]]
*Attempts to kill the actor this alias points at
|Attempts to get the actor this alias points at to re-evaluate his package stack
|-


'''bool Function [[TryToMoveTo - ReferenceAlias|TryToMoveTo]](ObjectReference RefToMoveTo)'''
|[[TryToKill - ReferenceAlias|Bool '''TryToKill'''()]]
*Attempts to move the reference this alias points to to the target reference
|Attempts to kill the actor this alias points at
|-


'''bool Function [[TryToRemoveFromFaction - ReferenceAlias|TryToRemoveFromFaction]](Faction FactionToRemoveFrom)'''
|[[TryToMoveTo - ReferenceAlias|Bool '''TryToMoveTo'''(ObjectReference ''RefToMoveTo'')]]
*Attempts to remove the reference this alias points to from a faction
|Attempts to move the reference this alias points to to the target reference
|-


'''bool Function [[TryToReset - ReferenceAlias|TryToReset]]()'''
|[[TryToRemoveFromFaction - ReferenceAlias|Bool '''TryToRemoveFromFaction'''(Faction ''FactionToRemoveFrom'')]]
*Attempts to reset the reference this alias points at
|Attempts to remove the reference this alias points to from a faction
|-


'''bool Function [[TryToStopCombat - ReferenceAlias|TryToStopCombat]]()'''
|[[TryToReset - ReferenceAlias|Bool '''TryToReset'''()]]
*Attempts to remove the actor this alias points at from combat
|Attempts to reset the reference this alias points at
|-
 
|[[TryToStopCombat - ReferenceAlias|Bool '''TryToStopCombat'''()]]
|Attempts to remove the actor this alias points at from combat
|-
 
|}


== Events ==
== Events ==

Revision as of 05:24, 24 October 2013


Extends: Alias Script

Script for the manipulation of reference aliases.

Definition

ScriptName ReferenceAlias extends Alias

Properties

None

Global Functions

None

Member Functions

Function Description
AddInventoryEventFilter(Form akFilter) Adds an inventory event filter to this alias.
Clear() Clears this alias from pointing at anything.
Bool ForceRefIfEmpty(ObjectReference akNewRef) Tries to force a reference into the alias, but only if it's already empty.
ForceRefTo(ObjectReference akNewRef) Forces this alias to use the specified ObjectReference
Actor GetActorReference() Alias for GetActorReference().
Actor GetActorReference() Retrieves the alias's ObjectReference cast as an Actor.
ObjectReference GetReference() Alias for GetReference().
ObjectReference GetReference() Attempts to retrieve the ObjectReference that this alias is pointing at
RemoveAllInventoryEventFilters() Remove all inventory event filters on this alias.
RemoveInventoryEventFilter(Form akFilter) Remove a specific inventory event filter.
Bool TryToAddToFaction(Faction FactionToAddTo) Attempts to add the reference this alias points to to a faction
Bool TryToClear() Attempts to clear this alias
Bool TryToDisable() Attempts to disable the reference this alias points at
Bool TryToDisableNoWait() Attempts to disable the reference this alias points at (the no-wait version)
Bool TryToEnable() Attempts to enable the reference this alias points at
Bool TryToEnableNoWait() Attempts to enable the reference this alias points at (no-wait version)
Bool TryToEvaluatePackage() Attempts to get the actor this alias points at to re-evaluate his package stack
Bool TryToKill() Attempts to kill the actor this alias points at
Bool TryToMoveTo(ObjectReference RefToMoveTo) Attempts to move the reference this alias points to to the target reference
Bool TryToRemoveFromFaction(Faction FactionToRemoveFrom) Attempts to remove the reference this alias points to from a faction
Bool TryToReset() Attempts to reset the reference this alias points at
Bool TryToStopCombat() Attempts to remove the actor this alias points at from combat

Events

ReferenceAliases receive events from the ObjectReference they are pointing at.

ReferenceAliases may also receive additional events if they are pointing at an Actor.