269 Commits

Author SHA1 Message Date
IcePixelx
899bde2af0 Add comments. 2021-12-27 21:30:04 +01:00
IcePixelx
f5208d2b61 Fixed NET::ShutDown recursive calling, fixed decompressed patch header size on decompress. 2021-12-27 20:44:37 +01:00
Amos
e03d74b753 Rename RTech decompression methods 2021-12-27 16:58:07 +01:00
Amos
69161ae6c0 Implement RTech_AsyncLoad hook and concommand
The ConCommand 'rtech_asyncload' allows the user to load specific pak files on-demand.
2021-12-27 16:53:35 +01:00
IcePixelx
54e07952e1 Fixed compilation. 2021-12-27 14:17:34 +01:00
Amos
947049b7e6 Add RPak async load pattern 2021-12-27 03:27:22 +01:00
Amos
0107656b1b Dedicated server inaccessible memory fix
The approach could likely be performed better, however this is a multithreaded operation and isn't very easy to debug. So far this allowed the server to start and change to every level. The root cause has to be identified when the server is stable
2021-12-27 03:15:25 +01:00
Amos
a87eee1818 Fix bug where FCVAR_CHEATS gets stripped regardless of intention 2021-12-27 02:23:03 +01:00
Amos
77c2be57ec Fix crash when setting persistence var in CClient struct 2021-12-27 02:06:03 +01:00
IcePixelx
c7987f8f6b Abit of Vector3 class. 2021-12-26 23:58:06 +01:00
IcePixelx
15bfffdd0f Fixed typo. Properly mask off cheats and dev from concommands and convars. 2021-12-26 22:58:28 +01:00
IcePixelx
c90d3184ea Aligning. 2021-12-26 04:14:28 +01:00
IcePixelx
0ca5b5ae35 Fixed potential crash with _NET_SetKey_f_CompletionFunc. 2021-12-26 02:37:56 +01:00
IcePixelx
c81aca28de Fixed a few asserts regarding the gui. RPak things. Check description.
* Fixed assert on ImGui on IBrowser because ImGui::Begin wasn't followed up by ImGui::End
* FileExists got modernized. Using std library instead of Windows native functions now.
* RTech::DecompressedSize is actually readable now thanks to steyk.
* Same goes for RTech::Decompress
* rtech_decompress prints the decompressed file CRC32 now and writes the file all at once.
* Fixed ImGui assert on spamming SetupImGui();
2021-12-26 02:30:20 +01:00
IcePixelx
8cfc55289b Git client decided not to commit this. 2021-12-25 22:58:51 +01:00
IcePixelx
8ed86febff fixed file typo. 2021-12-25 22:54:32 +01:00
Amos
2f30ce4a4c Move banlist.config back to root dir due to its importance 2021-12-25 22:49:09 +01:00
Amos
d5b2e58dae Code base refactor + major performance and readability improvement. Read description for details.
* Codebase restructured to SourceSDK codebase style and .cpp/.h assertion paths in the game executable.
* Document most functions with valve style 'Purpose' blocks.
* Rename variables to match the rest of the codebase and Valve's naming convention.
* Dedicated DLL and the SDKLauncher now share the same codebase as the DevSDK.

