View Single Post
  #1  
Old 09-30-2010, 06:13 AM
khortez khortez is offline
PrototypeX
khortez's Avatar
Join Date: Dec 2008
Posts: 91
khortez will become famous soon enough
onMouseDown() not working, help?

Tried doing:

PHP Code:
function onMouseDown(button){
if(
button == "left")
triggerserver("gui"name"block"temp.xtemp.y);

but it doesn't work when i do it that way. it only works if i keep it the way it is below. someone mind telling how i can fix that? any help appreciated.



PHP Code:
function onActionServerSide(){
  if (
params[0] == "block"
    
temp.putnpc2(params[1], params[2], "");
   
temp.p.join("personal_khortez_block");
  }









//#CLIENTSIDE
function onKeyPressed(codekey){
if(
key == "z"){

this.on = !this.on;

if(
this.on){
settimer(0.05);
player.chat "Blocks on!";
}

else {

player.chat "Blocks off!";
}
  }
    } 
   




function 
onTimeOut(){
temp.int(mousex);
temp.int(mousey);
 
  if (
this.on){ 
    
    
showimg(1"cega_staffblock2-frozenlies0.png"temp.xtemp.y);
    
showtext(2temp.x+2temp.y+0.5"Palatino Linotype""i"player.nick);
    
    
changeimgcolors(11110.5);
    
    if(
leftmousebutton){
    
triggerserver("gui"name"block"temp.xtemp.y);
    }
    
    
setTimer0.05 );
   }
   
   else{ 
    
hideimgs2);
  
}
 } 
Reply With Quote