Skip to content

Commit

Permalink
reverted changes
Browse files Browse the repository at this point in the history
  • Loading branch information
catriverr committed Nov 9, 2024
1 parent f96008a commit 188768c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 2 additions & 4 deletions lib/bin/gmeng.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@
#include <limits.h>
#endif

#define sleep std::this_thread::sleep_for
#define ms std::chrono::milliseconds


#define time_rn std::chrono::system_clock::now().time_since_epoch()
Expand Down Expand Up @@ -927,15 +925,15 @@ static void patch_argv_global(int argc, char* argv[]) {
#if _WIN32 == false
#include "utils/network.cpp"
#ifndef GMENG_NO_CURSES
/// for github build workflow
#include "types/interface.h"
#include "utils/interface.cpp"
/// for github build workflow
#endif
#if GMENG_SDL
#include "types/window.h"
#include "utils/window.cpp"
#endif
#endif
#endif
#include "utils/util.cpp"
namespace g = Gmeng;
namespace gm = Gmeng;
Expand Down
2 changes: 2 additions & 0 deletions lib/bin/utils/interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
#include <unistd.h>
#include <sys/ioctl.h>

#define sleep std::this_thread::sleep_for
#define ms std::chrono::milliseconds

#ifndef BUTTON5_PRESSED
#define BUTTON5_PRESSED true
Expand Down
2 changes: 1 addition & 1 deletion tests/event_loop.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ int main(int argc, char** argv) {
prev_color = color;
renderscale = get_renderscale(*level);
ev.call_event(FIXED_UPDATE, Gmeng::NO_EVENT_INFO);
sleep(ms( std::max(cfg.model_positions["CAKE_INTERACT_TIMES"].x, cfg.model_positions["CAKE_INTERACT_TIMES"].y - (int)(GET_TIME()-tim)) ));
std::this_thread::sleep_for(std::chrono::milliseconds( std::max(cfg.model_positions["CAKE_INTERACT_TIMES"].x, cfg.model_positions["CAKE_INTERACT_TIMES"].y - (int)(GET_TIME()-tim)) ));
};
texture_replace_color(level->base.lvl_template, prev_color, BLUE);
};
Expand Down

0 comments on commit 188768c

Please sign in to comment.