You'd need to remove the // Reference and add the using statement for Oxide.Core.MySql.
Custom extension not loading after update
Discussion in 'Rust Development' started by Kolyma, Oct 21, 2017.
-
Wulf Community Admin
-
Which would also require adding the Oxide.MySql.dll to the existing project's references. Wasn't aware that the intention was to move away from referencing the dll the old way at the top. Still failing to compile both on start and on reload.
Error while compiling: AutoDoors.cs(19,37): error CS0234: The type or namespace name `MySql' does not exist in the namespace `Oxide.Core'. Are you missing an assembly reference?
Has retrieving the MySql library changed too? -
Wulf Community Admin
-
Using the most recent release from 13 hours ago.
-
Wulf Community Admin
-
Loading Oxide Core v2.0.3601...
Same issue -
Wulf Community Admin
-
Code:
using System; using System.Collections.Generic; using Oxide.Core; //Access to Interface class using Oxide.Core.MySql; //Access to MySql Library using Oxide.Core.Database; //Access to Connection class
-
Wulf Community Admin
-
Wulf Community Admin
I'll adjust the regex for stuff like that. -
But... but... how will we comment our code
[DOUBLEPOST=1508593703][/DOUBLEPOST]Compiling without issues now, thanks a bunch. -
Wulf Community Admin
-
So that AppVeyor, how long before you release an update is it generally available? I wouldn't mind running a test or two pre-release to help find these pesky issues before they become a bigger problem.
-
Wulf Community Admin
-
Ahh understood. I'll check in on Thursdays and see if anything is up.
-
This line, which was changed after 2.0.3591 is the first (and only) thing that causes my problem when I use OxideMod version 2.0.3596
Code:Extensions/Oxide.CSharp/Compilation.cs
Code:var result = Regex.Replace(match.Groups[1].Value, @"Oxide\.[\w]+\.([\w]+)", "Oxide.$1");
-
Wulf Community Admin
-
Same problem with original topic of this thread. At least I kind of know where to start looking. Something in the implementation of my extension is causing it to not qualify as a reference because of that line above
Code:Error while compiling: MyExtUniversal.cs(20,17): error CS0246: The type or names pace name `MyExt' could not be found. Are you missing an assembly reference?
-
Wulf Community Admin
Code:// Include implicit references detected from using statements in script match = Regex.Match(line, @"^\s*using\s+([\w]+\.(?:Core|Ext|Game)\.(?:[^\.]+))[^;]*;.*$", RegexOptions.IgnoreCase); if (match.Success) { var result = match.Groups[1].Value; if (result.StartsWith("Oxide.")) AddReference(plugin, Regex.Replace(result, @"Oxide\.[\w]+\.([\w]+)", "Oxide.$1")); else AddReference(plugin, result); continue; }
So, if your extension doesn't have an X.X.X namespace and assembly DLL, then that's likely the cause. I could probably loosen that up a bit as I know there are some without X.X.X.