6 Months Ago
PhysicsWorld.CollisionRules Refactor - Project Settings Small Network Files Support (#1604) * Add PhysicsWorld.CollisionRules getter. Delete ServerConfig. Update collision rules json on world if hash changes before physics step. Project Settings (.config) are networked via Small Network Files - can react to changes * Do GetHashCode this way * Initialize CollisionRules * Handle small network files from different file systems this way? * Fix * Fix documentation * Reset config files * Kind of genericize SmallNetworkFiles - push / add / remove files from it externally - mount its MemoryFileSystem externally as well to desired file system * Fix - but obviously it can't be done this way it's absolutely awful * Add all files from network when mounting on client side * Method name update * Remove some duplication * Cleanup * Fix inverted condition * Unnecessary arg * ToHashCode * ReadWithFallback will return new T() if package is null too * Store CollisionRules from Project Settings in ProjectSettings static class - update it when project settings change. Physics worlds using this reference should update automatically * Call ProjectSettings.Reset in ResetEnvironment * Clean up * Swap these