Nothing I change works. T.T... It shows up in downloaded content as being there, but the item doesn't spawn in inventories and other changes to existing items I made didn't work either. I pretty much just took away the restrictions on Morrigan's two robes and made a new one with better stats. I made sure the module was set to run the script too... No clue why it doesn't work. // All module events
#include "utility_h"
#include "wrappers_h"
#include "events_h"
void main()
{
event ev = GetCurrentEvent();
int nEvent = GetEventType(ev);
Log_Events("", ev);
switch (nEvent)
{
////////////////////////////////////////////////////////////////////////
// Sent by: The engine
// When: The module loads from a save game, or for the first time. This event can fire more than
// once for a single module or game instance.
////////////////////////////////////////////////////////////////////////
case EVENT_TYPE_MODULE_LOAD:
{
// this event can fire multiple times, and we only want to do this once
// So we save a flag inside a number variable. We check it here and if its
// set already then we know we've already done this before. The name of the
// variable in quotes can be whatever you want.
int iModuleLoaded = GetLocalInt(OBJECT_SELF, "000_wildsrobe");
if (iModuleLoaded == 1)
break;
// get the object which contains the player
object oPlayer = GetHero();
// The flag we save won't persist beyond the game session, so its a good idea to actually
// look to see if the player already has the item, unless you WANT them to get another one
// The name in quotes is the TAG of the item. So what we do is see how many of the item
// the player already has, and if its 0, we know we haven't given it to them yet (or they sold it :p)
int iItemCount = CountItemsByTag(oPlayer, "000_wildsrobe");
// if its 0, then let's give them the item. Now this first parameter is a RESOURCE identifier. Note
// how its formatted. R"resource_file_name"
// The "R" part is important and identifies it as a resource. The filename is just the filename of the
// resource. You can see this in the toolset on the tabs up top.
// The number 1 means give 1 item.
if (iItemCount == 0)
UT_AddItemToInventory(R"000_wildsrobe.uti",1);
// lastly we set that number variable we talked about earlier, to save the fact that we've
// done this already.
SetLocalInt(OBJECT_SELF, "000_wildsrobe", 1);
break;
}
default:
{
break;
}
}
} http://i49.tinypic.com/5uh1cn.jpg http://i46.tinypic.com/2i07pcg.jpg http://i47.tinypic.com/iz7xpv.jpg Any idea?