View Single Post
  #5  
Old 07-05-2009, 03:40 AM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
Is this the effect you're looking for..?

PHP Code:
//#CLIENTSIDE

function onCreated() {
  
with (findimg(200)) {
    
image = "block.png";
    
x = player.x;
    
y = player.y;
    
this.origx = x;
    
this.origy = y;
  } 
  
setTimer(0.05);
}

function 
onTimeout() {
  
onAdjustZoom();
  
setTimer(0.05);
}

function 
onAdjustZoom() {
  
with (findimg(200)) {
    
zoom = 1 + cos(thiso.angle) * 0.5;
    
y = this.origy - (getimgheight(image) / (layer >= 4 ? 2 : 32)) * zoom;
  }
  
this.angle += pi / 32;
} 
I just used the cos to zoom the image in and out to test it.
__________________
Quote:

Last edited by fowlplay4; 07-05-2009 at 04:02 AM..
Reply With Quote