Advertisement
Guest User

PopUp API Schema

a guest
Mar 28th, 2023
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.28 KB | None | 0 0
  1. bool AddNewPopUpSchema(string pluginName, JObject schema)
  2. #Allows you to call plugin to create new pop-up preset for your plugin. EXAMPLE USAGE:
  3. JObject popUpConfig = new JObject()
  4. {
  5.     { "key", "Market" }, #<- Config Key value.
  6.     { "anchor", "0.5 1" },
  7.     { "name", "Legacy" },
  8.     { "parent", "Hud.Menu" },
  9.     { "background_enabled", true },
  10.     { "background_color", "0.145 0.135 0.12 1" },
  11.     { "background_fadeIn", 0.5f },
  12.     { "background_fadeOut", 0.5f },
  13.     { "background_offsetMax", "180 0" },
  14.     { "background_offsetMin", "-180 -65" },
  15.     { "background_smooth", false },
  16.     { "background_url", "" },
  17.     { "background_additionalObjectCount", 1 }, #<- This is value how many details is in this schema.
  18.     { "background_detail_0_color", "0.185 0.175 0.16 1" },
  19.     { "background_detail_0_offsetMax", "356 65" },
  20.     { "background_detail_0_offsetMin", "4 4" },
  21.     { "background_detail_0_smooth", false },
  22.     { "background_detail_0_url", "" },
  23.     { "text_anchor", "MiddleCenter" },
  24.     { "text_color", "0.91 0.87 0.83 1" },
  25.     { "text_fadeIn", 0.5f },
  26.     { "text_fadeOut", 0.5f },
  27.     { "text_font", "RobotoCondensed-Bold.ttf" },
  28.     { "text_offsetMax", "180 0" },
  29.     { "text_offsetMin", "-180 -65" },
  30.     { "text_outlineColor", "0 0 0 0" },
  31.     { "text_outlineSize", "0 0" }
  32. };
  33. PopUpAPI.Call("AddNewPopUpSchema", Name, popUpConfig);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement