TableFlipGod
Bronze Coder
So currently I have a project that wraps around this open source program : Here.
And I want my form radio button to set the cap to 30 fps or 60 fps. There is a config type thing in the code shown here
[CODE title="Code" highlight="34-38, 8-20"]#include <d3d11.h>
#pragma comment(lib, "d3d11.lib")
#include "sigscan.h"
#include "../injector/mapping.h"
#pragma pack(push, 1)
extern struct SettingsIPC
{
bool vsync_enabled;
double fps_cap;
struct
{
int scan_result;
void *scheduler;
int sfd_offset;
int present_count;
} debug;
};
#pragma pack(pop)
HMODULE MainModule = NULL;
HANDLE SingletonMutex = NULL;
uintptr_t TaskScheduler = 0;
int TaskSchedulerFrameDelayOffset = 0;
FileMapping IPC;
extern void WINAPI DllInit();
void WINAPI DllExit();
extern void SetFPSCap(int cap)
{
SettingsIPC fpscapper;
fpscapper.fps_cap = cap;
}
inline SettingsIPC* GetIPC()
{
return IPC.Get<SettingsIPC *>();
}[/CODE]
I also get this error when running a function:
System.EntryPointNotFoundException: 'Unable to find an entry point named 'SetFPSCap' in DLL 'rbxfpsunlocker.dll'.'
I have no idea how to set these values from c# using dll import. I did try to make a function as you can see from extern void SetFPSCap(int cap) that it failed horribly.
So how would i run functions from c#?
And I want my form radio button to set the cap to 30 fps or 60 fps. There is a config type thing in the code shown here
[CODE title="Code" highlight="34-38, 8-20"]#include <d3d11.h>
#pragma comment(lib, "d3d11.lib")
#include "sigscan.h"
#include "../injector/mapping.h"
#pragma pack(push, 1)
extern struct SettingsIPC
{
bool vsync_enabled;
double fps_cap;
struct
{
int scan_result;
void *scheduler;
int sfd_offset;
int present_count;
} debug;
};
#pragma pack(pop)
HMODULE MainModule = NULL;
HANDLE SingletonMutex = NULL;
uintptr_t TaskScheduler = 0;
int TaskSchedulerFrameDelayOffset = 0;
FileMapping IPC;
extern void WINAPI DllInit();
void WINAPI DllExit();
extern void SetFPSCap(int cap)
{
SettingsIPC fpscapper;
fpscapper.fps_cap = cap;
}
inline SettingsIPC* GetIPC()
{
return IPC.Get<SettingsIPC *>();
}[/CODE]
I also get this error when running a function:
System.EntryPointNotFoundException: 'Unable to find an entry point named 'SetFPSCap' in DLL 'rbxfpsunlocker.dll'.'
Code:
[DllImport("rbxfpsunlocker.dll", CallingConvention = CallingConvention.Winapi)]
static extern void SetFPSCap(int cap);
I have no idea how to set these values from c# using dll import. I did try to make a function as you can see from extern void SetFPSCap(int cap) that it failed horribly.
So how would i run functions from c#?
Last edited: