[Req]Monster Drop Tutorial...

Submit your code requests, and if you are good at coding come help others with their requests.
Post Reply
ADDKiD
<3 bd long time
Posts: 967
Joined: Tue Jul 12, 2005 8:07 pm
Location: Washington, USA
Contact:

Post by ADDKiD »

Ok, so basically, the name says it all, I need a tutorial on how to change what drops. I was told by Jensen, its Server side, if so, under what .cpp or .h? And what does it look like, because I've had one hell of a time searching for it..
laizkloom
Regular
Posts: 78
Joined: Sun Feb 27, 2005 8:41 am

Post by laizkloom »

in game.ccp
write in find Slime.
Search untill you find something like this :

case 1: // Slime, Giant-Ant, Amphis, Rabbit, Cat
switch (iDice(1,3)) {
case 1: iItemID = 1; break; // Dagger
case 2: iItemID = 8; break; // ShortSword
case 3: iItemID = 59; break; // LightAxe
}
break;

and there you go.

and if you add there more cases then your dices will change.
example if you want to add 2 more cases then you're dice will be (iDice(1,5))
ADDKiD
<3 bd long time
Posts: 967
Joined: Tue Jul 12, 2005 8:07 pm
Location: Washington, USA
Contact:

Post by ADDKiD »

Thanks for your quickness, I was getting impatient. I want to get my server setup right...


case 1: // Slime, Giant-Ant, Amphis, Rabbit, Cat
switch (iDice(1,3)) {
case 1: iItemID = 1; break; // Dagger
case 2: iItemID = 8; break; // ShortSword
case 3: iItemID = 59; break; // LightAxe
}
break;
So, if I added say 6 more it'd look like this...

case 1: iItemID = 1; break; // Dagger
case 2: iItemID = 8; break; // ShortSword
case 3: iItemID = 59; break; // LightAxe
case 4: iItemID = (#); break; // (Item)
case 5: iItemID = (#); break; // (Item)
case 6: iItemID = (#); break; // (Item)
case 7: iItemID = (#); break; // (Item)
case 8: iItemID = (#); break; // (Item)
case 9: iItemID = (#); break; // (Item)
laizkloom
Regular
Posts: 78
Joined: Sun Feb 27, 2005 8:41 am

Post by laizkloom »

Yes and dice is


switch (iDice(1,9))
1+12
Member
Posts: 173
Joined: Sat Feb 04, 2006 5:05 pm

Post by 1+12 »

It's actually very simple, but If you still don't understand I suggest using Drajwar's XML based Drop List

Its very useful when you don't got access to sources :P
Getting link for it one sec

<a href='index.php?showtopic=6660' target='_blank'>index.php?showtopic=6660</a>
ADDKiD
&lt;3 bd long time
Posts: 967
Joined: Tue Jul 12, 2005 8:07 pm
Location: Washington, USA
Contact:

Post by ADDKiD »

Thanks alot. I think I might try both. I'm thinking about releasing server files with Angels + Crafting working. But I think that'd bring back more noob servers and such. Don't want that now... Max lvl 519/600 gayness...
Post Reply