Run this on your custom page & view the source output in your browser:
PHP Code:
var_dump($vbulletin->userinfo);
Off the top of my head I think you are looking for
$vbulletin->userinfo['lastactivity'] and
$vbulletin->userinfo['pmunread'] (and I'm not sure about this one but try
$vbulletin->userinfo['pmread'])
I was just guessing at the above bit but if you run that piece of code you will get a whole list of the data within the variable.