Merge branch 'trunk' of github.com:lrre-foss/rnr into trunk

This commit is contained in:
floralrainfall 2023-07-14 18:34:56 -04:00
commit d0a55fbdbb
27 changed files with 267 additions and 90 deletions

3
.gitattributes vendored
View File

@ -1,2 +1 @@
# Ignore GLAD generated API files
glad.* linguist-generated
Content/Ogre/** linguist-vendored

2
.gitignore vendored
View File

@ -12,4 +12,4 @@ _deps
build
Disassembly
.vscode
Ogre.log
*.log

View File

@ -1,6 +1,6 @@
function(create_resources directory output)
file(WRITE ${output} "#include <stdint.h>\n\n")
file(GLOB bins ${directory}/*)
file(GLOB bins "${directory}/*.png") # Add other file types if necessary
foreach(bin ${bins})
string(REGEX MATCH "([^/]+)$" filename ${bin})

View File

@ -13,7 +13,6 @@ set(DEPENDENCIES_DIR ${CMAKE_SOURCE_DIR}/Dependencies)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes -Wno-return-type") # Ignore warnings generated by Luau and Qt
find_package(Boost REQUIRED)
find_package(cglm REQUIRED CONFIG)
find_package(OGRE REQUIRED COMPONENTS Bites CONFIG)
add_subdirectory(Projects)

View File

@ -1,21 +0,0 @@
17:36:32: XMLMeshSerializer reading mesh data from /home/caesium/projects/rbxnu/Content/RNR/fonts/Cube.mesh.xml...
17:36:32: Reading geometry...
17:36:32: Geometry done...
17:36:32: Reading submeshes...
17:36:32: Submeshes done.
17:36:32: Reading mesh names...
17:36:32: Mesh names done.
17:36:32: XMLMeshSerializer import successful.
17:36:32: MeshSerializer writing mesh data to stream /home/caesium/projects/rbxnu/Content/RNR/fonts/Cube.mesh...
17:36:32: File header written.
17:36:32: Writing mesh data...
17:36:32: Writing submesh...
17:36:32: Exporting submesh texture aliases...
17:36:32: Submesh texture aliases exported.
17:36:32: Submesh exported.
17:36:32: Exporting bounds information....
17:36:32: Bounds information exported.
17:36:32: Exporting submesh name table...
17:36:32: Submesh name table exported.
17:36:32: Mesh data exported.
17:36:32: MeshSerializer export successful.

View File

@ -5,8 +5,10 @@ if(COMPILE_PLAYER OR COMPILE_STUDIO)
if(LINUX)
include(/usr/share/cmake/Modules/FindX11.cmake)
endif()
find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets OpenGLWidgets)
set(QT6_LIBRARIES_INCL Qt6::Core Qt6::Gui Qt6::Widgets Qt6::OpenGLWidgets Qt6::GuiPrivate ${X11_X11_LIB})
add_subdirectory(Common)
if(COMPILE_PLAYER)

View File

@ -1,22 +1,16 @@
project(Common)
qt_standard_project_setup()
qt_add_library(Common STATIC
Header/GL/Adorn.hpp
Header/GL/RenderContext.hpp
Header/OgreWidget.hpp
list(APPEND SOURCE
Source/GL/Adorn.cpp
Source/OgreWidget.cpp
)
if(WIN32)
add_custom_command(TARGET Common POST_BUILD
COMMAND ${TOOL_WINDEPLOYQT}
$<TARGET_FILE:Common>
COMMENT "Running windeployqt..."
)
endif()
list(APPEND HEADER
Header/GL/Adorn.hpp
Header/GL/RenderContext.hpp
Header/OgreWidget.hpp
)
qt_standard_project_setup()
qt_add_library(Common STATIC ${SOURCE} ${HEADER})
target_include_directories(Common PUBLIC Header)
target_link_libraries(Common PUBLIC ${QT6_LIBRARIES_INCL} Engine)

View File

@ -8,7 +8,7 @@
#include <OGRE/Ogre.h>
#include <OGRE/RTShaderSystem/OgreShaderGenerator.h>
#include <App/V8/Tree/Instance.hpp>
#include <App/V8/World/World.hpp>>
#include <App/V8/World/World.hpp>
#include <GL/Adorn.hpp>

View File

@ -114,6 +114,7 @@ namespace RNR
Ogre::NameValuePairList options;
options["externalWindowHandle"] = getWindowHandle();
options["FSAA"] = "4";
#if OGRE_PLATFORM == OGRE_PLATFORM_APPLE
options["macAPI"] = "cocoa";
options["macAPICocoaUseNSView"] = "true";

View File

@ -1,23 +1,23 @@
project(Player)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resources/PlayerResources.hpp)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resource/Player.hpp)
set(CMAKE_AUTOMOC ON)
qt_add_executable(Player
${CMAKE_BINARY_DIR}/Resources/PlayerResources.hpp
Header/MainWindow.hpp
list(APPEND SOURCE
Source/main.cpp
Source/MainWindow.cpp
)
add_custom_command(TARGET Player POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy -t $<TARGET_FILE_DIR:Player> $<TARGET_RUNTIME_DLLS:Player>
COMMAND_EXPAND_LISTS
list(APPEND HEADER
${CMAKE_BINARY_DIR}/Resource/Player.hpp
Header/MainWindow.hpp
)
if(WIN32)
list(APPEND HEADER Resource/Windows/Script.rc)
endif()
qt_add_executable(Player ${SOURCE} ${HEADER})
target_include_directories(Player PRIVATE Header)
target_link_libraries(Player PRIVATE Common Engine)

View File

@ -2,6 +2,8 @@
#include <QMainWindow>
#include "Resource/Player.hpp"
class MainWindow : public QMainWindow
{
Q_OBJECT

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -0,0 +1,22 @@
#pragma once
#define VERSION_MAJOR_MINOR_STR "1.0"
#define VERSION_MAJOR_MINOR_PATCH_STR "1.0.0"
#define VERSION_FULL_STR "1.0.0.0"
#define VERSION_RESOURCE 1, 0, 0, 0
#define VERSION_RESOURCE_STR VERSION_FULL_STR "\0"
/*
* These properties are part of VarFileInfo.
* PRODUCT_LANGUAGE is also the resource file's recognizer (but still shares the same value.)
* For more information, please see: https://learn.microsoft.com/en-us/windows/win32/menurc/varfileinfo-block
*/
#define PRODUCT_LANGUAGE 0x0409 // en-US
#define PRODUCT_CHARSET 1200 // Unicode
#define APP_ICON "Icon.ico"
#define APP_NAME "RNR Player\0"
#define APP_DESCRIPTION "RNR's Not Roblox\0"
#define APP_ORGANIZATION "Legacy Roblox Reverse Engineers\0"
#define APP_COPYRIGHT "This program is licensed under the GNU General Public License v3.0.\0"

