PenUltima Online

It is currently Sat Aug 30, 2008 9:08 am

All times are UTC - 8 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Obtaining Client Information
PostPosted: Wed Feb 13, 2008 6:23 am 
Offline

Joined: Wed Feb 13, 2008 6:19 am
Posts: 1
I wish to know, wich client information i can get with pol, like version, hex , or whatever i can get, and how i can those informations. Could someone help me out ?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 13, 2008 3:07 pm 
Offline

Joined: Sat Feb 04, 2006 6:26 pm
Posts: 539
I use the .clientversion to test to see whether the player is using a pre-v5 client. In this instance it's to send a cliloc instead of normal SendSysMessage.

Code:
if ( CInt(character.clientversion[1, 1]) < 5 )
   SendSysMessage(character, "Cancelled");
else
   SendSysMessageCL(character, CL_CANCELLED);
endif


All I am doing is getting the client version string and finding the first character in the string, then turning it into an integer. In most cases all I want is to know if it's a v2 client, or a v4 client etc.

Alternatively, if you wanted to know the exact client version, skip all my string manipulation and just use:
var version := character.clientversion;
That might return a string like 5.0.9.1

If you want even more information, try .clientinfo which is client operating system information.
See the core-changes.txt for the information that returns.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subice by phpBBservice.nl