Revert "Updates Packets & Randomizer (#43)" (#61)

This reverts commit 179cb50557.
This commit is contained in:
Kamron Batman 2019-11-11 08:46:11 -08:00 • committed by GitHub
parent 179cb50557
commit c2ecc76457
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
588 changed files with 16260 additions and 10926 deletions

View file

@ -4,6 +4,7 @@ using Server.Gumps;
using Server.Items;
using Server.Mobiles;
using Server.Network;
using Server.Prompts;
namespace Server.Engines.BulkOrders
{

View file

@ -1,6 +1,7 @@
using System.Collections.Generic;
using Server.Gumps;
using Server.Multis;
using Server.Prompts;
using Server.Mobiles;
using Server.ContextMenus;
using Server.Items;

View file

@ -1,4 +1,3 @@
using System.Linq;
using Server.Mobiles;
namespace Server.Engines.BulkOrders

View file

@ -2,7 +2,7 @@ namespace Server.Engines.BulkOrders
{
public class LargeTailorBOD : LargeBOD
{
public static readonly double[] m_TailoringMaterialChances =
public static double[] m_TailoringMaterialChances =
{
0.857421875, // None
0.125000000, // Spined
@ -19,6 +19,7 @@ namespace Server.Engines.BulkOrders
switch (Utility.Random(14))
{
default:
case 0:
entries = LargeBulkEntry.ConvertEntries(this, LargeBulkEntry.Farmer);
break;
case 1:

View file

@ -357,14 +357,7 @@ namespace Server.Engines.BulkOrders
int[][][] goldTable = m_GoldTable;
int typeIndex = ComputeType(type, itemCount);
int quanIndex = quantity switch
{
20 => 2,
15 => 1,
_ => 0
};
int quanIndex = quantity == 20 ? 2 : quantity == 15 ? 1 : 0;
int mtrlIndex = material >= BulkMaterialType.DullCopper && material <= BulkMaterialType.Valorite
? 1 + (material - BulkMaterialType.DullCopper)
: 0;
@ -606,28 +599,11 @@ namespace Server.Engines.BulkOrders
{
int[][][] goldTable = Core.AOS ? m_AosGoldTable : m_OldGoldTable;
int typeIndex = itemCount switch
{
6 => 3,
5 => 2,
4 => 1,
_ => 0
} * 2 + (exceptional ? 1 : 0);
int quanIndex = quantity switch
{
20 => 2,
15 => 1,
_ => 0
};
int mtrlIndex = material switch
{
BulkMaterialType.Barbed => 3,
BulkMaterialType.Horned => 2,
BulkMaterialType.Spined => 1,
_ => 0
};
int typeIndex = (itemCount == 6 ? 3 : itemCount == 5 ? 2 : itemCount == 4 ? 1 : 0) * 2 + (exceptional ? 1 : 0);
int quanIndex = quantity == 20 ? 2 : quantity == 15 ? 1 : 0;
int mtrlIndex = material == BulkMaterialType.Barbed ? 3 :
material == BulkMaterialType.Horned ? 2 :
material == BulkMaterialType.Spined ? 1 : 0;
int gold = goldTable[typeIndex][quanIndex][mtrlIndex];
@ -639,7 +615,7 @@ namespace Server.Engines.BulkOrders
#region Constructors
private static readonly int[][] m_ClothHues =
private static int[][] m_ClothHues =
{
new[] { 0x483, 0x48C, 0x488, 0x48A },
new[] { 0x495, 0x48B, 0x486, 0x485 },
@ -702,15 +678,13 @@ namespace Server.Engines.BulkOrders
};
}
private static Item CreateRunicKit(int type) =>
type >= 1 && type <= 3
? new RunicSewingKit(CraftResource.RegularLeather + type, 60 - type * 15)
: throw new InvalidOperationException();
private static Item CreateRunicKit(int type)
{
if (type >= 1 && type <= 3)
return new RunicSewingKit(CraftResource.RegularLeather + type, 60 - type * 15);
private static Item CreatePowerScroll(int type) =>
type == 5 || type == 10 || type == 15 || type == 20
? new PowerScroll(SkillName.Tailoring, 100 + type)
: throw new InvalidOperationException();
throw new InvalidOperationException();
}
private static Item CreatePowerScroll(int type)
{