View File

@ -0,0 +1,49 @@
#include "Information.h"
#if defined(__MINGW64__) || defined(__MINGW32__)
// MinGW-w64, MinGW
#if defined(__has_include) && __has_include(<winres.h>)
#include <winres.h>
#else
#include <afxres.h>
#include <winresrc.h>
#endif
#else
// MSVC, Windows SDK
#include <winres.h>
#endif
IDI_ICON1 ICON APP_ICON
LANGUAGE PRODUCT_LANGUAGE, SUBLANG_DEFAULT
VS_VERSION_INFO VERSIONINFO
FILEVERSION VERSION_RESOURCE
PRODUCTVERSION VERSION_RESOURCE
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", APP_ORGANIZATION
VALUE "FileDescription", APP_DESCRIPTION
VALUE "FileVersion", VERSION_RESOURCE_STR
VALUE "LegalCopyright", APP_COPYRIGHT
VALUE "ProductName", APP_NAME
VALUE "ProductVersion", VERSION_RESOURCE_STR
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", PRODUCT_LANGUAGE, PRODUCT_CHARSET
END
END

View File

@ -1,7 +1,5 @@
#include <MainWindow.hpp>
#include "Resources/PlayerResources.hpp"
MainWindow::MainWindow()
{
QPixmap pixmap = QPixmap();

View File

@ -1,17 +1,13 @@
project(Server)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resource/Server.hpp)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resources/ServerResources.hpp)
list(APPEND SOURCE Source/main.cpp)
list(APPEND HEADER ${CMAKE_BINARY_DIR}/Resource/Server.hpp)
add_executable(Server
${CMAKE_BINARY_DIR}/Resources/ServerResources.hpp
Source/main.cpp
)
if(WIN32)
list(APPEND HEADER Resource/Windows/Script.rc)
endif()
add_custom_command(TARGET Server POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy -t $<TARGET_FILE_DIR:Server> $<TARGET_RUNTIME_DLLS:Server>
COMMAND_EXPAND_LISTS
)
add_executable(Server ${SOURCE} ${HEADER})
target_include_directories(Server PRIVATE Header)
target_link_libraries(Server PRIVATE Engine)

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -0,0 +1,22 @@
#pragma once
#define VERSION_MAJOR_MINOR_STR "1.0"
#define VERSION_MAJOR_MINOR_PATCH_STR "1.0.0"
#define VERSION_FULL_STR "1.0.0.0"
#define VERSION_RESOURCE 1, 0, 0, 0
#define VERSION_RESOURCE_STR VERSION_FULL_STR "\0"
/*
* These properties are part of VarFileInfo.
* PRODUCT_LANGUAGE is also the resource file's recognizer (but still shares the same value.)
* For more information, please see: https://learn.microsoft.com/en-us/windows/win32/menurc/varfileinfo-block
*/
#define PRODUCT_LANGUAGE 0x0409 // en-US
#define PRODUCT_CHARSET 1200 // Unicode
#define APP_ICON "Icon.ico"
#define APP_NAME "RNR Server\0"
#define APP_DESCRIPTION "RNR's Not Roblox\0"
#define APP_ORGANIZATION "Legacy Roblox Reverse Engineers\0"
#define APP_COPYRIGHT "This program is licensed under the GNU General Public License v3.0.\0"

