Greetings,
I am using for a custom plugin now ImageLibrary's "GetImageURL" Hook.
Passing the shortname + skinid with the call, and as i see , getting back the right url.
The url is in the Datafile of imagelibrary aswell.
But on try to open the UI, it throws me of the Server, but not every time....
I encountered that on situations like, using some not approved skinids or custom made workshop skins ( which work if they are manually applied)
And now i get the error on normal items with skinId "0" aswell.
For the UI im using:
Code:ui.Add(new Dictionary<string, object> { {"name", name}, {"parent", parent}, {"components", new List<object> { new Dictionary<string, string> { {"type", "UnityEngine.UI.RawImage"}, {"sprite", "assets/content/textures/generic/fulltransparent.tga"}, {"url", url}, {"color", color.ToString()}, {"imagetype", "Tiled"} }, new Dictionary<string, string> { {"type", "RectTransform"}, {"anchormin", $"{left.ToString().Replace(",", ".")} {((1 - top) - height).ToString().Replace(",", ".")}"}, {"anchormax", $"{(left + width).ToString().Replace(",", ".")} {(1 - top).ToString().Replace(",", ".")}"} } } } });
And in my Clientconsole i get the error " downloading image: http://...... ( Not an Image)
Which.... it IS its a .png the url even ends in ...png
RPC Error in AddUI
Discussion in 'Rust Development' started by Crushed, May 5, 2018.
-
Calytic Community Admin Community Mod
Sounds to me like there may be an issue with the Steam CDN or transport issue during the request.
I would recommend serving the images from your server by loading them into ImageLibrary and using the "PNG" property of RawImage as opposed to a remote url.
