diff --git a/scripts-test/Main.rb b/scripts-test/Main.rb new file mode 100644 index 0000000..77a3088 --- /dev/null +++ b/scripts-test/Main.rb @@ -0,0 +1,3 @@ +begin + print("YOOOO THIS WORK!") +end diff --git a/scripts-test/_scripts.txt b/scripts-test/_scripts.txt new file mode 100644 index 0000000..bb71259 --- /dev/null +++ b/scripts-test/_scripts.txt @@ -0,0 +1,2 @@ +# Overrides +Main diff --git a/src/main.cpp b/src/main.cpp index 77a9e69..734929c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -66,10 +66,10 @@ static inline const char* glGetStringInt(GLenum name){ } static void printGLInfo(){ - Debug() << "[main.cpp]GL Vendor :" << glGetStringInt(GL_VENDOR); - Debug() << "[main.cpp]GL Renderer :" << glGetStringInt(GL_RENDERER); - Debug() << "[main.cpp]GL Version :" << glGetStringInt(GL_VERSION); - Debug() << "[main.cpp]GLSL Version :" << glGetStringInt(GL_SHADING_LANGUAGE_VERSION); + Debug() << "[main.cpp] GL Vendor :" << glGetStringInt(GL_VENDOR); + Debug() << "[main.cpp] GL Renderer :" << glGetStringInt(GL_RENDERER); + Debug() << "[main.cpp] GL Version :" << glGetStringInt(GL_VERSION); + Debug() << "[main.cpp] GLSL Version :" << glGetStringInt(GL_SHADING_LANGUAGE_VERSION); } int rgssThreadFun(void *userdata){ @@ -217,10 +217,8 @@ int main(int argc, char *argv[]){ SDL_SetHint(SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS, "0"); SDL_SetHint(SDL_HINT_APP_ID, "OneshotSunshine"); SDL_SetHint(SDL_HINT_APP_NAME, "Oneshot: Sunshine"); - //deleted from SDL3 - //SDL_SetHint(SDL_HINT_ACCELEROMETER_AS_JOYSTICK, "0"); - //SDL_SetHint(SDL_HINT_VIDEO_HIGHDPI_DISABLED, "1"); -#if defined(__linux__) + //X11 work on *BSD,Solaris too! +#if defined(__linux__) || defined(BSD) || defined(__sun) SDL_SetHint(SDL_HINT_VIDEO_X11_NET_WM_BYPASS_COMPOSITOR, "0"); #endif diff --git a/src/oneshot.cpp b/src/oneshot.cpp index 3d82c48..73b8bff 100644 --- a/src/oneshot.cpp +++ b/src/oneshot.cpp @@ -22,7 +22,7 @@ #include #include #include -#elif defined __APPLE__ || __linux__ +#elif defined __APPLE__ || __linux__ || BSD #include #include #include @@ -32,15 +32,13 @@ #define OS_OSX #include #else - #define OS_LINUX + #define OS_LINUX || BSD #include #include #include "xdg-user-dir-lookup.h" #endif -#elif defined __FreeBSD__ || __NetBSD__ || __OpenBSD__ - #error "Work in progress:3" #else - #error "Operating system not detected." + #error "Operating system not detected or unsupported." #endif #define DEF_SCREEN_W 640 @@ -85,7 +83,7 @@ struct OneshotPrivate{ }; //OS-SPECIFIC FUNCTIONS -#if defined OS_LINUX +#if defined OS_LINUX || BSD struct linux_DialogData{ // Input int type; @@ -180,6 +178,8 @@ Oneshot::Oneshot(RGSSThreadData &threadData) : p->os = "windows"; #elif defined OS_OSX p->os = "macos"; + #elif defined BSD + p->os = "BSD "; #else p->os = "linux"; #endif