jayates

Member
I wanna add 105 PSs to the drop of a champion. How would I add that bit of code in? Here's the code area that needs the addition just not sure how to word it:
C#:
            PsCount = ChampionSpawn ? 5 : 2; //set how many ps to give if it spawned using champ spawn or normal spawn
            for ( int i = 0; i < PsCount; ++i )
            {
                Mobile m = (Mobile)toGive[i % toGive.Count];
                int level;
                double random = Utility.RandomDouble();
                if ( 0.25 >= random ) // select the level of the ps
                    level = 120;
                else if ( 0.55 >= random )
                    level = 115;
                else
                    level = 110;
           
                if ( OWLTROptionsManager.IsEnabled(OWLTROptionsManager.OPTIONS_ENUM.RECIPE_CRAFT) )
                    m.AddToBackpack( new ResourceRecipe() );
 
Code:
            PsCount = ChampionSpawn ? 5 : 2; //set how many ps to give if it spawned using champ spawn or normal spawn
            for ( int i = 0; i < PsCount; ++i )
            {
                Mobile m = (Mobile)toGive[i % toGive.Count];
                int level;
                double random = Utility.RandomDouble();
                if ( 0.25 >= random ) // select the level of the ps
                    level = 120;
                else if ( 0.45>= random )
                    level = 115;
                else if ( 0.65>= random )
                    level = 110;
               else
                    level = 105;
           
                if ( OWLTROptionsManager.IsEnabled(OWLTROptionsManager.OPTIONS_ENUM.RECIPE_CRAFT) )
                    m.AddToBackpack( new ResourceRecipe() );
ionsManager.OPTIONS_ENUM.RECIPE_CRAFT) )
m.AddToBackpack( new ResourceRecipe() );

should do the trick. You just re-distribute the chances in the random section.
 

Active Shards

Donations

Total amount
$0.00
Goal
$1,000.00
Back