Thread: Timeout problem
View Single Post
  #2  
Old 03-06-2009, 11:13 PM
LoneAngelIbesu LoneAngelIbesu is offline
master of infinite loops
LoneAngelIbesu's Avatar
Join Date: May 2007
Location: Toldeo, Ohio
Posts: 1,049
LoneAngelIbesu has a spectacular aura aboutLoneAngelIbesu has a spectacular aura about
Send a message via AIM to LoneAngelIbesu
I don't see this.stage being defined anywhere, yet it's in two of your conditional checks. So, I took it out, and the effect is a small up-and-down movement.

PHP Code:
function onTimeout() {
  if (
player.== 2)
    
this.air 2;
  if (
player.== 1)
    
this.air 1;
  if (
this.air == 1)
    
player.+= 0.05;
  else if (
this.air == 2)
    
player.-= 0.05;
  else if (
this.air == && player.0)
    
player.-= 0.05;
  
setTimer(0.05);

__________________
"We are all in the gutter, but some of us are looking at the stars."
— Oscar Wilde, Lady Windermere's Fan
Reply With Quote