Difference between revisions of "GetWorkshopOwnedObjects - ObjectReference"
Jump to navigation
Jump to search
imported>DarkruneDK (Created page with "Category:Scripting Category:Papyrus '''Member of:''' ObjectReference Script Finds all references linked to the Workshop reference that are...") |
imported>Kalevala |
||
Line 21: | Line 21: | ||
ObjectReference[] bobsStuff = SanctuaryWorkshopRef.GetWorkshopResourceObjects(Bob) | ObjectReference[] bobsStuff = SanctuaryWorkshopRef.GetWorkshopResourceObjects(Bob) | ||
</source> | </source> | ||
== Notes == | |||
The ObjectReference must have a LinkedRef to the Workshop via the WorkshopItemKeyword keyword in order to be found by this function. This is done automatically when an object is placed in WorkshopMode, but must be done manually if you spawn the ObjectReference with a script. | |||
== See Also == | == See Also == | ||
*[[ObjectReference Script]] | *[[ObjectReference Script]] | ||
*[[Game Script]] | *[[Game Script]] |
Revision as of 18:07, 18 October 2016
Member of: ObjectReference Script
Finds all references linked to the Workshop reference that are owned by the given Actor.
Syntax
ObjectReference[] Function GetWorkshopOwnedObjects(Actor akActor) native
Parameters
- akActor: The owning actor.
Return Value
An array of references owned by the Actor.
Examples
; Find all objects in the SanctuaryWorkshopRef workshop owned by the actor Bob.
ObjectReference[] bobsStuff = SanctuaryWorkshopRef.GetWorkshopResourceObjects(Bob)
Notes
The ObjectReference must have a LinkedRef to the Workshop via the WorkshopItemKeyword keyword in order to be found by this function. This is done automatically when an object is placed in WorkshopMode, but must be done manually if you spawn the ObjectReference with a script.