1. Code:
    using System.IO;
    void Loaded()
    {
        File.Delete("test.cs");
    }
    [Oxide] 19:52 [Debug] at Oxide.Plugins.NoFallDmg.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.CSharpPlugin.InvokeMethod (System.Reflection.MethodInfo method, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
    at Oxide.Plugins.CSharpPlugin.HandleAddedToManager (Oxide.Core.Plugins.PluginManager manager) [0x00000] in <filename unknown>:0

    is this error;How can to working it?
     
  2. Wulf

    Wulf Community Admin

    You can't use System.IO for security reasons. Plugins are sandboxed to prevent exactly what you are trying. Why do you need to delete a file?
     
  3. i build a plugin "A" then upload to website then i wanna build a Updata Plugin "B",Used for auto update the Plugin "A".
    so,i need use Delete() and Write()
     
  4. Wulf

    Wulf Community Admin

    You'd need to write an extension or wait for an official extension from Oxide to handle the updating. Plugins are sandboxed, extensions aren't. Extensions would mainly be for your private use though, as most hosts will not accept unofficial ones.
     
  5. how can write an extension
     
  6. Wulf

    Wulf Community Admin