Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Auto Loot (Walk Over Item to Loot)


Rob Janes
 Share

Recommended Posts

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 Long

X = 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 If

Next

End Sub

```

3\. Profit!
Link to comment
Share on other sites

Additions:

If you want a Auto Loot options do this

Add a check box at frmMain then call it chkLoot

Find this line

```

Call CheckForMapItem

```

Replace it with

```

If frmMain.chkLoot.Value > 0 Then

Call CheckForMapItem

End 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

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...