View File

@ -0,0 +1,49 @@
#include "Information.h"
#if defined(__MINGW64__) || defined(__MINGW32__)
// MinGW-w64, MinGW
#if defined(__has_include) && __has_include(<winres.h>)
#include <winres.h>
#else
#include <afxres.h>
#include <winresrc.h>
#endif
#else
// MSVC, Windows SDK
#include <winres.h>
#endif
IDI_ICON1 ICON APP_ICON
LANGUAGE PRODUCT_LANGUAGE, SUBLANG_DEFAULT
VS_VERSION_INFO VERSIONINFO
FILEVERSION VERSION_RESOURCE
PRODUCTVERSION VERSION_RESOURCE
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", APP_ORGANIZATION
VALUE "FileDescription", APP_DESCRIPTION
VALUE "FileVersion", VERSION_RESOURCE_STR
VALUE "LegalCopyright", APP_COPYRIGHT
VALUE "ProductName", APP_NAME
VALUE "ProductVersion", VERSION_RESOURCE_STR
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", PRODUCT_LANGUAGE, PRODUCT_CHARSET
END
END

View File

@ -1,23 +1,23 @@
project(Studio)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resources/StudioResources.hpp)
create_resources(Resource ${CMAKE_BINARY_DIR}/Resource/Studio.hpp)
set(CMAKE_AUTOMOC ON)
qt_add_executable(Studio
${CMAKE_BINARY_DIR}/Resources/StudioResources.hpp
Header/MainWindow.hpp
list(APPEND SOURCE
Source/main.cpp
Source/MainWindow.cpp
)
add_custom_command(TARGET Studio POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy -t $<TARGET_FILE_DIR:Studio> $<TARGET_RUNTIME_DLLS:Studio>
COMMAND_EXPAND_LISTS
list(APPEND HEADER
${CMAKE_BINARY_DIR}/Resource/Studio.hpp
Header/MainWindow.hpp
)
if(WIN32)
list(APPEND HEADER Resource/Windows/Script.rc)
endif()
qt_add_executable(Studio ${SOURCE} ${HEADER})
target_include_directories(Studio PRIVATE Header)
target_link_libraries(Studio PRIVATE Common Engine)

View File

@ -7,9 +7,15 @@
#include <QTimer>
#include <QToolBar>
#include <QMenuBar>
#include <QGridLayout>
#include <QTreeView>
#include <QVariant>
#include <OGRE/Bites/OgreBitesConfigDialog.h>
#include <OgreWidget.hpp>
#include "Resource/Studio.hpp"
class MainWindow : public QMainWindow
{
Q_OBJECT

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -0,0 +1,22 @@
#pragma once
#define VERSION_MAJOR_MINOR_STR "1.0"
#define VERSION_MAJOR_MINOR_PATCH_STR "1.0.0"
#define VERSION_FULL_STR "1.0.0.0"
#define VERSION_RESOURCE 1, 0, 0, 0
#define VERSION_RESOURCE_STR VERSION_FULL_STR "\0"
/*
* These properties are part of VarFileInfo.
* PRODUCT_LANGUAGE is also the resource file's recognizer (but still shares the same value.)
* For more information, please see: https://learn.microsoft.com/en-us/windows/win32/menurc/varfileinfo-block
*/
#define PRODUCT_LANGUAGE 0x0409 // en-US
#define PRODUCT_CHARSET 1200 // Unicode
#define APP_ICON "Icon.ico"
#define APP_NAME "RNR Studio\0"
#define APP_DESCRIPTION "RNR's Not Roblox\0"
#define APP_ORGANIZATION "Legacy Roblox Reverse Engineers\0"
#define APP_COPYRIGHT "This program is licensed under the GNU General Public License v3.0.\0"

View File

@ -0,0 +1,49 @@
#include "Information.h"
#if defined(__MINGW64__) || defined(__MINGW32__)
// MinGW-w64, MinGW
#if defined(__has_include) && __has_include(<winres.h>)
#include <winres.h>
#else
#include <afxres.h>
#include <winresrc.h>
#endif
#else
// MSVC, Windows SDK
#include <winres.h>
#endif
IDI_ICON1 ICON APP_ICON
LANGUAGE PRODUCT_LANGUAGE, SUBLANG_DEFAULT
VS_VERSION_INFO VERSIONINFO
FILEVERSION VERSION_RESOURCE
PRODUCTVERSION VERSION_RESOURCE
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", APP_ORGANIZATION
VALUE "FileDescription", APP_DESCRIPTION
VALUE "FileVersion", VERSION_RESOURCE_STR
VALUE "LegalCopyright", APP_COPYRIGHT
VALUE "ProductName", APP_NAME
VALUE "ProductVersion", VERSION_RESOURCE_STR
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", PRODUCT_LANGUAGE, PRODUCT_CHARSET
END
END

View File

@ -1,11 +1,4 @@
#include <MainWindow.hpp>
#include <QGridLayout>
#include <QTreeView>
#include <QVariant>
#include <OGRE/Bites/OgreBitesConfigDialog.h>
#include "Resources/StudioResources.hpp"
MainWindow::MainWindow()
{

View File

@ -1,6 +1,3 @@
project(Engine)
add_library(Engine STATIC
Header/Helpers/Name.hpp
Header/Helpers/Strings.hpp
@ -38,7 +35,7 @@ add_library(Engine STATIC
)
target_include_directories(Engine PUBLIC ${BOOST_INCLUDE_DIRS} Header/)
target_link_libraries(Engine PUBLIC ${BOOST_LIBRARIES} OgreBites cglm Luau.Analysis Luau.Ast Luau.Compiler Luau.VM)
target_link_libraries(Engine PUBLIC ${BOOST_LIBRARIES} OgreBites Luau.Analysis Luau.Ast Luau.Compiler Luau.VM)
if(WIN32 OR MINGW)
file(COPY ${CMAKE_SOURCE_DIR}/Content/win32_plugins.cfg DESTINATION ${CMAKE_BINARY_DIR})

View File

@ -2,8 +2,6 @@
#include <string>
#include <cglm/cglm.h>
#include <Rendering/TextureProxyBase.hpp>
namespace RNR