Power Source CO HELP!!!!

07/26/2009 20:37 f0am#16
Actually noman person, you can do it this way, his was wasn't wrong at all

Code:
if (Other.ChanceSuccess(100))
                    {
                        string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
                        World.ItemDrops(item);
}
The problem was that you did chance 1000, i think there is no 1000/100 chance.
07/26/2009 20:41 roycu#17
F0am, ill try it that way thanks :) is there anyway you can make certin mobs drop certin items? thanks for all your help so far you have been very helpful
07/26/2009 20:42 n0mansland#18
Quote:
Originally Posted by roycu View Post
lol sorry im completly new :( where do you put what mob it drops for? lol its prob in plain sight im just blinde :(
Enitities.cs Infront of any other code (Not near top) Just as long as you don't get errors putting it in.
07/26/2009 20:44 roycu#19
SORRY FOR DOUBLE POST but i just tested your way f0am and they still are not drop any :( if it helps im killing phesents for this expareament
07/26/2009 20:46 roycu#20
noman do you mean like this?

(put monster ID here) if (Other.ChanceSuccess(100))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
07/26/2009 20:52 n0mansland#21
Quote:
Originally Posted by roycu View Post
norman do you mean like this?

(put monster ID here) if (Other.ChanceSuccess(100))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
No, Nothing goes there unless you are checking something just
Code:
Other.ChanceSuccess(100))
Goes there, but if you want to make it on a specific mob you seperate it with || Then after that you would put something like this

Code:
(BossMob && Other.ChanceSuccess(50)))
So altogether

Code:
((Other.ChanceSuccess(100)) || (BossMob && Other.ChanceSuccess(100)))
Doing things like those you can also check if they have LuckyTime and boost up their drop rates.. Messing with drops are fun :)
07/26/2009 21:02 f0am#22
Code:
                    #region DragonBall Drop
                    if (Other.ChanceSuccess(4))
                    {
                        string Item = "1088000-0-0-0-0-0";
                        DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
                        World.ItemDrops(item);
                    }
                    #endregion
                    #region Certain Mob Drop
                    if (Name == "Pheasant")
                    {
                        if (Other.ChanceSuccess(2))
                        {
                            string Item = "1088000-0-0-0-0-0";
                            DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
                            World.ItemDrops(item);
                        }
                    }
                    #endregion
