35 lines
752 B
C++
35 lines
752 B
C++
// Stepstead — iOS Pedometer plugin (CMPedometer)
|
||
// Godot 4 iOS plugin. Singleton adı: "Pedometer"
|
||
//
|
||
// GDScript sözleşmesi (autoload/pedometer.gd ile eşleşir):
|
||
// bool is_available()
|
||
// void start()
|
||
// void stop()
|
||
// int get_step_count() -> oturum başından beri kümülatif adım
|
||
#ifndef STEPSTEAD_PEDOMETER_H
|
||
#define STEPSTEAD_PEDOMETER_H
|
||
|
||
#include "core/object/class_db.h"
|
||
#include "core/object/object.h"
|
||
|
||
class Pedometer : public Object {
|
||
GDCLASS(Pedometer, Object);
|
||
|
||
static Pedometer *instance;
|
||
|
||
protected:
|
||
static void _bind_methods();
|
||
|
||
public:
|
||
bool is_available();
|
||
void start();
|
||
void stop();
|
||
int get_step_count();
|
||
|
||
static Pedometer *get_singleton();
|
||
|
||
Pedometer();
|
||
~Pedometer();
|
||
};
|
||
|
||
#endif // STEPSTEAD_PEDOMETER_H
|