<commit_before>//
//  mcbAccelerometerParallaxNode.h
//  SoundSurfer
//
//  Created by <NAME> on 10/16/13.
//
//

#ifndef __SoundSurfer__mcbAccelerometerParallaxNode__
#define __SoundSurfer__mcbAccelerometerParallaxNode__

#include "cocos2d.h"
#include "mcbAccelerometer.h"

namespace mcb{namespace PlatformSupport{
    class AccelerometerParallaxNode : public cocos2d::CCNode, public AccelerometerListener{
        typedef cocos2d::CCNode super;
        cocos2d::CCPoint _realPosition;
        cocos2d::CCPoint _offset={0.f,0.f};
        
        cocos2d::CCPoint _multiplier={0.f,0.f};
        float _filteringFactor=.9f;
        
        cocos2d::CCPoint _accelerationOffset={0.f,0.f};
        
        struct{
            float x=0.f;
            float y=0.f;
        }_prevAccel;
    public:
        CREATE_FUNC(AccelerometerParallaxNode);
        
        void setMultiplier(const cocos2d::CCPoint & multiplier){_multiplier=multiplier;}
        const cocos2d::CCPoint & multiplier(){return _multiplier;}
        
        void setFilteringFactor(const float filteringFactor){_filteringFactor=filteringFactor;}
        float filteringFactor(){return _filteringFactor;}
        
        void setAccelerationOffset(const cocos2d::CCPoint & accelerationOffset){_accelerationOffset=accelerationOffset;}
        const cocos2d::CCPoint & accelerationOffset(){return _accelerationOffset;}
        
        
        virtual void setPosition(const cocos2d::CCPoint & pos);
        virtual const cocos2d::CCPoint & getPosition() override;
    protected:
        virtual void onEnter() override;
        virtual void onExit() override;
    };
}}
#endif /* defined(__SoundSurfer__mcbAccelerometerParallaxNode__) */
<commit_msg>conditional init for older cocoas version<commit_after>//
//  mcbAccelerometerParallaxNode.h
//  SoundSurfer
//
//  Created by <NAME> on 10/16/13.
//
//

#ifndef __SoundSurfer__mcbAccelerometerParallaxNode__
#define __SoundSurfer__mcbAccelerometerParallaxNode__

#include "cocos2d.h"
#include "mcbAccelerometer.h"

namespace mcb{namespace PlatformSupport{
    class AccelerometerParallaxNode : public cocos2d::CCNode, public AccelerometerListener{
        typedef cocos2d::CCNode super;
        cocos2d::CCPoint _realPosition;
        cocos2d::CCPoint _offset={0.f,0.f};
        
        cocos2d::CCPoint _multiplier={0.f,0.f};
        float _filteringFactor=.9f;
        
        cocos2d::CCPoint _accelerationOffset={0.f,0.f};
        
        struct{
            float x=0.f;
            float y=0.f;
        }_prevAccel;
    public:
        CREATE_FUNC(AccelerometerParallaxNode);
#if COCOS2D_VERSION <= 0x00020003
        virtual bool init(){return true;}
#endif
        
        void setMultiplier(const cocos2d::CCPoint & multiplier){_multiplier=multiplier;}
        const cocos2d::CCPoint & multiplier(){return _multiplier;}
        
        void setFilteringFactor(const float filteringFactor){_filteringFactor=filteringFactor;}
        float filteringFactor(){return _filteringFactor;}
        
        void setAccelerationOffset(const cocos2d::CCPoint & accelerationOffset){_accelerationOffset=accelerationOffset;}
        const cocos2d::CCPoint & accelerationOffset(){return _accelerationOffset;}
        
        
        virtual void setPosition(const cocos2d::CCPoint & pos);
        virtual const cocos2d::CCPoint & getPosition() override;
    protected:
        virtual void onEnter() override;
        virtual void onExit() override;
    };
}}
#endif /* defined(__SoundSurfer__mcbAccelerometerParallaxNode__) */

{'fraction_non_alphanumeric': 0.0949563257255565, 'fraction_numerical': 0.018596787827557058, 'mean_word_length': 3.231227651966627, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 5, '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': '2973593', 'n_tokens_mistral': 1129, 'n_tokens_neox': 1083, 'n_words': 193}