View Single Post
  #1  
Old 07-12-2009, 07:48 AM
Angel_Light Angel_Light is offline
Varia Developer
Angel_Light's Avatar
Join Date: Nov 2005
Location: Knoxville, TN
Posts: 1,684
Angel_Light is on a distinguished road
Send a message via AIM to Angel_Light Send a message via MSN to Angel_Light
help with openexternalpm()

ok, so I'm just working with some stuff and I try to get a pm window open when a player just double clicks another, here's what I got:

PHP Code:
//#CLIENTSIDE

//...script...

function onMouseDown()
{

  if ( 
params0] == "double")
  {

    
this.pID getPlayerIDmousexmousey);
    
    if ( 
this.pID != -&& this.pID != player.id)
    {

        
playersthis.pID].openexternalpmfalse);

    }
  }
}

function 
getPlayerIDtemp.mxtemp.my)
{

  for ( 
temp.0allplayerscount++)
  {
  
    if ( 
mx in playersp].xplayersp].2|  &&
         
my in playersp].yplayersp].3|)
      return 
playersp].id;

  }
  
  return -
1;

From what I can tell it should work, but when I double click nothing happens at all. What am I doing wrong?
__________________
Deep into the Darkness peering...
Reply With Quote