minor fixes

This commit is contained in:
CocoSimone
2022-12-12 02:48:07 +01:00
parent cfd4166d5a
commit 1b743b4359
4 changed files with 3 additions and 4 deletions

View File

@@ -5,7 +5,6 @@
#include <nlohmann/json.hpp> #include <nlohmann/json.hpp>
#include <filesystem> #include <filesystem>
#include <SDL.h> #include <SDL.h>
#include <SDL_vulkan.h>
VkInstance instance{}; VkInstance instance{};
using json = nlohmann::json; using json = nlohmann::json;

View File

@@ -15,7 +15,7 @@ struct Window {
[[nodiscard]] bool gotClosed(SDL_Event event); [[nodiscard]] bool gotClosed(SDL_Event event);
ImFont *uiFont{}, *codeFont{}; ImFont *uiFont{}, *codeFont{};
u32 windowID{}; u32 windowID{};
float volumeL = 0.1, volumeR = 0.1; float volumeL = 0.01, volumeR = 0.01;
void LoadROM(n64::Core& core, const std::string& path); void LoadROM(n64::Core& core, const std::string& path);
private: private:
bool lockVolume = true; bool lockVolume = true;

View File

@@ -20,7 +20,7 @@ void Scheduler::enqueueAbsolute(const Event& event) {
void Scheduler::tick(u64 t, n64::Mem& mem, n64::Registers& regs) { void Scheduler::tick(u64 t, n64::Mem& mem, n64::Registers& regs) {
ticks += t; ticks += t;
if(ticks >= events.top().time) { while(ticks >= events.top().time) {
events.top().event_cb(mem, regs); events.top().event_cb(mem, regs);
events.pop(); events.pop();
} }

View File

@@ -21,7 +21,7 @@ enum MessageType : u8 {
template <MessageType messageType = Info, typename ...Args> template <MessageType messageType = Info, typename ...Args>
constexpr void print(const std::string& fmt, Args... args) { constexpr void print(const std::string& fmt, Args... args) {
#ifndef __WIN32 #ifndef _WIN32
if constexpr(messageType == Error) { if constexpr(messageType == Error) {
fmt::print(fmt::emphasis::bold | fg(fmt::color::red), fmt, args...); fmt::print(fmt::emphasis::bold | fg(fmt::color::red), fmt, args...);
exit(-1); exit(-1);