Skip to content
This repository has been archived by the owner on Apr 28, 2024. It is now read-only.

Commit

Permalink
Merge pull request #3 from spectreseven1138/re
Browse files Browse the repository at this point in the history
RE
  • Loading branch information
toasterofbread authored Aug 11, 2022
2 parents f1a30f5 + cf117fb commit db787c4
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions engine/compiler_settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

/* Available platforms */

#define PLATFORM_RAYLIB 2
#define PLATFORM_VITA 3
#define PLATFORM_VITA 2
#define PLATFORM_RAYLIB 3

/* Platform in use */

Expand Down
8 changes: 4 additions & 4 deletions engine/src/common/input.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ bool Input::isButtonPressed(GamepadButton button) {
bool Input::isButtonPressed(MouseButton button) {
switch (button) {
case MouseButton::MOUSE_WHEEL_UP:
return GetMouseWheelMove() == 1.0f;
return GetMouseWheelMove() >= 1.0f;
case MouseButton::MOUSE_WHEEL_DOWN:
return GetMouseWheelMove() == -1.0f;
return GetMouseWheelMove() <= -1.0f;
default:
return IsMouseButtonDown(button);
}
Expand All @@ -36,9 +36,9 @@ bool Input::isButtonJustPressed(GamepadButton button) {
bool Input::isButtonJustPressed(MouseButton button) {
switch (button) {
case MouseButton::MOUSE_WHEEL_UP:
return GetMouseWheelMove() == 1.0f;
return GetMouseWheelMove() >= 1.0f;
case MouseButton::MOUSE_WHEEL_DOWN:
return GetMouseWheelMove() == -1.0f;
return GetMouseWheelMove() <= -1.0f;
default:
return IsMouseButtonPressed(button);
}
Expand Down
2 changes: 1 addition & 1 deletion engine/src/common/quaternion.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "common/vector3.h"
#include "raylib/raymath.h"

#include <json.hpp>
#include <nlohmann/json.hpp>
#include "common/raylib.h"
#include <string>
using namespace std;
Expand Down
2 changes: 1 addition & 1 deletion engine/src/common/vector2.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "engine/compiler_settings.h"

#include <json.hpp>
#include <nlohmann/json.hpp>
#include "common/raylib.h"
#include <box2d/box2d.h>
#include <string>
Expand Down
2 changes: 1 addition & 1 deletion engine/src/common/vector3.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "common/vector2.h"

#include <raylib/raymath.h>
#include <json.hpp>
#include <nlohmann/json.hpp>
#include "common/raylib.h"
#include <box2d/box2d.h>
#include <string>
Expand Down
2 changes: 1 addition & 1 deletion engine/src/core/os.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <any>
using namespace std;

#include <json.hpp>
#include <nlohmann/json.hpp>
using json = nlohmann::json;

// Forward declarations
Expand Down
2 changes: 1 addition & 1 deletion engine/src/core/resource/sprite_animation.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "sprite_animation.h"

#include <unordered_map>
#include <json.hpp>
#include <nlohmann/json.hpp>
using json = nlohmann::json;
using namespace std;

Expand Down
2 changes: 1 addition & 1 deletion engine/src/core/resource/sprite_animation.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#include <memory>
#include <json.hpp>
#include <nlohmann/json.hpp>
using json = nlohmann::json;

#include "engine/src/engine.h"
Expand Down
2 changes: 1 addition & 1 deletion engine/src/node/types/animated_sprite.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "animated_sprite.h"

#include <memory>
#include <json.hpp>
#include <nlohmann/json.hpp>
using json = nlohmann::json;

#include "common/utils.h"
Expand Down
4 changes: 2 additions & 2 deletions engine/src/platform/SConscript
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ from spectre7 import utils
Import("env")

env.Replace(
CPPPATH = [".", env.ENGINE_SRC, join(env.ENGINE_SRC, "platform", env.PLATFORM_NAME), "include"],
CCFLAGS = ["-std=c++17", "-g", "-fpermissive", "-Wundef", "-fdiagnostics-color=always", f"-DGIT_COMMIT_HASH='\"{env.getGitHash()}\"'", "-Linclude/lib/vita", "-Wl,-rpath include/lib/vita", "-lbox2d"],
CPPPATH = [".", env.ENGINE_SRC, join(env.ENGINE_SRC, "platform", env.PLATFORM_NAME), "include", "include/bullet"],
CCFLAGS = ["-std=c++17", "-g", "-fpermissive", "-fdiagnostics-color=always", f"-DGIT_COMMIT_HASH='\"{env.getGitHash()}\"'", "-Linclude/lib/vita", "-Wl,-rpath include/lib/vita", "-lbox2d"],
LINKFLAGS = ["-g"],
LIBPATH = [env.LIB_DIR],
LIBS = [
Expand Down
2 changes: 1 addition & 1 deletion project/src/nodes/world.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

#include "common/raylib.h"
#include <btBulletCollisionCommon.h>
#include <json.hpp>
#include <nlohmann/json.hpp>
using json = nlohmann::json;

World* World::singleton = NULL;
Expand Down

0 comments on commit db787c4

Please sign in to comment.