Difference between revisions of "CreateItemOnObject"
From Dragon Age Toolset Wiki
BryanDerksen (Talk | contribs) m (1 revision: re-import with default parameter value parameters set) |
BryanDerksen (Talk | contribs) (part of the description was missing, adding it in. Removing tag.) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
− | |||
{{dafunction | {{dafunction | ||
|name=CreateItemOnObject | |name=CreateItemOnObject | ||
Line 35: | Line 34: | ||
== Description == | == Description == | ||
<!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --> | <!-- This section contains the full description from the functions comments. Do not change unless you are confident these are incomplete or incorrect. --> | ||
− | Creates an item using the specified file name at lLocation. If the object is a creature | + | Creates an item using the specified file name at lLocation. If the object is a creature then it will also attempt to use an appear animation if the flag is set. If an invalid object type is specified, the file name does not exist or the location is bad an invalid object will be returned. |
+ | |||
NOTE: As with all commands that add items to a container, this command will reset the container (if a placeable) | NOTE: As with all commands that add items to a container, this command will reset the container (if a placeable) | ||
− | to interactive | + | to interactive no matter its previous state. |
<!-- == Remarks == --> | <!-- == Remarks == --> |
Latest revision as of 21:24, 24 February 2010
Creates an item at a specific location
object CreateItemOnObject(
resource rItemFileName,
object oTarget,
int nStackSize = 1,
string sTag = "",
int bSuppressNotification = FALSE,
int bDroppable = TRUE
);
resource rItemFileName,
object oTarget,
int nStackSize = 1,
string sTag = "",
int bSuppressNotification = FALSE,
int bDroppable = TRUE
);
- Parameters:
- rItemFileName
- The file name of the object to create (*.uti)
- oTarget
- The item will be created inside the invetory of this object
- nStackSize
- Stack size of the item to be created
- sTag
- (optional) tag for the new item
- bSuppressNotification
- if true, the "Item Acquired" notification will not be displayed
- bDroppable
- if true, the item can be looted when the target creature dies
- Returns:
- a valid new object or OBJECT_INVALID on error
- Source:
- script.ldf
Description
Creates an item using the specified file name at lLocation. If the object is a creature then it will also attempt to use an appear animation if the flag is set. If an invalid object type is specified, the file name does not exist or the location is bad an invalid object will be returned.
NOTE: As with all commands that add items to a container, this command will reset the container (if a placeable) to interactive no matter its previous state.