QUOTE |
if ( item != null ) { if( item is ICraftable ) endquality = ((ICraftable)item).OnCraft( quality, makersMark, from, craftSystem, typeRes, tool, this, resHue ); if ( item.Hue == 0 ) item.Hue = resHue; if ( maxAmount > 0 ) item.Amount = maxAmount; if(item is BaseArmor) { // mod to randomly add sockets and socketability features to armor. These settings will yield // 2% drop rate of socketed/socketable items // 0.1% chance of 5 sockets // 0.5% of 4 sockets // 3% chance of 3 sockets // 15% chance of 2 sockets // 50% chance of 1 socket // the remainder will be 0 socket (31.4% in this case) // uncomment the next line to prevent artifacts from being socketed // if(ArtifactRarity == 0) XmlSockets.ConfigureRandom(item, 2.0, 0.1, 0.5, 3.0, 15.0, 50.0); } from.AddToBackpack( item ); //from.PlaySound( 0x57 ); } |