Rob Janes Posted December 21, 2012 Author Share Posted December 21, 2012 Want to auto pick up loot like in action/adventure games? Walking over an item automatically picks it up if you're eligible for it. Add the following code.1\. In your client, in modGameLogic, find the CheckMovement Sub, Add this code AFTER the 'End Select'```Call CheckForMapItem```2\. In your client, in any module, I added it to modGameLogic, add this code```Public Sub CheckForMapItem()Dim i, X, Y As LongX = GetPlayerX(MyIndex)Y= GetPlayerY(MyIndex)For i = 1 To MAX_MAP_ITEMS If MapItem(i).num > 0 Then If MapItem(i).X = X And MapItem(i).Y = Y Then CheckMapGetItem End If End IfNextEnd Sub```3\. Profit! Link to comment Share on other sites More sharing options...
BugSICK Posted December 21, 2012 Share Posted December 21, 2012 nice. i will add this in your engine. thanks Sir Rob Link to comment Share on other sites More sharing options...
TorenRenne Posted December 21, 2012 Share Posted December 21, 2012 Nice addition!Assuming it is not called or interferes with dropping items? Link to comment Share on other sites More sharing options...
DMF Posted December 21, 2012 Share Posted December 21, 2012 works. nice code thanks and alot of people will like it. ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png) Link to comment Share on other sites More sharing options...
hisherwin Posted December 21, 2012 Share Posted December 21, 2012 Additions:If you want a Auto Loot options do thisAdd a check box at frmMain then call it chkLootFind this line```Call CheckForMapItem```Replace it with```If frmMain.chkLoot.Value > 0 ThenCall CheckForMapItemEnd If```I made this without my VB6 , not tested of course but logic said it will ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png) Link to comment Share on other sites More sharing options...
DMF Posted December 21, 2012 Share Posted December 21, 2012 ???huh wat is ur addon do?? Link to comment Share on other sites More sharing options...
Dr.House Posted December 21, 2012 Share Posted December 21, 2012 > ???huh wat is ur addon do??You can check in item editor if the item to be auto lootable or not lol Link to comment Share on other sites More sharing options...
DMF Posted December 21, 2012 Share Posted December 21, 2012 >| oh then y he say frm main and not item editor?? Link to comment Share on other sites More sharing options...
Growlith1223 Posted December 21, 2012 Share Posted December 21, 2012 Because that chkLoot is a player option, not an Item option. This makes it so if your chkLoot is checked, it will auto loot. Link to comment Share on other sites More sharing options...
DMF Posted December 21, 2012 Share Posted December 21, 2012 >| oh. thanks for clearing this up. 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