McCull96 Posted January 13, 2011 Author Share Posted January 13, 2011 Open the server and go to mod combat and find:```' Now set HP to 0 so we know to actually kill them in the server loop```Above that add:```'Drop the goods if they get it n = Int(Rnd * Npc(npcNum).DropChance) + 1 If n = 1 Then Call SpawnItem(Npc(npcNum).DropItem, Npc(npcNum).DropItemValue, mapNum, MapNpc(mapNum).Npc(mapNpcNum).x, MapNpc(mapNum).Npc(mapNpcNum).y) End If``` Link to comment Share on other sites More sharing options...
Aramyth Posted January 13, 2011 Share Posted January 13, 2011 I found 2 small mistakes in your code mate. The correct code for this would be:``` 'Drop the goods if they get it n = Int(Rnd * Npc(npcNum).DropChance) + 1 If n = 1 Then Call SpawnItem(Npc(npcNum).DropItem, Npc(npcNum).DropItemValue, mapNum, MapNpc(mapNum).Npc(mapNpcNum).x, MapNpc(mapNum).Npc(mapNpcNum).y) End If```Regards Aramyth. Link to comment Share on other sites More sharing options...
coffzor Posted January 13, 2011 Share Posted January 13, 2011 Thanks, Works great, update with the fix underneath your topic post.**Confirmed and WORKS!** Link to comment Share on other sites More sharing options...
McCull96 Posted January 13, 2011 Author Share Posted January 13, 2011 @Aramyth: I didn't notice those mistakes Ill modify it where it's correct Link to comment Share on other sites More sharing options...
igloo9 Posted January 14, 2011 Share Posted January 14, 2011 This isn't working for me. :/ I added that code, saved the file, deleted the NPCs, and restarted the server. NPC's still don't drop. Link to comment Share on other sites More sharing options...
DshWinchester Posted January 14, 2011 Share Posted January 14, 2011 put the chance1 to 1I think you put 100..then its 1 on 100 of chance to drop that item Link to comment Share on other sites More sharing options...
igloo9 Posted January 14, 2011 Share Posted January 14, 2011 @DishWasher:> put the chance> > 1 to 1> > I think you put 100..> then its 1 on 100 of chance to drop that itemI did put 1 to 1\. Still nothing. Link to comment Share on other sites More sharing options...
DshWinchester Posted January 14, 2011 Share Posted January 14, 2011 check if you put in the right place![](http://img257.imageshack.us/img257/9223/screenhunter01jan140646.png) Link to comment Share on other sites More sharing options...
Aramyth Posted January 14, 2011 Share Posted January 14, 2011 DishWasher is right. The code works perfectly fine. If it doesn't, you're doing something wrong.Aramyth. Link to comment Share on other sites More sharing options...
Guest Posted January 14, 2011 Share Posted January 14, 2011 I cant find the code. Link to comment Share on other sites More sharing options...
WhoKnowz Posted January 14, 2011 Share Posted January 14, 2011 @Raiko:> I cant find the code.Try searching for this```' Now set HP to 0 so we know to actually kill them in the server loop```The original post actually is missing the space between the ' and Now. Hope this helps. Link to comment Share on other sites More sharing options...
Guest Posted January 15, 2011 Share Posted January 15, 2011 i did.I cant find it. Link to comment Share on other sites More sharing options...
Displaced Posted January 15, 2011 Share Posted January 15, 2011 modCombat.bas -> Sub PlayerAttackNpc Link to comment Share on other sites More sharing options...
Guest Posted January 15, 2011 Share Posted January 15, 2011 I dont have Combat.bas 0.0.Edit: Is it normal to have XMAS but dont have Combat.bas. Link to comment Share on other sites More sharing options...
pankaka Posted January 15, 2011 Share Posted January 15, 2011 Here's a tutorial.![](http://i54.tinypic.com/ayrqbo.png)This script works perfectly, thanks alot! Link to comment Share on other sites More sharing options...
Guest Posted January 15, 2011 Share Posted January 15, 2011 Thank you fo your unhelpful tutorial i know how to do all that but i sayd that i dont have Combat.bas So can someone give it to me. Link to comment Share on other sites More sharing options...
Displaced Posted January 15, 2011 Share Posted January 15, 2011 Are you sure that you looked in server src directory? Otherwise try redownload EOX & look again. There is a modCombat.bas ! Link to comment Share on other sites More sharing options...
Guest Posted January 15, 2011 Share Posted January 15, 2011 I redownload it and now i have it.Ty. Link to comment Share on other sites More sharing options...
MCADAMS Posted January 16, 2011 Share Posted January 16, 2011 Works like a charm. Thank you very much ^^ Link to comment Share on other sites More sharing options...
Guest Posted January 27, 2011 Share Posted January 27, 2011 WOOT! Worked perfectly. Thanks for the share. Link to comment Share on other sites More sharing options...
dthnote801 Posted January 28, 2011 Share Posted January 28, 2011 @Tarou:> This isn't working for me. :/ I added that code, saved the file, deleted the NPCs, and restarted the server. NPC's still don't drop.I got it tarou lol sending zeph the files. :P I'll explain to you in-game if you need me to Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now