Jump to content

ImageLibrary Issues

Closed 1.1.3

[Part 1]Error while compiling: template.cs(103,35): error CS1525: Unexpected symbol `https'

Broken lines

void Loaded() {
			ImageLibrary?.Call("AddImage",""https://i.imgur.com/Vklka0y.jpg"",Image_1138);
};

 

Edited by ArtiIOMI

Share this comment


Link to comment

[Part 2]Error while compiling: template.cs(104,2): error CS1519: Unexpected symbol `;' in class, struct, or interface member declaration

Edited by ArtiIOMI

Share this comment


Link to comment

[Part 3]Error while compiling: template.cs(103,68): error CS0103: The name `Image_1138' does not exist in the current context

Edited by ArtiIOMI

Share this comment


Link to comment

Solution
Go to UI/Assets/Editor and open UGUIMenu.cs
Find in file

        if (ImageLibaryExports.Count > 0)
        {
            int index = 0;
            fullexport.Append($"\n\n[PluginReference] private Plugin ImageLibrary;\nvoid Loaded() {"{"}");
            foreach (var name in ImageLibaryExports.Keys)
            {
                fullexport.Append($"\n\t\t\tImageLibrary?.Call(\"AddImage\",\"{ImageLibaryExports.Values.ElementAt(index)}\",{name});");
                index++;
            }
            fullexport.Append($"\n{"};"}");
        }

and change to 

        if (ImageLibaryExports.Count > 0)
        {
            int index = 0;
            fullexport.Append($"\n\n[PluginReference] private Plugin ImageLibrary;\nvoid Loaded() {"{"}");
            foreach (var name in ImageLibaryExports.Keys)
            {
                fullexport.Append($"\n\tImageLibrary?.Call(\"AddImage\",{ImageLibaryExports.Values.ElementAt(index)},\"{name}\");");
                index++;
            }
            fullexport.Append($"\n{"}"}");
        }

Save file. Done.

@Billy Joe To close. Thanks.

  • Love 1

Share this comment


Link to comment
437.9k

Downloads

Total number of downloads.

2.3k

Customers

Total customers served.

32.3k

Files Sold

Total number of files sold.

526.2k

Payments Processed

Total payments processed.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.