Commit graph

66 commits

Author SHA1 Message Date
Mag-nus
dfafa2f026
Few more minor bug fixes with the help of Claude (#4471) 2026-08-03 11:48:25 +00:00
Mag-nus
63dcd84541
Improve Offline Player Saving (#4100)
PlayerManager saves offline players in bulk, once very hour. This is done in bulk to help avoid desync between offline player updates.

Player caching is typically set to 30 min.

What can happen now is that PlayerManager may save a bunch of offline players, that will then be loaded into the player biota cache (for 30 min)... then after 30 min, they all get unloaded because nothign touches those biotas, then 30 min later again the PlayerManager performs its hourly maint of bulk save, thus, re-caching all those biotas.

Caching is not necessary for these biotas.

Caching is designed for biotas that exist in an online state.
2024-02-03 20:43:13 +00:00
Ty Conner
e5351c2f0e
wire up copychar and bornagain commands (#3599)
* copychar

* bornagain

* .

* ..

* Update AdminCommands.cs

* Update PlayerManager.cs

* Update AdminCommands.cs

* Update AdminCommands.cs

* Update ShardDatabase.cs

* Update ShardDatabase.cs
2021-07-18 13:47:01 -04:00
Ty Conner
79dd8bd083
Fix context save issues with character rename by admin (#3116)
* Fix context save issues with character rename by admin

* Update ShardDatabase.cs
2020-08-13 12:57:23 -04:00
Mag-nus
62c648bfe6
Improve ShardDatabaseWithCaching Locking (#2880)
* Improve ShardDatabaseWithCaching Locking

* Add biota information

* remove virtual

* remove debugging
2020-04-05 15:40:21 -05:00
Mag-nus
75fc1ce23c
Step 3. Convert ShardDatabase/WorldObjects biota from the ACE.Database model to the new ACE.Entity model (#2731)
* Step 1. Add new adapter classes and models

All classes and objects added are in new namespaces.

This add has 0 interraction on existing ACE code.

This sets the groundwork for Step 2. Moving World DB caching to the new models

* first part of the world entity usage

* almost there

* final part

* update WeenieExtensions

* fix

* merge fixes and improvements

* ACE.Database new code

* it compiles

* InitializePropertyDictionaries

* WOrldDatabaseWithEntityCache cleanup

* ShardDatabaseWithCaching

* ShardDatabase Cleanup

* todo

* cache counts reported in serverstatus

* House InitializePropertyDictionaries

* improve ServerStatus

* BiotaModel change HousePermissions to Dictionary<uint, bool>

* PropertiesAllegiance to dictionary

* BiotaUpdater improvements

* Shard Database Cache Reporting

* More code ported from Step 3

* Remove stub CharacterCache

* Update WorldDatabaseWithEntityCache.cs

* build fixes

* code audit

* Remove non-callback functions from SerializedShardDatabase

* BiotaUpdater progress.. only emote left

* Emotes done... now need to test

* fix

* Burden/Value fix for containers

* fat fingered EncumbranceVal

* add some safety

* Don't cache player biotas for initial PlayerManager load

* fix null spellbook

* Add another null check

This is redundant as the check is also upstream.

This is to prevent an exception in the future if this function is called from another source.
2020-04-02 22:40:27 -05:00
gmriggs
23a005a763
multihouse decommission (#2067)
* prototype: adding account-wide house recall

* updating restriction db / has permissions

* additional ObjMaint refactoring

* re-adding CheckPlayers()

* the call to GetVisibleObjects() in Monster.FindNextTarget() is no longer needed in new design

* removing more unused code

* very preliminary testing

* prevent 1 character from purchasing multiple houses

* adding account/character houses

* further work on AccountHouses / CharacterHouses

* latest updates, account/character multihouse polish, apartment deed location

* adding /house-select process

* HouseManager refactoring, removing async, fixing PlayerHouse.CompareTo equals, fixed InventoryLoaded for weenies, added Player_House.GetHouseInstance()

* first posted draft

* wiring up the remaining HouseInstance -> GetHouseInstance()

* preventing maintenance items from being added for houses owned by players in multihouse state

* cleaning up log messages, handling some edge cases
2019-07-10 13:39:10 -04:00
gmriggs
3602018459
adding verify-skill-credits (#1954) 2019-06-08 22:14:20 -04:00
Ty Conner
807f8105da
Fix some issues with finger command (#1879)
* Add GetCharacterByGuid

* Adjust finger command to only return "playable" characters, and correct accounts for offline players

* Add IsDeleted and adjust IsPendingDeletion
2019-05-12 17:06:19 -05:00
Ty Conner
1eb41f4ef7
Several Command Updates (#1614)
* GameMessageServerName tweak

* Update acehelp and acecommands

* Add pop command

* Add watchmen command

* Add finger command

* Update changelog

* .

* cleanup

* cleanup

* Load Account when Player is Onlined

* .

* Hide launcher pings and pongs.

* Add null check for @telereturn
2019-03-31 04:52:09 -05:00
Ty Conner
c2923cf38b
Rework Name and IsPlussed (#1510)
* Rework Name and IsPlussed a bit

* Add basic support for player weenie changes when accesslevel changes

* Cleanup

* Update changelog

* cleanup

* clean up returns

* Return to Virtual + Override

* cleanup

* Restore @rename functionality

* Strip + from killer's name in Corpse.LongDesc for VTank compatiblity

* Add @pk command

* Add in support for PlayerKillerStatus.Free

* Add Chorzite to comps list

* If Level is greater than maxlevel, do not crash

* Fix @morph command
2019-03-10 22:15:43 -05:00
Mag-nus
0095e2cfcc
Reuse available Dynamic GUIDs (#1493)
* Reuse available Dynamic GUIDs

On ACE startup, the shard database is queried for available id's in the dynamic guid range.

This helps further reduce (max + 1) id allocation.

It's a bit premature, but, based on current architecture, I don't know if we'll ever need to do a id defragment.

A requirement of this method is that ace_world may only contain guids in the static range.

* GetMaxGuidFoundInRange has no valid use in ace_world

All ids must be in the static range

* Add world update script
2019-03-07 20:17:42 -06:00
gmriggs
e682545dc9
Adding most of the remaining Allegiance features (#1396)
* Adding most of the remaining Allegiance features

* Adding house ownership verification

* Sending allegiance metadata on login

* Adding officer permission levels

* checking allegiance house permissions for recall

* Adding /allegiance house commands

* Renaming classes

* Adding allegiance locks

* Adding handler for monarch pledging allegiance

* Adding allegiance chat boot / gag

* Adding allegiance boots and bans
2019-02-03 12:09:32 -05:00
gmriggs
9c8bc7ceb0
Adding /hslist <housetype> to show list of available houses (#1373)
* Adding /hslist <housetype> to show list of available houses

* Updating RootHouse

* Updating activation requirements for wielding items

* More updates

* Adding ConvertToMoASkill to activation requirements

* reversing lock check

* Fixing floating storage chests

* Revise comment
2019-01-26 15:14:32 -05:00
gmriggs
7837c7bf61
Adding housing portals / dungeons (#1187)
* Adding house guest and storage permissions, open/closed, hook visibility, and boot system

* Adding housing portals / dungeons

* small fix
2018-12-29 10:15:51 -05:00
Mag-nus
17ac4db713
Fix player logout, save, and session drop flows (#1119)
* Add Shard biota count to serverstatus

* Remove unneeded null check in Session.cs

* Progress

Remove Player.InWorld. This was only used for command manager, instead, we can check if CurrentLanblock != null

Improve Player.SaveToDatabase() processes

Add PlayerManager.ProcessDeletedPlayer stub

Reduce Player.EnqueueLogout code

* More Player Logout, Save and Session Drop progress

* fix admin boot command

* More cleanup

* Player_Inventory GetPickupItem() should not return error when item not found. Changed to debug
2018-12-08 21:24:55 -06:00
Mag-nus
eeaf9725e4
PlayerManager (#1103)
* PlayerManager initial checkin

* OfflinePlayer initial checkin

* More progress

* Comment out Console.WriteLine debug messages

* Add property dictionaries to OfflinePlayer

* IPlayer initial checkin

* Add allegiance vars to IPlayer

* Couple comments

* More progress

* Add more to IPlayer

* line endings fix

* More progress. Compiles. Friends list works again.

* Friend status updates now work (again)

* PlayerManager save OfflinePlayers every 1hr

* Bye bye legacy AllPlayers

* using cleanup

* Allegience switch to PlayerManager progress

* More Allegiance progress

* More progress

* More allegiance progress

* IPlayer adds

* Migrate inversefriends to PlayerManager

* Switch WorldManager GetPlayerByGuid over to PlayerManager

* WorldManager Find(ObjectGuid characterGuid) removed. Use PlayerManager instead

* WorldManager FindByPlayerName(string name) removed. Use PlayerManager instead

* PlayerManager thread safety switched to ReaderWriterLockSlim

* More progress

* ServerStatus added TotalAccountsCreated, TotalCharactersCreated

* No more Player access/management stuff in WorldManager. It's all in PlayerManager now

* Player.IsOnline is no more.

* Friends AppearOnline fix

* Handle dead session better to switch player from online to offline

* Remove adding the + to names in ChatChannels. Name property should be changed to not include +

* serverstatus total accounts and characters on same line

* Allegience initial fix, still more bugs though

* PlayerManager minor cleanup

uint should be faster key than ObjectGuid

Changed the dictionaries to private. We don't want anyone outside of this class referencing them.

* Thread safety added to LScape.get_landcell
2018-12-02 13:41:16 -06:00
Mag-nus
502e716e8e
Landblock item saving + Much more (#1071)
* Landblock EnqueueBroadcast cleanup

Avoid double cast by using OfType

Change excludeList from IEnumerable to ICollection because it was being enumerated more than once.

* SerializedShard handle OperationCancledException

* SerializedShard break on the exceptions

* Landblock save progress

* Landblock merge fix

* Decayable -> Dynamic

* Improved ShutdownServer to include landblock unload and db queue wait

* Sleep during shutdown instead of using up all the CPU

* Shard GetDynamic was comparing against the wrong id... woops

* Fix shard biota caching

* Improve shutdown logging and actions

* cosmetic code order

* Fix crash when trying to add a bad wo to a landblock

* This fixes reloading dynamic objects

* Don't save item on pickup

* Don't save item on pickup from chest

* Don't save items on drop

* Set Home Position only for creatures (Used for navigation)

* Improve the landblock SaveDB code

* Don't save player corpse on death. Landblock will do that for us in bulk.

* Add the housing objects to statics that persist to the shard

* WorldObjectFactory dont overwrite location if object came from database

* Improved IsStaticThatShouldPersistToShard

* This should fix player dropped missiles

* Move PositionType into ACE.Entity.Enum.Properties

* Ephemeral support for Positions

* Decay code/saving works much better

* Filter out contained and wielded items from shard GetDynamicsByLandblock

* TimeToRot provision for -1 (No rot)

* Corpse decay is now controlled by landblock and uses the same decay code

* ShardDatabase: Fix add/remove biota bug

* WorldObject.Destroy now destroys contained and equipped items as well

* TryRemoveFromInventoryWithNetworking no longer removes the object from the db

* Player corpse items now remain when the corpse decays

* Cleaned up SetPropertiesForWorld
2018-10-23 15:52:09 -05:00
Mag-nus
118c890285 More profiling based improvements (#1067)
* RateMonitor created

* NetworkSession Update foreach change to help profiling

This just removes the lambda pattern for the foreach so profilers can monitor each line individually.

Functionality is unchanged.

* Reduce Landblock ctor async work to a single thread

This helps reduce ACE thread starvation

* NetworkSession cosmetic

* NetworkSession cosmetic

* NetworkSession currentBundles ConcurrentDictionary to Array

This significantly improves the performance of NetworkSession.

Arrays are faster than Dictionaries, and we manage concurrency to the elements via currentBundleLocks.

We're also able to get away with using an array because the number of elements is only 12.

Accessing the indexes of currentBundles should be atomic as it's an array of reference values, compiled as 64 bit.

* Add InParallel to database functions that do their underlying work in parallel

* DoSessionWork tick outbound messages in series, not in parallel.

* NetworkSession should not be interfacing with ActionChains

* Don't load landblock ctor resources in parallel

Save the threads in the pool for more important work

* LandblockManager removed check/recheck

This is legacy code from a pattern no longer used. It is no longer required.

* Cosmetic
2018-10-15 23:06:54 -04:00
gmriggs
39311e1230
Player housing - adding the ability to place and save items on floor/wall/ceiling hooks (#1012)
* Player housing - adding the ability to place and save items on floor/wall/ceiling hooks

* Updating to GetBiota

* Adding house storage
2018-09-13 18:00:15 -04:00
Mag-nus
09e1c68135
Migrate Character tables over to similar caching/threading model as Biota (#979)
* First batch of Character refactor

Characters are now cached with their dbContext, exactly like we do for Biotas. This greatly simplifies the way characters are pulled and saved, and is much more efficient.

Deleting and restoring characters have been migrated to the new SaveCharacter function. There is no need for separate functions to handle those specific tasks.

IsPlussed column added to Character. This removes the need to query the biota to see if we should display the + in front of the name at the character screen.

Character.LastLoginTimestamp, TotalLogins, CharacterOptions1, and CharacterOptions2 are now used. These property types were removed from the ACE.Entity.enum. (the 9000+ types)

Fixed a few places where ChangesDetected was being set insetad of CharacterChangesDetected. There is still more work to do to improve this pattern.

* Player_Client renamed to Player_Character

Plus some cleanup on the way CharacterOptions were get

* Remove duplicate appearance DID properties from WorldObject_Properties

* Removed the duplicate HairTexture DID properties

* Migrate HairTexture from biota property to Character property

* Forgot a CharacterChangesDetected

* Migrate Character specific functions to Player_Character

* Some more Biota wrappers added to BiotaExtensions

* CharacterPropertiesShortcutBar wrapped

* CharacterPropertiesSpellBar migrated to CharacterExtensions

* CharacterPropertiesTitleBook migrated to CharacterExtensions

* CharacterPropertiesFriendList migrated to CharacterExtensions

* drop AccountId from CharacterPropertiesFriendList
2018-08-30 07:11:25 -05:00
Mag-nus
71f1803088 ShardDbContext caching. 1 for every Biota via a ConditionalWeakTable (#964)
* ShardDbContext caching. 1 for every Biota via a ConditionalWeakTable

* Forgot to SetBiotaPopulatedCollections in SaveBiota
2018-08-22 18:31:44 -07:00
Mag-nus
12c9eea68a
Shard Biota Save & Threading Model Rework (#960)
* SaveBiota major changes

SaveBiota now only updates values in the database that have changed instead of updating every single value.

In addition. SaveBiota detects added and removed linked entities.

* Replace AddBiota(s) with SaveBiota(s)

* This improves the way a few places referenced the biota

* SaveBiota switched to a diff method. Still some work to do

* More notes + fixes

* SaveBiota move GetBiota to before EnterWriteLock

* Added a note about the lock performance

* More summary improvements for BiotaDatabaseLock

* Thread safety added to the SaveBiotas and AddBiotas functions

SavePlayer also switched to use the SaveBiotas bulk action instead of saving each biota individually.

* Biota.Clone() added

* BiotaExtensions cosmetic only

* DbUpdateException fixed

If there were multiple new records in a collection, the first one was attached but with the last new records values.

This would end up resulting in property records with duplicate types id's.

* ReoveBiota check if biota actually exists in db before removal.

* /databasequeueinfo added

* New From-Weenie Containers should not be searching the shard for inventory

* DeveloperDatabaseCommands removed RequiresWorld flag

* Improved DatabasePerfTest results.
2018-08-20 18:30:38 -05:00
Mag-nus
9622ab3f61
DatabasePerfTest developer command added (#957)
My test results:

Starting Database Performance Tests.
Biotas per test: 1000
This may take several minutes to complete...
1000 individual add   . Duration:  29.9 seconds. Successes: 1000, Failures:    0. Average:  30 ms
1000 individual save  . Duration:  23.9 seconds. Successes: 1000, Failures:    0. Average:  24 ms
1000 individual remove. Duration:  23.7 seconds. Successes: 1000, Failures:    0. Average:  24 ms
1000 bulk add         . Duration:   8.5 seconds. Successes:    1, Failures:    0. Average:   9 ms
1000 bulk save        . Duration:   6.2 seconds. Successes:    1, Failures:    0. Average:   6 ms
1000 bulk remove      . Duration:   7.0 seconds. Successes:    1, Failures:    0. Average:   7 ms
Database Performance Tests Completed

Next step is to modify the save to detect added/removed entities and only update changed records (not all).
2018-08-18 09:35:26 -05:00
Mag-nus
df8946b9da
Major Shard Performance Improvements (#941)
* Shard PopulatedCollectionFlags

This greatly improves GetBiota performance.

It does so by recording the biotas populated collections on save, and then on Get, only pulling those known populated collections back from the database.

* Note added about GetBiota improvements

* Shard Parallel loops added for GetPlayerBiotas

This improves performance signifcantly.

Previously, a full mule too 8s to load.
Now, it's uder 500ms.
2018-08-10 20:30:21 -05:00
Mag-nus
c61acf7a01
PropertyManager Database Cleanup (#940)
Previously, PropertyManager used SerializedShardDatabase to wrap it's database calls.

This didn't make much sense because SerializedShardDatabase was basically just a wrapper that serialized calls to ShardDatabase.

So, instead, we now have a ShardConfigDatabase class as well that is held by DatabaseManager. This holds the property/config specific funcitons for the shard.

In addition, there were a couple bugs fixed in PropertyManager where a function migt have been GetLong() when it should have been GetDouble(), etc...
2018-08-10 13:52:19 -05:00
Mag-nus
74b661050a
Various small cleanups (#939)
* Remove Parallel.ForEach from Fellowship

No need for parallel execution for these simple loops

* Cleanup Session/Player save call stack

* comment fix.

* Another comment added

* Config Properties cosmetic cleanup

This is in preparation for the properties/database refactor.
2018-08-10 12:21:06 -05:00
Mag-nus
c4f32f1484
Session class improvements (#937)
* Session.AccountCharacters renamed to Characters

* includedDeleted option added to Shard GetCharacters()

* change Shard GetCharacter includeDeleted parameter order

* Character pruning removed from GameMessageCharacterList

This class shouldn't be doing the pruning. It should be the caller.

This class should send the characters exaclty as they're passed. It's not good to have functions like this that are manipulating your data before sending it off when it's not obvious.

* Sorting characters by LastLoginTimestamp not needed

Client auto sorts first by isDeleted, then, by name.

* Logging off doesn't reload characters

No need to reload them from the database. The session already has all it's owned non-deleted characters.

We simply check the characters for deletion and remove them from the list if needed.

This reduces database overhead.

* using statement cleanups. Purely cosmetic

* CharacterHandler code reorder

I prefer top down.
Character create, enter world, log off, delete, restore

* AuthenticationHandler bug fix for characters that are marked deleted on initial login

* CharacterHandler Delete/Restore no longer reload entire character list

This improves DB efficiency

* Session code cleanup. Mostly just organization

* Remove IActor from Session and add InboundMessageQueue to WorldManager

* Improve WorldManager ActionQueue names

* Add back character sort on initial connect
2018-08-09 21:20:38 -05:00
Mag-nus
81fc08040e
Character refactor (#928)
This removes Character as the parent of a Biota, and instead, makes them side by side objects that are owned by Player.

Session no longer owns Character.

Session maintains a list of the Characters for the account.

Session holds a reference to the current Player being used.

Player holds a reference to Biota and Character objects.

What I said in discord:

We have the Player object (our god class).

To put a player in the world, it requires a biota. It doesn't require a character or session.
To manipulate the player, we need a session (but not a character).
To give the player a user interface, we need a character.

The character holds all the user progress of the particular biota it's associated with.

So, a session holds a link to the current player the session is managing.

Player holds a link to the biota and character that represent the player.

The biota represents the player from the worlds pov.
The character represents the player from the users pov.
2018-08-07 21:08:22 -05:00
gmriggs
1b504ff5f0 Adding landblock unloading system, and player corpses (#831)
* Adding landblock unloading system, and player corpses

* Adding dropped items to player corpse

* Adding landblock unloading system, and player corpses

* Adding dropped items to player corpse

* Adding permaload flag, and updating TimeToRot on landblock unload

* Adding corpse looting permissions

* Adding stack sizes

* Cleanup
2018-06-29 12:35:57 -07:00
gmriggs
719246da54 Adding Allegiance system (#825)
* Allegiance WIP

* Ranks, XP passup calcs

* Granting Allegiance XP passup to patrons

* Commenting debug messages

* Fixing Allegiance tab

* Adding Allegiance exceptions

* Adding break allegiance

* add ability to /tele players by name (#823)

* add ability to /tele players by name

* command parsing resiliency

* Give Request fix (#824)

* Give Request fix

Selected Wielded Objects as well as Inventory Objects. This fixes crash of gioving wielded objects to the town crier.

* Deleted unnecessary semicolons

* requested return for null

* UI panel refresh, apply XP earned by vassals on login

* Unequip and burden correction (#826)

* Add a configurable property storing database to resolve issue #753 (#820)

* Added the configuration database base script.

This should initialize the config database to hold different values that can be changed during the server operation.

* Added database models and connection.

This should begin to add in the new configuration database and its models so that it can be accessed from the server.

* Added boolean statistic access methods.

Modified the database file so that it was properly casting to a boolean and added the methods into the server configuration database API.

* Added the ability to access/modify integers in the config database.

* Added the ability to access/modify floating point variables in the configuration database

* Added the ability to access/modify string values in the configuration database

* Added the ServerConfigurationDatabase to the DatabaseManager.

* Added in the initial caching layer for configuration

* Added the ability to modify cached items.

* Changed from regular dictionaries to concurrent dictionaries.

* Added in the ability for the ConfigurationManager to self-update from the database.

* Added fallback parameters instead of forcing a default

* Added customizable vitae statistics.

This is the first big stat that can be modified. It is a float, so more floats should now work when they have support added.

* Updated the configuration manager to separate methods and ensure semantics are correct.

* Added command to fetch float value from server

* Add property for XP/Lum multipler.

* Welcome message/MOTD is now configurable from the database.

* Added string modification commands

* Database is no longer required for server configuration.

* Added in all modification/fetch commands and a resync command

* Renamed ConfigurationManager -> PropertyManager as this removes ambiguity

* Changed logging string to be more consistent

* Pass w/ StyleCop

* Added comments to the property manager

* Added the ability to disable caching fallback values.

This can be used for default settings or if a fetch with the default fallback should not cache (ie fetching xp_multipler before xp_multiplier has been fetched from the DB/the default value has been given, and therefore xp_multiplier is fetched as 0 and cached as 0). This functionality should be used for server commands.

* The admin commands now properly obey cacheFallback restrictions

* Added initial default property handling.

* Moved to using constant values as defaults.

* Switched to using a Dictionary for resolution of default properties

* Added warning when the server configuration database is not loaded.

* Corrected MOTD default string

* Renamed some of the database connection objects and changed float -> double and int -> long

* Fixed admin commands not being named correctly

* Fixed spelling error

* Config tables now lie in the shard database

* Added descriptions to properties across the board that can be analyzed through admin commands

* Removed property from PlayerXP file

* Removed vitae properties from EnchantmentManager

* Added null checks to make output nicer

* Added command to modify property descriptions

* Fixed string not being stored properly in the DB and crashing the server

* Wrapped the old ServerPropertyDatabase into SerializedShardDatabase

* Fixed ShardDbContext having a modified OnConfiguring method

* Allegiance WIP

* Ranks, XP passup calcs

* Granting Allegiance XP passup to patrons

* Commenting debug messages

* Fixing Allegiance tab

* Adding Allegiance exceptions

* Adding break allegiance

* UI panel refresh, apply XP earned by vassals on login
2018-06-22 17:33:06 -07:00
Evan Merlock
e406ef4853 Add a configurable property storing database to resolve issue #753 (#820)
* Added the configuration database base script.

This should initialize the config database to hold different values that can be changed during the server operation.

* Added database models and connection.

This should begin to add in the new configuration database and its models so that it can be accessed from the server.

* Added boolean statistic access methods.

Modified the database file so that it was properly casting to a boolean and added the methods into the server configuration database API.

* Added the ability to access/modify integers in the config database.

* Added the ability to access/modify floating point variables in the configuration database

* Added the ability to access/modify string values in the configuration database

* Added the ServerConfigurationDatabase to the DatabaseManager.

* Added in the initial caching layer for configuration

* Added the ability to modify cached items.

* Changed from regular dictionaries to concurrent dictionaries.

* Added in the ability for the ConfigurationManager to self-update from the database.

* Added fallback parameters instead of forcing a default

* Added customizable vitae statistics.

This is the first big stat that can be modified. It is a float, so more floats should now work when they have support added.

* Updated the configuration manager to separate methods and ensure semantics are correct.

* Added command to fetch float value from server

* Add property for XP/Lum multipler.

* Welcome message/MOTD is now configurable from the database.

* Added string modification commands

* Database is no longer required for server configuration.

* Added in all modification/fetch commands and a resync command

* Renamed ConfigurationManager -> PropertyManager as this removes ambiguity

* Changed logging string to be more consistent

* Pass w/ StyleCop

* Added comments to the property manager

* Added the ability to disable caching fallback values.

This can be used for default settings or if a fetch with the default fallback should not cache (ie fetching xp_multipler before xp_multiplier has been fetched from the DB/the default value has been given, and therefore xp_multiplier is fetched as 0 and cached as 0). This functionality should be used for server commands.

* The admin commands now properly obey cacheFallback restrictions

* Added initial default property handling.

* Moved to using constant values as defaults.

* Switched to using a Dictionary for resolution of default properties

* Added warning when the server configuration database is not loaded.

* Corrected MOTD default string

* Renamed some of the database connection objects and changed float -> double and int -> long

* Fixed admin commands not being named correctly

* Fixed spelling error

* Config tables now lie in the shard database

* Added descriptions to properties across the board that can be analyzed through admin commands

* Removed property from PlayerXP file

* Removed vitae properties from EnchantmentManager

* Added null checks to make output nicer

* Added command to modify property descriptions

* Fixed string not being stored properly in the DB and crashing the server

* Wrapped the old ServerPropertyDatabase into SerializedShardDatabase

* Fixed ShardDbContext having a modified OnConfiguring method
2018-06-20 21:58:17 -04:00
Ty Conner
53f00917a4
Database Rebase and Table Rename (#799)
* World DB Rekeyed

* Rebase World DB

* Rebase Shard DB

* Update PK in EmoteAction

* Shard DB Rekeyed. This change creates lots of exceptions currently.

* Revert to Shard/World DB Rebase

* Restore Id to each table

* Restore Id to Shard tables

* Update World DB pr location

* Missed this ObjectId > Id change

* Rename Tables

* Updating Changlog and Readme. This PR fixes #782 and fixes #783

* Updating Changelog again to note that you must drop and re-create Shard and World DB due to changes
2018-05-24 16:07:00 -04:00
Mag-nus
e3f4a0e929 Shard fix for unecessary unboxing. Should also slightly improve performance. 2018-04-19 09:09:49 -05:00
Mag-nus
8e0ee768f0 Give the Thread()'s actual names. This helps with debugging. 2018-03-22 09:00:54 -05:00
Mag-nus
1f0bf7469b This develops the db item management system. Objects now persist to the db properly.
Records (properties) are removed from the db as they're removed from a biota. This is because the context can't track removed entries after the context has been disposed.

Adding new records (properties) does not automatically save to the db. Instead, periodic saves, or saves at critical points, will cause the entire biota to be saved to the db which will update any existing records (properties) as well as add any new ones.
2018-03-15 23:17:36 -05:00
Mag-nus
e776fec587 Shard database GetBiota efficiency improvements 2018-03-10 08:56:00 -06:00
Mag-nus
6f15fb7c7c Container.TryAddToInventory progress 2018-03-09 10:57:12 -06:00
Mag-nus
e92eb5a2a1 Notes about adding a character to the db 2018-03-06 04:40:07 -05:00
Mag-nus
128d084886 Inventory/EquippedObjects model progress 2018-03-06 04:40:06 -05:00
Mag-nus
8e179facad ShardDatabase.GetInventory fixed for nestedItems *i think* 2018-03-06 04:40:06 -05:00
Mag-nus
fe34547e7e AceObject finally gone. Yay! 2018-03-06 04:40:05 -05:00
Mag-nus
c87b6b041e AceContractTracker removed 2018-03-06 04:40:04 -05:00
Ty Conner
44b9906cba Some Character Creation changes 2018-03-06 04:39:57 -05:00
Mag-nus
d5a25c9393 This has inventory partially working on login. Still needs work 2018-03-06 04:38:20 -05:00
Mag-nus
6d14a8b979 I *think* this will save the inventory on char create. Haven't checked DB to verify. 2018-03-06 04:38:19 -05:00
Mag-nus
836cbe7b16 Ability to add/save multiple biotas at once 2018-03-06 04:38:18 -05:00
Mag-nus
513970179f RemoveProperty now properly removes records from the db 2018-03-06 04:38:04 -05:00
Ty Conner
9775aaac4b Proper character list sorting, REMed WO changes as they cause exception on save currently 2018-03-06 04:38:00 -05:00
Mag-nus
8eebd6c934 forgetting spells now works 2018-03-06 04:37:51 -05:00