Commit Graph

27 Commits

Author SHA1 Message Date
jadebenn
7b819d508b Squashed commit of the following:
commit f4311e593f
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Nov 16 22:16:50 2024 -0600

    temp fix for MSVC debug builds

commit 0e81c69de8
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Nov 16 21:11:04 2024 -0600

    CMakePresets indentation

commit d7aa52a0fc
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Nov 16 21:03:37 2024 -0600

    use DLU_CONFIG_DIR envvar

commit d1bfe9f15d
Merge: 6e781da2 de3fe931
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Nov 16 20:24:05 2024 -0600

    Merge branch 'main' into MSVCCompilerFlags

commit 6e781da2e7
Merge: 6ccd72c6 3a6123fe
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Apr 13 18:15:16 2024 -0500

    Merge remote-tracking branch 'upstream/main' into MSVCCompilerFlags

commit 6ccd72c6a9
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Apr 13 17:48:58 2024 -0500

    add RelWithDebInfo presets and move -Werror flag into presets.json

commit b96cfd71a4
Merge: c4adcee8 1ee45639
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Apr 9 01:47:17 2024 -0500

    Merge remote-tracking branch 'upstream/main' into MSVCCompilerFlags

commit c4adcee8e8
Merge: 7f9fcb5b 28ce8ac5
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 22:30:35 2024 -0500

    Merge remote-tracking branch 'upstream/main' into MSVCCompilerFlags

commit 7f9fcb5b75
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 22:10:01 2024 -0500

    change gnu and clang build directories to enable consistent artifact generation

commit 553740e8a0
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 21:38:34 2024 -0500

    update build presets

commit 39a8029fda
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 20:30:06 2024 -0500

    update github actions

commit 7eae64f8a6
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 20:18:46 2024 -0500

    disable /WX on MSVC

commit 24d3bc0ce6
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Mon Apr 8 20:11:59 2024 -0500

    altered cmake configuration scripts

commit 368f4ccabf
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Apr 6 23:00:04 2024 -0500

    change defaults

commit 7d7ea68bf9
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 22:23:32 2024 -0500

    fix preset

commit 57d0b12f9b
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Apr 6 21:50:32 2024 -0500

    expand cmake presets

commit aa62d357bb
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 20:50:26 2024 -0500

    rename gcc to gnu

commit d6e4edd886
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 20:27:20 2024 -0500

    change runtime output dir

commit abe413f239
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 20:22:47 2024 -0500

    debug try 2

commit c6c771b892
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 20:16:00 2024 -0500

    add debug messages (again)

commit 6c6966afd2
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 19:46:58 2024 -0500

    was not actually fixed

commit fab74c90b6
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 19:37:02 2024 -0500

    are these messages actually somehow fixing the issue?

commit a4b6b7c0d9
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 19:27:34 2024 -0500

    see if this re-breaks mac

commit 07626f8ebb
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 19:04:59 2024 -0500

    back to debug messages

commit bdf9adc0e8
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:55 2024 -0500

    Revert "try disabling an apple-specific build rule"

    This reverts commit 45ec66e976.

commit 8154207848
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:53 2024 -0500

    Revert "more fiddling with mac test builds"

    This reverts commit 0f843c02c9.

commit 8f5c10d158
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:52 2024 -0500

    Revert "try and narrow down the macos build failure cause"

    This reverts commit 5fd86833fa.

commit 54876bf886
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:50 2024 -0500

    Revert "try stripping out all the custom macos test logic again"

    This reverts commit cc15a26ce8.

commit 8af35727a6
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:48 2024 -0500

    Revert "I'm really just throwing everything to the wall and seeing what sticks"

    This reverts commit 1a05b027fe.

commit e143f22ada
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:46 2024 -0500

    Revert "more macos tinkering"

    This reverts commit 829ec35b57.

commit 495e70c376
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:44 2024 -0500

    Revert "implib"

    This reverts commit d41349d6ed.

commit 37dbb52104
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:42 2024 -0500

    Revert "try manual link directory specification"

    This reverts commit 0c2d40632e.

commit ce568189fc
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:40 2024 -0500

    Revert "save me"

    This reverts commit bd73aa21a9.

commit c420a72016
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:36 2024 -0500

    Revert "aaaaaaaaa"

    This reverts commit 338279c396.

commit dccac945bb
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:47:08 2024 -0500

    Revert "paths paths paths"

    This reverts commit 9a7d86aa6c.

