AddLoot() 공개 메소드

public AddLoot ( LootPack pack ) : void
pack Server.LootPack
리턴 void
예제 #1
0
        public static void Convert(BaseCreature bc)
        {
            if (bc.IsParagon)
            {
                return;
            }

            bc.Hue = Hue;

            if (bc.HitsMaxSeed >= 0)
            {
                bc.HitsMaxSeed = (int)(bc.HitsMaxSeed * HitsBuff);
            }

            bc.RawStr = (int)(bc.RawStr * StrBuff);
            bc.RawInt = (int)(bc.RawInt * IntBuff);
            bc.RawDex = (int)(bc.RawDex * DexBuff);

            bc.Hits = bc.HitsMax;
            bc.Mana = bc.ManaMax;
            bc.Stam = bc.StamMax;

            for (int i = 0; i < bc.Skills.Length; i++)
            {
                Skill skill = (Skill)bc.Skills[i];

                if (skill.Base > 0.0)
                {
                    skill.Base *= SkillsBuff;
                }
            }

            bc.PassiveSpeed /= SpeedBuff;
            bc.ActiveSpeed  /= SpeedBuff;

            bc.DamageMin += DamageBuff;
            bc.DamageMax += DamageBuff;

            if (bc.Fame > 0)
            {
                bc.Fame = (int)(bc.Fame * FameBuff);
            }

            if (bc.Fame > 32000)
            {
                bc.Fame = 32000;
            }

            // TODO: Mana regeneration rate = Sqrt( buffedFame ) / 4

            if (bc.Karma != 0)
            {
                bc.Karma = (int)(bc.Karma * KarmaBuff);

                if (bc.TotalGold > 0)
                {
                    bc.PackGold((int)(bc.TotalGold * 1.5));
                }
                if (bc.Fame <= 500)
                {
                    bc.AddLoot(LootPack.Poor);
                }
                if (bc.Fame <= 1700 && bc.Fame > 500)
                {
                    bc.AddLoot(LootPack.Meager);
                }
                if (bc.Fame <= 4500 && bc.Fame > 1700)
                {
                    bc.AddLoot(LootPack.Average);
                }
                if (bc.Fame <= 10000 && bc.Fame > 4500)
                {
                    bc.AddLoot(LootPack.Rich);
                }
                if (bc.Fame <= 16000 && bc.Fame > 10000)
                {
                    bc.AddLoot(LootPack.FilthyRich);
                }
                if (bc.Fame <= 26000 && bc.Fame > 16000)
                {
                    bc.AddLoot(LootPack.UltraRich);
                }
                if (bc.Fame <= 32000 && bc.Fame > 26000)
                {
                    bc.AddLoot(LootPack.SuperBoss);
                }

                if (Math.Abs(bc.Karma) > 32000)
                {
                    bc.Karma = 32000 * Math.Sign(bc.Karma);
                }
            }
        }
예제 #2
0
		public static void Convert( BaseCreature bc )
		{
			if ( bc.IsParagon )
				return;

			bc.Hue = Hue;

			if ( bc.HitsMaxSeed >= 0 )
				bc.HitsMaxSeed = (int)( bc.HitsMaxSeed * HitsBuff );
			
			bc.RawStr = (int)( bc.RawStr * StrBuff );
			bc.RawInt = (int)( bc.RawInt * IntBuff );
			bc.RawDex = (int)( bc.RawDex * DexBuff );

			bc.Hits = bc.HitsMax;
			bc.Mana = bc.ManaMax;
			bc.Stam = bc.StamMax;

			for( int i = 0; i < bc.Skills.Length; i++ )
			{
				Skill skill = (Skill)bc.Skills[i];

				if ( skill.Base > 0.0 )
					skill.Base *= SkillsBuff;
			}

			bc.PassiveSpeed /= SpeedBuff;
			bc.ActiveSpeed /= SpeedBuff;

			bc.DamageMin += DamageBuff;
			bc.DamageMax += DamageBuff;

			if ( bc.Fame > 0 )
				bc.Fame = (int)( bc.Fame * FameBuff );

			if ( bc.Fame > 32000 )
				bc.Fame = 32000;

			// TODO: Mana regeneration rate = Sqrt( buffedFame ) / 4

			if ( bc.Karma != 0 )
			{
				bc.Karma = (int)( bc.Karma * KarmaBuff );

                if (bc.TotalGold > 0)
                {
                    bc.PackGold((int)(bc.TotalGold * 1.5));
                }
                if (bc.Fame <= 500)
                {
                    bc.AddLoot(LootPack.Poor);
                }
                if (bc.Fame <= 1700 && bc.Fame > 500)
                {
                    bc.AddLoot(LootPack.Meager);
                }
                if (bc.Fame <= 4500 && bc.Fame > 1700)
                {
                    bc.AddLoot(LootPack.Average);
                }
                if (bc.Fame <= 10000 && bc.Fame > 4500)
                {
                    bc.AddLoot(LootPack.Rich);
                }
                if (bc.Fame <= 16000 && bc.Fame > 10000)
                {
                    bc.AddLoot(LootPack.FilthyRich);
                }
                if (bc.Fame <= 26000 && bc.Fame > 16000)
                {
                    bc.AddLoot(LootPack.UltraRich);
                }
                if (bc.Fame <= 32000 && bc.Fame > 26000)
                {
                    bc.AddLoot(LootPack.SuperBoss);
                }

				if( Math.Abs( bc.Karma ) > 32000 )
					bc.Karma = 32000 * Math.Sign( bc.Karma );
			}
		}