* Obtain globals or pointers directly instead of waiting for runtime initialized data.
* Dynamically search for all functions and globals (this doesn't count for dedicated yet!).
* Initialize most in-SDK variables.

* Move certain prints and other utilities under ConVars to reduce verbosity and increase performance.
* Print all pattern scan results through a virtual function to make it easier to add and debug new patterns in the future.
* Type global var pointers appropriately if class or type is known and implemented.
* Forward declare 'CClient' class to avoid having 2 'g_pClient' copies.
* Add IDA's pseudo definitions for easier prototyping with decompiled assembly code.

* RPAK decompress Command callback implementation.
* Load decompressed RPaks from 'paks\Win32\' overriding the ones in 'paks\Win64\' (the decompress callback will automatically fix the header and write it to 'paks\Win32\').

* VPK decompress Command callback implementation.
* Move CRC32 ands Adler32 to implementation files.

* Server will print out more details about the connecting client.

* Upgrade ImGui lib to v1.86.
* Don't compile id3dx.h for dedicated.
* Don't compile id3dx.cpp for dedicated
* Implement DevMsg print function allowing to print information to the in-game VGUI/RUI console overlay, ImGui console overlay and the external windows console

* Fixed bug where the Error function would not properly terminate the process when an error is called. This caused access violations for critical/non-recoverable errors.
* Fixed bug where the game would crash if the console or server browser was enabled while the game was still starting up.
* Several bug fixes for the dedicated server (warning: dedicated is still considered work-in-progress!).
2021-12-25 22:36:38 +01:00
IcePixelx
262365b733 origin sdk, throw error if originsdk failed. 2021-12-15 15:58:50 +01:00
IcePixelx
f34b4bbeea Rebuild CHostState::FrameUpdate fully works now. 2021-11-05 21:25:25 +01:00
IcePixelx
15078652e1 Create class instances earlier. 2021-11-05 00:57:52 +01:00
IcePixelx
e92453db37 Some fixes. 2021-11-05 00:09:49 +01:00
Amos
877fb9a077 Fix redefinition compiler error 2021-10-24 13:37:43 -07:00
Amos
6fb9e8004a Additional patches for dedicated
New patches disabling extra stuff
Improve code readability
2021-10-24 12:50:23 -07:00
Amos
f6c6ab6768 Additional dedicated server patches. Pending big overhaul
'Changelevel 'concommand works consistently and indefinitely now

Huge strip down in resource usage. Few things to be fixed still so idle mem usage is still balooned due to a temporary solution brought in place to prevent crashing when loading texture and material assets.

Stripping texture and material assets preloading from the root caused issues in 'CStudioRenderContext' and 'ModelLoader'. This needs to be addressed in the future

Exact line of the issue: Line 177 in opcodes.cpp:
"gCSourceAppSystemGroup_Create.Offset(0x384).Patch({ 0x90, 0x90, 0x90 }); // PrecacheMaterial"
2021-10-23 12:47:54 -07:00
IcePixelx
d2c724786f Merge branch 'indev' of https://github.com/Mauler125/detours_r5 into indev 2021-10-22 18:55:15 +02:00
IcePixelx
5a432fba57 fixed typo 2021-10-22 18:55:10 +02:00
Amos
a4273fedfd Alpha dedicated 2021-10-21 15:56:45 -07:00
IcePixelx
ab12789faf Log system adjustments. 2021-10-20 18:49:48 +02:00
r-ex
7f86722116
changed paint hook for logsystem and fixed some issue (#58)
* changed paint hook

* Update gameclasses.cpp

* fixed vector issue with logsystem (i think)
2021-10-20 18:04:21 +02:00
IcePixelx
cb3aaa7640 Clean up. 2021-10-20 18:03:02 +02:00
Amos
18d6e1f666
Merge pull request #56 from r-ex/indev
logsystem console overlay
2021-10-05 15:29:59 -07:00
rexx
6c65dd0fcd why 2021-10-05 22:10:08 +01:00
rexx
c356dd403c Update hooks.h 2021-10-05 22:01:28 +01:00
rexx
3d770e087d convar for logger overlay, some colour changes 2021-10-05 21:59:27 +01:00
rexx
65ab3770e5 Update patterns.h 2021-10-05 20:56:52 +01:00
rexx
ea336277bd base logsystem 2021-10-05 20:56:31 +01:00
IcePixelx
341bd875e7 Fixed some debug prints. 2021-10-05 00:34:50 +02:00
IcePixelx
ef8b20f513 Removed LockCursor static address when removing the hook. 2021-10-05 00:28:14 +02:00
IcePixelx
17d45a02aa Read description for changes.
* Completely re-wrote the DirectX creation and hooks.
* Using spdlog mostly everywhere now.
* Added prints for when compiled in debug.
* Using LockCursor now to prevent input to the game while in the gui.
* Patched the game to call CMatSystemSurface::LockCursor instead of it calling the inlined version.
* Added rebuild CHostState::FrameUpdate (Not finished yet)
* Added option to print to command prompt again.
* Added log Auto-Clear.
* Added scan for NetChan Encryption Key Pointer.
* Added more error handling when loading gui config.
2021-10-05 00:25:58 +02:00
Amos
27536741f8
Merge pull request #54 from r-ex/indev
native server script functions
2021-09-25 14:58:54 -07:00
rexx
26d78c584e temp dedi patches 2021-09-25 22:54:11 +01:00
rexx
6236a6402d server script functions 2021-09-20 21:06:23 +01:00
Александр Герман
d08387d9ba
static link debug (#53) 2021-09-16 12:42:05 +02:00
r-ex
25c5a5c9af
custom native ui & client script functions (#52)
* custom native ui & client script functions

* spacing is hard

* sq_pushbool, sq_pushstring, sq_getstring, sq_getinteger

* sq_pushinteger, sq_newarray, sq_arrayappend, sq_newtable, sq_newslot

* Re-factored code.

Co-authored-by: IcePixelx <41352111+PixieCore@users.noreply.github.com>
2021-09-14 17:25:22 +02:00
Amos
b42e85b1f4 First work-in-progress dedicated implementation
Based on MrSteyk's dedicated patch.
Additional patches targets the disabling of the client.dll library and VGUI. The disabling of the client.dll library initialization caused several issues to be investigated still (currently loops fine in _Host_RunFrame()). but executing a map command currently makes it only load the mp_common VPK before getting stuck somewhere. Setting hoststate to a valid map with HS_NEW_GAME (manually) does something to the engine but does not force the server to load anything yet.

Added enums and classes from r5dev project.
2021-09-12 16:41:30 -07:00
Amos
fad7906fd8 Update launcher
Adds spdlog library instead for clearer output.
Adds precompiled header for slightly faster compilation.
Updated print text with clearer details.
Renamed to "r5reloaded.exe" instead to match files in game directory
2021-09-12 07:15:42 -07:00
IcePixelx
2da6d71fb3 Alot of changes read description
* Ban list added
* Playlist parser added
* Kick functions added
* Connect uses encryption keys now
* Fixed restricted server commands
1.6
2021-09-08 00:32:03 +02:00
IcePixelx
c89c7c9c6b Removed native console logging, logging to file and imgui console now. 2021-08-30 17:52:10 +02:00
IcePixelx
0e1c930805 Re-factored r5launcher. Using std::filesystem to read startup files now. 2021-08-30 16:39:56 +02:00