commit 9a7d86aa6c
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:39:08 2024 -0500

    paths paths paths

commit 338279c396
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:29:01 2024 -0500

    aaaaaaaaa

commit bd73aa21a9
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:21:16 2024 -0500

    save me

commit 0c2d40632e
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 18:09:03 2024 -0500

    try manual link directory specification

commit d41349d6ed
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 17:52:20 2024 -0500

    implib

commit 829ec35b57
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 17:43:47 2024 -0500

    more macos tinkering

commit 1a05b027fe
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 17:18:41 2024 -0500

    I'm really just throwing everything to the wall and seeing what sticks

commit cc15a26ce8
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 17:09:45 2024 -0500

    try stripping out all the custom macos test logic again

commit 5fd86833fa
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 16:54:53 2024 -0500

    try and narrow down the macos build failure cause

commit 0f843c02c9
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 16:47:19 2024 -0500

    more fiddling with mac test builds

commit 45ec66e976
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 16:29:29 2024 -0500

    try disabling an apple-specific build rule

commit 6e41423dc3
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 04:01:07 2024 -0500

    one last MacOS try for the night

commit bc79a17ddb
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 03:50:41 2024 -0500

    try fixing macos build

commit d6031ce9f5
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 03:04:52 2024 -0500

    try zero-initializinng this struct to solve docker issue

commit 24cbd94a80
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Apr 6 02:34:36 2024 -0500

    attempted docker fix

commit 7812f27330
Merge: ef8029d4 18c27b14
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Fri Apr 5 23:32:29 2024 -0500

    Merge branch 'main' into MSVCCompilerFlags

commit ef8029d46f
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Fri Apr 5 23:30:26 2024 -0500

    update cmake configs

commit 04a7bc2b8d
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 21:00:23 2024 -0500

    edit build script

commit 9fc6b4e973
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 18:10:09 2024 -0500

    fix build directory issue

commit a19afaaab0
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 18:06:37 2024 -0500

    update .gitignore

commit 426d34a0aa
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 17:58:19 2024 -0500

    unexclude toolchain dir

commit 9ce7d9043c
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 17:55:02 2024 -0500

    updated cmake workflows

commit db5c10c331
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 16:58:00 2024 -0500

    temporarily remove macos build for testing purposes

commit f7da00ff89
Merge: 145f97cf 661e0939
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 16:51:39 2024 -0500

    Merge branch 'MSVCCompilerFlags' of https://github.com/jadebenn/DarkflameServer into MSVCCompilerFlags

commit 145f97cfdc
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Fri Apr 5 16:50:39 2024 -0500

    build reorganization and experimental clang support

commit 661e0939b7
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Wed Apr 3 22:13:11 2024 -0500

    fix typo in windows preset

commit 018e5707d7
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 20:30:33 2024 -0500

    try using compiler flags for mac instead

