Commit Graph

45 Commits

Author SHA1 Message Date
Aaron Kimbre
09bd4e9089 make it compile 2023-11-16 00:32:50 -06:00
Aaron Kimbre
2a34cff008 Merge branch 'main' into guild_temp 2023-11-15 21:14:20 -06:00
David Markowitz
0ddd20e2b5
fix: ugc Save rocket and car modular assembly data to database (#1279)
* Ugc: Use persistent Id for rocekts and cars

* Remove comment

* Ugc: Save rocket and car IDs to the database

* Correct names

* Database: formatting
2023-11-15 19:32:30 -06:00
Aaron Kimbrell
1ec8da8bf7
fix: remove foreign key on name in cheat_detection table (#1202) 2023-09-30 06:22:32 -05:00
David Markowitz
b24775f472
feat: Security improvements for spoofed packets (#1201)
* Add cheat detection for spoofed packets

* Add config option for ip loggin

* remove packet saving
2023-09-28 12:16:11 -05:00
David Markowitz
238fc98ea5 Fix shooting gallery leaderboard bugs
- add weekly functionality for top scores
- Fix shooting gallery score saving
- remove extra leaderboard fetch
2023-06-21 21:46:11 -07:00
David Markowitz
96fc6e81d8 Update sql to work
The old way was supposed to work but doesn't.  Oh well!
2023-06-05 02:24:00 -07:00
EmosewaMC
47deca6f4f Update migration
Better column names and maintainability
Better updating
Convert all data to floats
2023-05-31 23:04:33 -07:00
EmosewaMC
0107d05d55 draft 2023-05-30 04:11:37 -07:00
David Markowitz
1c7ac93d4b Fix various bugs and make code cleaner.
Still have work to go.
2023-05-08 03:55:10 -07:00
David Markowitz
bc518be654 Bug fixes and cleanup
Fix co-pilot induced column bugs
Fix insert/update statements
Added saving functionality
Added update clause for column
2023-05-07 04:09:10 -07:00
EmosewaMC
820b375c50 push 2023-05-07 00:31:38 -07:00
EmosewaMC
42870028e4 Remove complex migration
Only shooting gallery had a value put in the wrong column.  All others were either already correct or unimplemented.
2023-04-17 15:19:13 -07:00
David Markowitz
fcb088d263 Further work on leaderboards
- Modularize tests
- Add migrations
- Fix switch case so it actually breaks
- Add in missing writes
- Beginning work on custom migration to move the leaderboard to the final state
2023-04-17 01:16:23 -07:00
Aaron Kimbrell
ce51438bc8
Implement some scripts for alpha FV (#1049)
* Implement maelstrom fog for alpha FV
add OnOffCollisionPhantom call to cppscripts
Add physics shape for gas blocking volume

* Add Ninja Sensie Script for alpha FV
and migration

* Fix private var casing

* And ninja wild scripts
they keep making me add more things

* address feedback

---------

Co-authored-by: Gie "Max" Vanommeslaeghe <gievanom@hotmail.com>
2023-04-12 11:46:31 -05:00
Aaron Kimbrell
9d65d871d0
fix compatibility with nexus dash (#1011)
* add some more utility to the masterserver -a command
fix compatability with nexus dash

* cleanup code some more
user logger where it makes sense
only take in password if it is needed
log a better error if account cannot be created

* update message

* return before success statement if catching error
2023-03-05 13:11:32 -06:00
David Markowitz
fab4414204
Fix serratorizer chargeup time (#931) 2022-12-31 03:56:12 -08:00
Aaron Kimbre
c4ae05ecee fix guild creation 2022-12-20 08:54:52 -06:00
Aaron Kimbre
30fbdd3956 WIP 2022-12-20 08:14:58 -06:00
Demetri Van Sickle
fde62a4777
Fixed typo (#875) 2022-12-06 08:36:42 -06:00
Aaron Kimbrell
d8945e9067
Add migration to make play_key_id nullable (#857)
since there is an option not to use play_keys
2022-12-02 03:46:54 -08:00
David Markowitz
d4af7d76a2
Add property behaviors migration (#790)
* Add behaviors migration

Add migration for behaviors.  Tested that the tables get altered correctly, names are set correctly.

Tested that I can place models, both regular and Brick-by-Brick ones and that they get deleted properly.  Tested that picking up models and re-placing them down properly updates them in the tables.

* Only update when empty
2022-10-31 17:31:49 -05:00
David Markowitz
906887bda9
Add automatic cdclient migration runner support and setup (#789)
* Add automatic migrations for CDServer

Add support to automatically migrate and update CDServers with new migrations.  Also adds support to simplify the setup process by simply putting the fdb in the res folder and letting the server convert it to sqlite.

This reduces the amount of back and forth when setting up a server.

* Remove transaction language

* Add DML execution
`poggers`
Add a way to execute DML commands through the sqlite connection on the server.

* Make DML Commands more robust

On the off chance the server is shutdown before the whole migration is run, lets just not add it to our "finished list" until the whole file is done.

* Update README
2022-10-30 00:38:43 -07:00
David Markowitz
c13937bd1f
Address Brick-By-Brick builds not properly saving and make migrations automatic (#725)
* Properly store BBB in database

Store the BBB data in the database as the received SD0 packet as opposed to just the raw lxfml.  Addressed several memory leaks as well.

* Add Sd0Conversion

Add brick by brick conversion commands with 2 parameters to tell the program what to do with the data.

Add zlib -> sd0 conversion.  Files look good at a glance but should be tested in game to ensure stability.  Tests to come.

* moving to laptop

ignore this commit.  I need to move this to my laptop

* Add functionality to delete bad models

Adds functionality to delete bad models.  Models are batched together and deleted in one commit.

More testing is needed to ensure data safety.  Positive tests on a live database reveal the broken models were truncated and complete ones were kept around successfully.  Tests should be done to ensure larger sd0 models are properly saved and not truncated since this command should be able to be run any time.

Valgrind tests need to be run as well to ensure no memory leaks exist.

* Delete from query change

Changed from delete to delete cascade and instead deleting from properties_contents as opposed to ugc.

* Address numerous bugs

DELETE CASCADE is not a valid SQL command so this was changed to a better delete statement.

Added user confirmation before deleting a broken model.
Address appending the string model appending bad data, causing excess deletion.
Addressed memory leaks with sql::Blob

* Error handling for string

* Even more proper handling...

* Add bounds check for cli command

Output a message if a bad command is used.

Update MasterServer.cpp

* Remove user interference

-Add back in mariadb build jobs so i dont nuke others systems
- Remove all user interference and consolidate work into one command since 1 depends on the next.

* Add comments

test

Revert "test"

This reverts commit fb831f268b7a2f0ccd20595aff64902ab4f4b4ee.

* Update CMakeMariaDBLists.txt

Test

* Improve migration runner

Migration runner now runs automatically.
- Resolved an issue where extremely large sql queries caused the database to go into an invalid state.
- Made migrations run automatically on server start.
- Resolved a tiny memory leak in migration runner? (discarded returned pointer)
- Moved sd0 migrations of brick models to be run automatically with migration runner.
- Created dummy file to tell when brick migrations have been run.

* Update README

Updated the README to reflect the new server migration state.

* Make model deleter actually delete models

My complicated sql actually did nothing...  Tested that this new SQL properly gets rid of bad data.

* Revert "Update CMakeMariaDBLists.txt"

This reverts commit 8b859d8529.
2022-10-24 17:20:36 -05:00
avery
0b9e97625e
Remove parentheses from ADD reporter_id 2022-07-30 22:09:45 -07:00
Jett
c9cd7a200a
Merge pull request #634 from DarkflameUniverse/migration-runner
Add a argument to the MasterServer for running migrations
2022-07-12 11:17:42 +01:00
Jett
d642de9462 Implement a migration runner 2022-07-12 02:16:08 +01:00
David Markowitz
06217ad5e3
Address friends list IDs and removal of friends (#628)
* Add friends list migration

* Change friends to use charID

Update friends table to use charID and not LWOOBJID variant.

* Fix remove friend

Fix remove friend and make the query more readable at a glance.

* Add and remove friends in the container

Properly add and remove friends in the player container
2022-07-10 17:59:07 -07:00
Aaron Kimbre
d42cbb2473 make newline at end of file 2022-04-19 21:36:09 -05:00
Aaron Kimbre
d4adb0e6e5 Fix migration 0 for cd server
setting every component to 1901 instead of just component 39
Add migration to fix it for existing users
and set the values back to what they were
2022-04-19 21:30:38 -05:00
EmosewaMC
77c6350f03 updated initial migration
Made it so people wont accidentally wipe their database if 0_initial.sql is ever run again
2022-04-09 00:48:14 -07:00
EmosewaMC
3900267fed added comment 2022-04-09 00:31:18 -07:00
EmosewaMC
0a494422b7 Added migration for plunger gun 2022-04-09 00:22:02 -07:00
David Markowitz
db0f363967
Merge pull request #476 from EmosewaMC/bugReportFixing
Added more specific bug reporting.  There is a new migration called migrations/dlu/2_reporter_id.sql to run on the database.
2022-04-01 15:12:58 -07:00
EmosewaMC
5c16dd11f4 altered table now has a default for performance cost 2022-03-30 00:37:36 -07:00
EmosewaMC
e79d4e66f3 add performance cost column 2022-03-29 19:46:38 -07:00
EmosewaMC
6499139a49 moved addition to new migration. 2022-03-24 01:11:21 -07:00
EmosewaMC
22a00de8cd added char id column 2022-03-20 20:46:15 -07:00
EmosewaMC
150dec1cc2 Added file to run on table charinfo to allow for unique names only
Created a new file to run on the MySQL database to alter the MySQL table charinfo.names to only allow unique entries
2022-01-09 00:12:49 -08:00
EmosewaMC
01230e2575 Revert change in 0_initial.sql 2022-01-09 00:09:27 -08:00
EmosewaMC
b529b7d3a0 Added UNIQUE for charInfo table
Added UNIQUE for charInfo table.
2022-01-08 00:00:27 -08:00
Ramen2X
ca287db536
make 0_initial.sql compatible with MySQL 2021-12-06 20:06:12 -05:00
Avery
0a9d4d0d66
Update 0_nt_footrace.sql 2021-12-05 19:28:06 -08:00
Avery
bcfa1fb906
Update 1_fix_overbuild_mission.sql 2021-12-05 19:27:45 -08:00
Unknown
0545adfac3 Public release of the DLU server code!
Have fun!
2021-12-05 18:54:36 +01:00