Jump to content
Sign in to follow this  

_InGamePing UDF

Recommended Posts


I saw some people on edgeofnowhere asking on how to read d2 ping. So I decided to write a function.

;By Joke758
#include <memory.au3>

; This is an example
MsgBox ( 0, "By Joke758", "Ping in game: " & _InGamePing() )

Func _InGamePing()
  ;By Joke758
Local $pid = ""
If ProcessExists ( "Diablo II.exe" ) Then
   $pid = ProcessExists ( "Diablo II.exe" )

If ProcessExists ( "D2Loader-1.11b.exe" ) Then
   $pid = ProcessExists ( "D2Loader-1.11b.exe" )

If $pid = "" Then
   Return 0
   SetError ( 1 )
  ;Can't find open diablo process

$open = _MemOpen ( $pid )
$read = _MemRead ( $open, 0x6FBCA2A4, 4 )
$hping = StringRight( hex($read[3]), 2 ) & StringRight( hex($read[2]), 2 ) & StringRight ( hex($read[1]), 2 )  & StringRight ( hex($read[0]), 2 )
$ping = dec ( $hping )
_MemClose ( $open )
Return $ping

require memory.au3 ( by w0uter )


[u]My Programs:[/u]Word Search Creator - Make your own Word SearchShortHand - Hide a secret message in a jpg fileHex Editor - Edit your Binary fileIncrease file size - Increase the size of any filesArt Generator - A program that generate random picture[u]My Functions:[/u]16-Bits Hash - My Hash function similar to MD5Probabilities - My probabilities function (factorial, permuation, combination)_GetDate() - Convert a date to a day of the week_Base(), _Dec() - Convert a number in any base (bin, oct, hex, dec). Create your own!

Share this post

Link to post
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
Sign in to follow this