commit 81e5f059d5
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 20:20:31 2024 -0500

    macos refuses to work :(

commit a3d70197f2
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 20:13:37 2024 -0500

    try adding build types back to mac

commit 005d439a4a
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 19:58:44 2024 -0500

    edit macos presets

commit bba825f0c8
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 19:48:20 2024 -0500

    update CMake presets

commit 199c8224a5
Merge: 1116ba83 c1c5db65
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Wed Apr 3 19:00:39 2024 -0500

    Merge remote-tracking branch 'upstream/main' into MSVCCompilerFlags

commit 1116ba8306
Merge: 9316bd6e c7b3d9e8
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sun Feb 11 21:03:02 2024 -0600

    Merge branch 'DarkflameUniverse:main' into MSVCCompilerFlags

commit 9316bd6eeb
Merge: 62fb8ad0 29666a1f
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Feb 10 21:02:52 2024 -0600

    Merge branch 'DarkflameUniverse:main' into MSVCCompilerFlags

commit 62fb8ad071
Merge: d5089b72 24f94edf
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Thu Feb 8 21:41:50 2024 -0600

    Merge branch 'DarkflameUniverse:main' into MSVCCompilerFlags

commit d5089b72cc
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sun Feb 4 16:26:38 2024 -0600

    add Linux debug preset

commit 7c9f56ff76
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Sat Feb 3 16:02:53 2024 -0600

    move out g++ O2 flag

commit 6cc99fae42
Merge: 96276391 050184c5
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Sat Feb 3 02:41:43 2024 -0600

    Merge branch 'DarkflameUniverse:main' into MSVCCompilerFlags

commit 962763916d
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 22:00:49 2024 -0600

    export the compile commands so I can see if they're having any effect

commit 4b7d1d6593
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 21:49:24 2024 -0600

    trying 'init' flags instead

commit 3fa80063e9
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 21:13:47 2024 -0600

    ONE MORE TIME

commit ae2115c68d
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 20:52:33 2024 -0600

    final(?) try for now

commit 119937f5d9
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 20:34:44 2024 -0600

    ditto

commit ab39754597
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 20:34:41 2024 -0600

    testing if these even have any effect

commit e7058be3dc
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 20:28:05 2024 -0600

    third test

commit 10d7776fb2
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 19:33:59 2024 -0600

    trying more variations on the flags

commit 70f3756098
Author: jadebenn <jonahbenn@yahoo.com>
Date:   Tue Jan 30 18:49:46 2024 -0600

    testing

commit 9b7c593ae9
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Tue Jan 30 08:49:53 2024 -0600

    Update CMakePresets.json

commit 8a34544d0e
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Tue Jan 30 08:44:29 2024 -0600

    test moving flags to json

commit b682f13fa9
Merge: 2239507d d78b5087
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Mon Jan 29 22:49:29 2024 -0600

    Merge branch 'DarkflameUniverse:main' into MSVCCompilerFlags

commit 2239507d3c
Author: jadebenn <jadebenn@users.noreply.github.com>
Date:   Mon Jan 29 06:14:47 2024 -0600

    Add MSVC optimization flags
2024-11-17 12:33:15 -06:00
jadebenn
fafe2aefad
chore: Nitpicking-utils (#1549)
* nit

* GeneralUtils const-correctness and minor fixes

* use copy instead of reference for char iteration loops

* fix typo and reorganize some functions
2024-04-14 23:14:54 -07:00
Aaron Kimbrell
feeac2e041
feat: refactor slash commands system into more scalable system (#1510)
* WIP, but working

* Scaffolding

* testing and making it compile again

* move all commands to functions

* renaming to compile

* fix failing tests

idk how these werent failing before.  Seems to have been magic.

* move commandss into their namespace
make help command useful
fix mac error

TODO: remove the multiple not founds/ rework the structure to split into help and handling

* Just need to fill out the fields, but it's all there templated

* Add all aliases, register missing commands

* All help text

* remove test logs

* improvements

pass through added code for optimizations and cleanup as well as reduce the amount of scoping for readability and maintainability

* Update SlashCommandHandler.cpp

* only save command if it is a GM command

* simplify if checks

* remove broken delimiter

* Update SlashCommandHandler.cpp

* Update SlashCommandHandler.cpp

---------

Co-authored-by: David Markowitz <EmosewaMC@gmail.com>
2024-04-08 15:11:59 -05:00
jadebenn
35ce8771e5
chore: supress warnings on external library headers and actually get rid of the last old-style casts (#1502)
* chore: supress warnings on external library headers and actually get rid of the last old-style casts

* remove commented out section I forgot

* update cmake required version to 3.25 unless we can find another way to do this

* update readme

* Update CMakeLists.txt
2024-03-17 20:48:09 -05:00
jadebenn
6e3b5acede
chore: Less verbose name for enum underlying type casts (#1494)
* Less verbose name for enum underlying type casts

* Remove redundant call
2024-03-06 23:45:04 -06:00
Daniel Seiler
554a9a6806
fix: Dissolve more CMake dependencies (#1387)
* fix: more include changes

* fix: remove dZoneManager from global include

* fix: dDatabase

* fix: dCommon

* fix: object libs

* fix: rebase

* fix: bcrypt

* wip: try simplified connector build

* fix: update dockerfile

* fix: mariadb C/C++ on apple

* feat: Move scripts to CMAKE_MODULE_PATH

* fix: dPropertyBehaviors

* fix: macos?

* fix: Dockerfile

* fix: macos?

* fix: macos?

* fix: macos?

* fix: macos?

* fix: macos?

* try: install_name_tool

* fix not building on unix

* fix include paths

* Remove code changes

Will fix in another PR.

* format pass

remove 2 more included directories.
remove commented out code
add status to messages

* comments and format

surround include directories with quotes
remove commented out code
remove debug messages

* Update CMakeLists.txt

---------

Co-authored-by: David Markowitz <EmosewaMC@gmail.com>
Co-authored-by: David Markowitz <39972741+EmosewaMC@users.noreply.github.com>
2024-03-05 20:13:24 -06:00
jadebenn
424d54b98c
squash commits (#1479) 2024-02-27 01:29:51 -06:00
jadebenn
7235423c7b
Convert game message bit stream raw pointers to references (#1465) 2024-02-26 08:17:22 -06:00
jadebenn
a0d51e21ca
refactor: allow usage of NiPoint3 and NiQuaternion in constexpr context (#1414)
* allow usage of NiPoint3 and NiQuaternion in constexpr context

* removed .cpp files entirely

* moving circular dependency circumvention stuff to an .inl file

* real world usage!!!!!

* reverting weird branch cross-pollination

* removing more weird branch cross-pollination

* remove comment

* added inverse header guard to inl file

* Update NiPoint3.inl

* trying different constructor syntax

* reorganize into .inl files for readability

* uncomment include

* moved non-constexpr definitions to cpp file

* moved static definitions back to inl files

* testing fix

* moved constants into seperate namespace

* Undo change in build-and-test.yml

* nodiscard
2024-01-29 01:53:12 -06:00
Aaron Kimbrell
0bc12141c3
chore: default size to 33 on LU(W)Strings since that's the most common lenght (#1410)
Was doing this on other places, but not the main one
2024-01-12 14:23:44 -06:00
jadebenn
440dc8b88f
replace macro with anonymous namespace function (#1394) 2024-01-05 18:55:42 -06:00
David Markowitz
2804dc3ec2
fix: make include paths consistent (#1390)
* fix: bad header includes

tests pass

* fix-up more include paths
2024-01-05 06:33:52 -06:00
David Markowitz
1941679d27
feat: Bump standard to 20 (#1376)
* Bump to 20

* fix warnings and errors

* thanks RakNet
2024-01-02 07:53:00 +00:00
jadebenn
6de224a2fa
chore: miscellaneous code, formatting, and syntax cleanup (#1351)
* miscellaneous code, formatting, and syntax cleanup

* update

* update again

* updated to account for feedback
2023-12-23 18:11:00 -06:00
jadebenn
fcf4d6c6fa
feat: Improve console output to show packet enum names (magic_enum) (#1344)
* add enum stringification functionality from third party source

* squashed commit

* Macros: Add test and improve speed

Space macros out
utilize cache locality
ensure no lost functionality

* moved stringify code to dCommon

* Rename #defines in stringify enum tests

* Revert "moved stringify code to dCommon"

This reverts commit 33fa5f8d2f.

* improve macro functionality

change function handle

formatting and function definition tweaks

* typo fixes

* moved code to dCommon/dEnums and tests to dCommonTests/dEnumsTests

* initial magic_enums alternate implementation of enum stringification

* deleted unused tests

* reverted compile flag oopsy and fixed output types

* fixed testing suite

* test formatting improvement

* formatting again :(

* added gm string to "aborting gm!" message

* Push my suggestion for CI tests.

* updated magic enum test

* fix test variable type

* added gm test

* making sure magic_enum is on a release branch

* tidying up console outputs

* re-implemented enum array access for performance

* now it is bugged :(

* nvm, working

* helping out the snowflake compilers

* changed return type too

* optimization too

* formatting too I guess because why not

* being even more painfully specific

* Update WorldServer.cpp to match emo's feedback

* Update MagicEnumTests.cpp to use srand(time(NULL))

* Update eGameMessageType.h - formatting

* Trying to fix the crash but can't actually compile the code to check on my own rn

* Update WorldServer.cpp - third try at this

* Update MagicEnumTests.cpp - use better macro definitions

* Update MagicEnumTests.cpp - c string comparison fix

* addressing all but the cmake feedback

* fixed cmake to the best of my very limited ability

* added tests to verify magic enum arrays are pre-sorted

* updated

---------

Co-authored-by: David Markowitz <EmosewaMC@gmail.com>
Co-authored-by: Jettford <mrjettbradford@gmail.com>
2023-12-23 10:51:59 -06:00
David Markowitz
1a199151da
Remove std::couts littered throughout the base (#1313) 2023-11-21 18:04:23 -08:00
Aaron Kimbrell
8e84cafdfa
feat: add configurable feature and versions (#1298)
* feat: add configurable feature and versions
to allow for easily swithing it out to enable features in the client for funsies
tested that this doesn't break anything and added test

* cleanup
2023-11-18 03:33:23 -06:00
David Markowitz
5942182486
feat: Abstract Logger and simplify code (#1207)
* Logger: Rename logger to Logger from dLogger

* Logger: Add compile time filename

Fix include issues
Add writers
Add macros
Add macro to force compilation

* Logger: Replace calls with macros

Allows for filename and line number to be logged

* Logger: Add comments

and remove extra define

Logger: Replace with unique_ptr

also flush console at exit. regular file writer should be flushed on file close.

Logger: Remove constexpr on variable

* Logger: Simplify code

* Update Logger.cpp
2023-10-21 16:31:55 -07:00
David Markowitz
3dd2791066
chore: Use TryParse for LDF parsing (#1206)
* LDF: Simplify parsing

* Update GeneralUtils.h
2023-10-09 15:22:40 -05:00
Aaron Kimbrell
08020cd86d
chore: cleanup LU(W)string writing (#1188)
* chore: cleanup LU(W)string writing
and add methods for reading
remove redunent "packet" from packet reading helpers
move write header to bitstreamutils since it's not packet related
add tests for reading/writing LU(W)Strings

* remove un-needed function defintions in header

* make reading and writing more efficient

* p

p

* quotes

* remove unneeded default

---------

Co-authored-by: David Markowitz <39972741+EmosewaMC@users.noreply.github.com>
2023-09-20 20:06:28 -05:00
David Markowitz
0d48cfe8c0
fix: Nipoint3 Operator+= (#1172)
* fix operator +=

* fix operator +=
2023-07-31 00:22:56 -07:00
David Markowitz
4fe335cc66
Refactor: Amf3 implementation (#998)
* Update AMFDeserializeTests.cpp

Redo Amf3 functionality

Overhaul the whole thing due to it being outdated and clunky to use

Sometimes you want to keep the value

Update AMFDeserializeTests.cpp

* Fix enum and constructors

Correct enum to a class and simplify names.
Add a proper default constructor

* Update MasterServer.cpp

* Fix bugs and add more tests

* Refactor: AMF with templates in mind

- Remove hard coded bodge
- Use templates and generics to allow for much looser typing and strengthened implementation
- Move code into header only implementation for portability

Refactor: Convert AMF implementation to templates

- Rip out previous implementation
- Remove all extraneous terminology
- Add proper overloads for all types of inserts
- Fix up tests and codebase

* Fix compiler errors

* Check for null first

* Add specialization for const char*

* Update tests for new template specialization

* Switch BitStream to use references

* Rename files

* Check enum bounds on deserialize

I did this on a phone
2023-05-13 17:22:00 -05:00
David Markowitz
7aad6e4bc2
Make header skips more obvious (#1074)
* Make header skips more obvious

seeing inStream.Read(LWOOBJID) is much less clear than a macro which very clearly skips the header.

* Formatting pass
2023-05-08 06:31:10 -05:00
David Markowitz
e8590a5853
Add tests for LDF parsing and serialization. Cleanup LDF (#1062)
* Add tests and cleanup LDF header

Also implements a speedup by using overloaded operators to put numbers directly to a stream as opposed to doing to_string first.

Stage 2 of re-write

Reduce scoping
Add further optimizations
Fix more edge cases
Split out tests to many smaller ones

Use EXPECT_NO_THROW

Add edge cases to test

Added these first with the before to confirm they failed, and now will be adding the remaining fixes needed to make the tests pass.

Add edge case testing for LDF strings

Add further tests

Use characters instead of char*

Update AMFDeserializeTests.cpp

Add null tests

* Add Test Fixture for dCommon

* Add speed test

* Convert to using string_view

* Add explanation on early return

* Remove "testing" code
2023-05-02 17:19:20 -05:00
David Markowitz
4734996c7c
Resolve most compiler warnings (#1053) 2023-04-12 11:48:20 -05:00
David Markowitz
d138b7b878
Make ControlBehavior messages far more modular (#991)
* Make case consistent

* How modular can you go?

Holy modular

* Add comments

* Initialize values
2023-02-16 11:30:33 -06:00
David Markowitz
1464762bcd
Implement GTest and change windows output path
Implement GTest as a testing infrastructure.
Make windows output binaries to the build folder instead of the release type folder (potentially issue further down the line)
Add a simple unit test for DestroyableComponent
2022-11-07 00:12:35 -08:00