<commit_before>import UIKit

class MOptionReformaCrossingLane:MOptionReformaCrossingLaneProtocol
{
    var foes:[MOptionReformaCrossingFoe]
    private(set) var verticalPosition:CGFloat
    private(set) var sceneWidth:CGFloat
    private let deltaVertical:CGFloat
    private var collectable:Bool
    
    init(deltaVertical:CGFloat)
    {
        self.deltaVertical = deltaVertical
        foes = []
        collectable = false
        verticalPosition = 0
        sceneWidth = 0
    }
    
    //MARK: public
    
    func foeInitialPoint(foe:MOptionReformaCrossingFoe) -> CGPoint
    {
        return CGPoint.zero
    }
    
    func foeEndingPoint(foe:MOptionReformaCrossingFoe) -> CGPoint
    {
        return CGPoint.zero
    }
    
    func hasFoeWaiting(sceneSize:CGSize) -> Bool
    {
        return false
    }
    
    final func removeFoe(item:MOptionReformaCrossingFoe)
    {
        var foes:[MOptionReformaCrossingFoe] = []
        
        for foe:MOptionReformaCrossingFoe in self.foes
        {
            if foe !== item
            {
                foes.append(foe)
            }
        }
        
        self.foes = foes
    }
    
    final func stopFoes()
    {
        for foe:MOptionReformaCrossingFoe in foes
        {
            foe.totalStop()
        }
        
        foes = []
    }
    
    final func configureForScene(size:CGSize)
    {
        collectable = true
        
        sceneWidth = size.width
        let sceneHeight_2:CGFloat = size.height / 2.0
        verticalPosition = sceneHeight_2 + deltaVertical
        
        foes = []
    }
    
    final func playerCollectAt(position:CGPoint) -> Bool
    {
        if collectable
        {
            let playerY:CGFloat = position.y
            
            if playerY > verticalPosition
            {
                collectable = false
                
                return true
            }
        }
        
        return false
    }
    
    //MARK: lane protocol
    
    var scaleHorizontal:CGFloat
    {
        get
        {
            return 0
        }
    }
    
    var direction:CGFloat
    {
        get
        {
            return 0
        }
    }
    
    var posibleFoes:[MOptionReformaCrossingFoe.Type]
    {
        get
        {
            return [MOptionReformaCrossingFoeVW.self,
                    MOptionReformaCrossingFoeRuta2.self,
                MOptionReformaCrossingFoeMetrobus.self,
            MOptionReformaCrossingFoePolice.self,
            MOptionReformaCrossingFoeTamales.self,
            MOptionReformaCrossingFoeTaxiPink.self]
        }
    }
}
<commit_msg>added fierro viejo to factory<commit_after>import UIKit

class MOptionReformaCrossingLane:MOptionReformaCrossingLaneProtocol
{
    var foes:[MOptionReformaCrossingFoe]
    private(set) var verticalPosition:CGFloat
    private(set) var sceneWidth:CGFloat
    private let deltaVertical:CGFloat
    private var collectable:Bool
    
    init(deltaVertical:CGFloat)
    {
        self.deltaVertical = deltaVertical
        foes = []
        collectable = false
        verticalPosition = 0
        sceneWidth = 0
    }
    
    //MARK: public
    
    func foeInitialPoint(foe:MOptionReformaCrossingFoe) -> CGPoint
    {
        return CGPoint.zero
    }
    
    func foeEndingPoint(foe:MOptionReformaCrossingFoe) -> CGPoint
    {
        return CGPoint.zero
    }
    
    func hasFoeWaiting(sceneSize:CGSize) -> Bool
    {
        return false
    }
    
    final func removeFoe(item:MOptionReformaCrossingFoe)
    {
        var foes:[MOptionReformaCrossingFoe] = []
        
        for foe:MOptionReformaCrossingFoe in self.foes
        {
            if foe !== item
            {
                foes.append(foe)
            }
        }
        
        self.foes = foes
    }
    
    final func stopFoes()
    {
        for foe:MOptionReformaCrossingFoe in foes
        {
            foe.totalStop()
        }
        
        foes = []
    }
    
    final func configureForScene(size:CGSize)
    {
        collectable = true
        
        sceneWidth = size.width
        let sceneHeight_2:CGFloat = size.height / 2.0
        verticalPosition = sceneHeight_2 + deltaVertical
        
        foes = []
    }
    
    final func playerCollectAt(position:CGPoint) -> Bool
    {
        if collectable
        {
            let playerY:CGFloat = position.y
            
            if playerY > verticalPosition
            {
                collectable = false
                
                return true
            }
        }
        
        return false
    }
    
    //MARK: lane protocol
    
    var scaleHorizontal:CGFloat
    {
        get
        {
            return 0
        }
    }
    
    var direction:CGFloat
    {
        get
        {
            return 0
        }
    }
    
    var posibleFoes:[MOptionReformaCrossingFoe.Type]
    {
        get
        {
            return [MOptionReformaCrossingFoeVW.self,
                    MOptionReformaCrossingFoeRuta2.self,
                MOptionReformaCrossingFoeMetrobus.self,
            MOptionReformaCrossingFoePolice.self,
            MOptionReformaCrossingFoeTamales.self,
            MOptionReformaCrossingFoeTaxiPink.self,
            MOptionReformaCrossingFoeFierroViejo.self]
        }
    }
}

{'fraction_non_alphanumeric': 0.06161406161406161, 'fraction_numerical': 0.003402003402003402, 'mean_word_length': 1.4717421765530125, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2564536', 'n_tokens_mistral': 1641, 'n_tokens_neox': 1606, 'n_words': 255}