Skip to content

Commit

Permalink
Merge pull request #24 from Archie-osu/beta
Browse files Browse the repository at this point in the history
Merge 0.0.7-rc2
  • Loading branch information
Archie-osu authored Oct 9, 2021
2 parents 969c1d9 + 941a447 commit 6221070
Show file tree
Hide file tree
Showing 29 changed files with 2,801 additions and 196 deletions.
6 changes: 4 additions & 2 deletions ExamplePlugin/ExamplePlugin.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>ClangCL</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>ClangCL</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
Expand Down Expand Up @@ -95,6 +95,7 @@
<ConformanceMode>true</ConformanceMode>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
<LanguageStandard>stdcpp17</LanguageStandard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
Expand All @@ -113,6 +114,7 @@
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<LanguageStandard>stdcpp17</LanguageStandard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
Expand Down
9 changes: 9 additions & 0 deletions ExamplePlugin/Src/Hello World/SDK/Enums/Enums.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,23 @@ enum Color : int
{
CLR_BLACK = 0,
CLR_DARKBLUE = 1,
CLR_MATRIXGREEN = 2,
CLR_AQUA = 3,
CLR_RED = 4,
CLR_PURPLE = 5,
CLR_GOLD = 6,
CLR_DEFAULT = 7,
CLR_GRAY = 8,
CLR_BLUE = 9,
CLR_GREEN = 10,
CLR_LIGHTBLUE = 11,
CLR_TANGERINE = 12,
CLR_PINK = 13,
CLR_YELLOW = 14,
CLR_WHITE = 15
};

enum EOpcode
{
// todo
};
2 changes: 1 addition & 1 deletion ExamplePlugin/Src/Hello World/SDK/FwdDecls/FwdDecls.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ typedef bool (*FNCodeExecute)(YYObjectBase* Self, YYObjectBase* Other, CCode* co
// Macros

#define WIN32_LEAN_AND_MEAN 1
#define YYSDK_VERSION "0.0.7-rc1" // YYToolkit version - don't change this!
#define YYSDK_VERSION "0.0.7-rc2" // YYToolkit version - don't change this!
#define YYTK_MAGIC 'TFSI'

// Macros, but complicated
Expand Down
6 changes: 5 additions & 1 deletion ExamplePlugin/Src/Hello World/SDK/Plugins/Plugins.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ using FNPluginEntry = YYTKStatus(*)(YYTKPlugin* pPlugin);
using FNPluginUnload = YYTKStatus(*)(YYTKPlugin* pPlugin);
using FNTextRenderCallback = void(*)(float& x, float& y, const char*& str, int& linesep, int& linewidth);

#pragma pack(push, 1)

struct YYTKPlugin
{
FNPluginEntry PluginEntry; // Pointer to the entry function - set by the core.
Expand All @@ -41,4 +43,6 @@ struct YYTKPlugin
if (PluginStart) return reinterpret_cast<T>(GetProcAddress(reinterpret_cast<HMODULE>(PluginStart), Name));
return nullptr;
}
};
};

#pragma pack(pop)
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,5 @@ struct APIVars_t
void* MainModule = nullptr; // A pointer to the core module (can be casted to an HMODULE)
void* RenderView = nullptr; // A pointer to an ID3D11RenderTargetView. Is nullptr in DX9!
void* DeviceContext = nullptr; // A pointer to a D3D11DeviceContext object. Is nullptr in DX9!
void* pSwapChain = nullptr; // A pointer to a swapchain object - is nullptr in DX9!
};
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ YYRValue::YYRValue(const bool& Value) noexcept(true)
{
this->Kind = VALUE_BOOL;
this->Flags = 0;
this->I32 = Value; // A bool is really just a 0 or a 1, so I can freely cast it to an integer.
this->Real = static_cast<double>(Value); // A bool is really just a 0 or a 1, so I can freely cast it to an integer.
}

YYRValue::YYRValue(const long long& Value) noexcept(true)
Expand Down
4 changes: 3 additions & 1 deletion ExamplePlugin/Src/Hello World/dllmain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ YYTKStatus PluginEventHandler(YYTKPlugin* pPlugin, YYTKEventBase* pEvent)
// Go To Room port
if (GetAsyncKeyState(VK_F3) & 1)
{
YYRValue Result = EasyGMLCall(pPlugin, "get_integer", { "Go to room (ported by Archie from UMT to YYToolkit\nEnter the room ID you wish to teleport to.", 11.0 });
YYRValue Result = EasyGMLCall(pPlugin, "get_integer", { "Go to room (ported by Archie from UMT to YYToolkit).\nEnter the room ID you wish to teleport to.", 11.0 });

EasyGMLCall(pPlugin, "room_goto", { Result });
}
Expand Down Expand Up @@ -139,6 +139,8 @@ DllExport YYTKStatus PluginUnload(YYTKPlugin* pPlugin)
Script->s_code->i_pVM = poscr_Dogcheck;
}

EasyGMLCall(pPlugin, "variable_global_set", { "debug", 0.0 });

return YYTK_OK;
}

Expand Down
115 changes: 28 additions & 87 deletions Launcher/Form1.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 6221070

Please sign in to comment.