07-11-2008, 05:22 AM
Sweet!
Got it working
Thanks alot genusis!
heres what I came up with:
Works great now
Got it working

heres what I came up with:
Code:
' Check for an npc
For i = MAX_MAP_NPCS To 1 Step -1
If MapNpc(GetPlayerMap(index), i).Num > 0 Then
If MapNpc(GetPlayerMap(index), i).x = x And MapNpc(GetPlayerMap(index), i).y = y Then
' Change target
Player(index).Target = i
Player(index).TargetType = TARGET_TYPE_NPC
SendTarget index
If Mid(Trim(Npc(MapNpc(GetPlayerMap(index), i).Num).Name), 0, 1) = "a" Then
Call PlayerMsg(index, "Your target is now a " & Trim(Npc(MapNpc(GetPlayerMap(index), i).Num).Name) & ".", Yellow)
End If
Exit Sub
End If
End If
Next i
Works great now
