         let rand: CGFloat = CGFloat(Float(arc4random()) / 0xFFFFFFFF)
         return (rand) * (to - from) + from
     }
-    
-    /*
-     This method checks to see how many bricks are left in the scene by going through all the scene’s children. For each child, it checks whether the child name is equal to BlockCategoryName. If there are no bricks left, the player has won the game and the method returns true.
-     */
-    
-    func isGameWon() -> Bool {
-        let numberOfBricks = 0
-        
-        return numberOfBricks == 0
-    }
-    
 }
 
 extension JDSnackScene

                        {
                            let newPostition = CGPoint(x: NewX, y: NewY)
                            snackBody.position = self.TouchTheWallDetect(input: newPostition)
                            break
                        }
                        //
                        if(abs(snackBody.InstanceDirection.dx) == 1 && abs(snackBody.position.y - turnRound.turnRoundPosition.y) < 0.01) //橫向超越

        var result = input
        if(input.x > self.frame.width)
        {
            let exceedLength:CGFloat = input.x - self.frame.width
            result.x = exceedLength
        }
        else if(input.x < 0)
        {
            let exceedLength:CGFloat = 0 - input.x
            result.x = self.frame.width - exceedLength
        }
        
        if(input.y > self.frame.height)
        {
            let exceedLength:CGFloat = input.y - self.frame.height
            result.y = exceedLength
        }
        else if(input.y < 0)
        {
            let exceedLength:CGFloat = 0 - input.y
            result.y = self.frame.height - exceedLength
        }
        return result
    }
