- Code: Select all
int i = 0;
Actor* myActor = 0;
actor_to_screen(&xmouse, &ymouse);
myActor = CreateActor("Draggable", "simplegear", "(none)", "(none)", xmouse, ymouse, false);
i = rand(3);
myActor->animpos = i;
myActor->ItemBaseType = i;
//Add Random Mods
myActor->ItemMod1 = rand(4);
myActor->ItemMod2 = rand(4);
myActor->ItemMod3 = rand(4);
myActor->ItemMod4 = rand(4);
/* Adding "//" in front of the line below causes GE to Crash */
strcpy(myActor->ItemName, ItemModList[myActor->ItemMod1].prefix + " " + ItemModList[myActor->ItemMod2].prefix + " " + BaseTypes[myActor->ItemBaseType] + " " + ItemModList[myActor->ItemMod3].suffix + " " + ItemModList[myActor->ItemMod4].suffix);