Copy Object
Zephirius
Member Posts: 419
I've copied oPC and now I want it to turn hostile but can't seem to assign a tag to it. Any help would be cool.
void main() { object oPC = GetLastUsedBy(); if (!GetIsPC(oPC)) return; location lLoc; lLoc = GetLocation(oPC); CopyObject(oPC, lLoc, oPC); }
0
Comments
You can set the tag of the new object with the 4th parameter.
The function returns the new object, too, so you don't necessarily need to refer to it by tag.
The third parameter should be OBJECT_INVALID, as you're not creating an inventory item.