diff --git a/modules/summator/summator.cpp b/modules/summator/summator.cpp index 25d0bde821dc..d3bf112482d9 100644 --- a/modules/summator/summator.cpp +++ b/modules/summator/summator.cpp @@ -3,5 +3,17 @@ #include "summator.h" void Summator::add(int p_value) { - + count += p_value; +} + +void Summator::reset() { + count = 0; +} + +int Summator::get_total() const { + return count; +} + +void Summator::_bind_methods() { + ClassDB::bind_method(D_METHOD("add", "value"), &Summator::add) } \ No newline at end of file