there. since u tried, those both should work
07/26/2009 21:10 roycu#23
thanks! 2 things =] 1 would be where does that big code you just gave me go :( sorry im a noob amd 2nd is it possible to make rb work on my server since its only client 5017?
07/26/2009 21:17 f0am#24
entities.cs like i said before, yes it isp ossible
07/26/2009 21:20 roycu#25
i ment where in the entities.cs i tried putting that code where the other drop rates were and nothing happend so i put it at the end of EVERYTHING in entities and nothing happend so i must eather be entering code wrong or putting code in wrong spot, sorry for so many questions

#region DragonBall Drop
if (Other.ChanceSuccess(4))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
#endregion
#region Certain Mob Drop
if (Name == "Pheasant")
{
if (Other.ChanceSuccess(2))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
}
#endregion



p.s. ok sweet is making rb hard? well hard for a noob lol
07/26/2009 21:22 f0am#26
just look for another one of those if (Other.ChanceSucess there is bound to be on >< anyway... rb is already released. search for like
[All-In-1] Guides and Releases or [All-In-1] LOTF guides and releases
07/26/2009 21:29 roycu#27
Quote:
if (Other.ChanceSuccess(50) || BossMob && Other.ChanceSuccess(85) || MType == 1)
{
int DMG = General.Rand.Next(MinAtk, MaxAtk) - (int)Target.Defense;

if (DMG < 1)
DMG = 1;

if (Target.GetHitDie((uint)DMG))
{
if (MType == 1)
World.MobAttacksCharSkill(this, Target, (uint)DMG, 1320, 2);
else
World.MobAttacksChar(this, Target, 2, (uint)DMG);
World.MobAttacksChar(this, Target, 14, (uint)DMG);
}
else
{
if (MType == 1)
World.MobAttacksCharSkill(this, Target, (uint)DMG, 1320, 2);
else
World.MobAttacksChar(this, Target, 2, (uint)DMG);
}
Target = null;
}
}
else
{
Target = null;
}
i found that if thats what your talking about also
Quote:
if (Other.ChanceSuccess(50) || BossMob && Other.ChanceSuccess(85) || MType == 1)
{
int DMG = General.Rand.Next(MinAtk, MaxAtk) - (int)Target.Defense;

if (DMG < 1)
DMG = 1;

if (Target.GetHitDie((uint)DMG))
{
if (MType == 1)
World.MobAttacksCharSkill(this, Target, (uint)DMG, 1320, 2);
else
World.MobAttacksChar(this, Target, 2, (uint)DMG);
World.MobAttacksChar(this, Target, 14, (uint)DMG);
}
else
{
if (MType == 1)
World.MobAttacksCharSkill(this, Target, (uint)DMG, 1320, 2);
else
World.MobAttacksChar(this, Target, 2, (uint)DMG);
}
Target = null;
}
}
else
{
thos are the only 2 i have in my entities.cs, eather of them the right one? lol once again sorry for the questions i am indeed a dumba$$
07/26/2009 21:48 f0am#28
there is moeny drops then it says else and all the rest ropd there
07/26/2009 21:58 roycu#29
Quote:
uint MoneyDrops = 0;

if (Other.ChanceSuccess(20))
{
int DropTimes = 1;
if (Other.ChanceSuccess(15))
{
DropTimes = General.Rand.Next(1, 6);
}
for (int i = 0; i < DropTimes; i++)
{
MoneyDrops = (uint)General.Rand.Next(1, 10);

if (Other.ChanceSuccess(70))
MoneyDrops = (uint)General.Rand.Next(1, 200);
if (Other.ChanceSuccess(60))
MoneyDrops = (uint)General.Rand.Next(30, 500);
if (Other.ChanceSuccess(45))
MoneyDrops = (uint)General.Rand.Next(100, 1000);
if (Other.ChanceSuccess(30))
MoneyDrops = (uint)General.Rand.Next(500, 5000);
if (Other.ChanceSuccess(15))
MoneyDrops = (uint)General.Rand.Next(1000, 15000);

MoneyDrops = MoneyDrops / (136 - (uint)Level) * 10;
if (MoneyDrops < 1)
MoneyDrops = 1;
string Item = "";

if (MoneyDrops < 10)
Item = "1090000-0-0-0-0-0";
else if (MoneyDrops < 100)
Item = "1090010-0-0-0-0-0";
else if (MoneyDrops < 1000)
Item = "1090020-0-0-0-0-0";
else if (MoneyDrops < 3000)
Item = "1091000-0-0-0-0-0";
else if (MoneyDrops < 10000)
Item = "1091010-0-0-0-0-0";
else
Item = "1091020-0-0-0-0-0";

DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
}
else
{

if (Other.ChanceSuccess(100))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
if (Other.ChanceSuccess(1))
{
string Item = "1060100-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
if (Other.ChanceSuccess(0))
{
string Item = "721533-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
if (Other.ChanceSuccess(0))
{
string Item = "721536-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
if (Other.ChanceSuccess(0))
{
string Item = "723038-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
#region DragonBall Drop
if (Other.ChanceSuccess(4))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
#endregion
#region Certain Mob Drop
if (Name == "Pheasant")
{
if (Other.ChanceSuccess(2))
{
string Item = "1088000-0-0-0-0-0";
DroppedItem item = DroppedItems.DropItem(Item, (uint)(PosX - General.Rand.Next(4) + General.Rand.Next(4)), (uint)(PosY - General.Rand.Next(4) + General.Rand.Next(4)), (uint)Map, MoneyDrops);
World.ItemDrops(item);
}
}
#endregion
is that what you mean? :S the bold points are the money and the code you gave to me if thats what you ment it dosent work :(
07/26/2009 22:26 f0am#30
looks like u already added db up there, anway press f5 to debug ><