I want to create a new directory in the oxide folder of the server then within create a file for each player where all data is stored for them. The file name being the players id.
This is what i have so far
Code:namespace Oxide.Plugins { [Info("CoffeesCup", "Coffee", 0.1)] [Description("")] class CoffeesCup : RustPlugin { #region Universal Hooks void Loaded() { Puts("... Loaded"); } #endregion #region Player Hooks void OnPlayerConnected(Network.Message packet, BasePlayer player) { string targetID = player.userID; storeData = Interface.Oxide.DataFileSystem.ReadObject<StoredData>(targetID); } #endregion #region Stored Data class StoredData { public Dictionary<ulong, double> dataPlayerID = new Dictionary<ulong, double>(); } StoredData storeData; #endregion } }
Create personal player file
Discussion in 'Rust Development' started by Eis3nheim, Feb 9, 2017.