UniversalUI for Rust

This is a fully Customizable UI for Info and Buttons!

Total Downloads: 1,074 - First Release: Nov 23, 2016 - Last Update: May 13, 2017

5/5, 22 likes
  1. Absolut
    Required Dependencies:
    http://oxidemod.org/plugins/imagelibrary.2193/
    Optional Dependencies:
    http://oxidemod.org/plugins/kits.668/
    Configuration File:
    Yes
    If you want to donate to my work feel free: Joseph Weems Geld mit PayPal.Me senden


    THIS PLUGIN REQUIRES: ImageLibrary for Rust | Oxide to work...


    Universal UI was designed to be a solution for server admins that want to give players on the server a more simplified method for explaining how various plugins work as well as combining the functionality.


    Imagine opening a UI element that has an unlimited number of tabs (sections), pages within each section, and buttons.


    This plugin has (2) parts. (1) The Main Button Bar located on the right of the screen. This bar can be blank or hold up to 20 buttons. (2) The information pane which is fully customizable.


    Fully customizable means... you can set a picture for every button and page. You can set an unlimited number of Sections, pages per section, and buttons per page.


    You might design a Section as ZoneManager Commands and make it require (admin - which is permissions "UniversalUI.admin" or connection of OwnerID (Auth2). In this section you might have a page with buttons for creating and customizing zones, or for information. Really the sky is the limit.


    Everything is configured through the config file which means you should regularly save a copy of this "just in case".


    The config is NOT simple, but with practice you can figure it out. ALWAYS use a json validator...


    Somethings to note...


    If a button has a command that is "NONE" or ""; it will be invisible (I.E. disabled).


    If a button, page, or section is set as admin = true, it will only be visible by admins or users with the "UniversalUI.admin" permission.


    After initial load, all the admin has to do is modify the config file and reload for the changes to take effect. Images are reloaded on EVERY reload/load.


    I have introduced the ability for an admin or user with the admin permission to Add/Remove Sections and Pages from within the game. This process is very simple and self-explanatory. The newly created page/section will need to be configured in the config just like pages/sections added manually.


    Page Types:

    The major change in adding Pages from within the game is you are prompted for what type of page you want it to be. There are 4 types of pages.


    Text: Is a page optimized to show one big text message.

    Buttons: Is optimized for buttons and will hold 70 buttons!

    Kits: Is a custom kits template that will allow you to add kits to the page, which can be redeemed by players (try it before asking questions). Kits are added from within the game or by adding the name of the kit to the config file… (do it from within game).

    You can also change the PageType via config by changing the type value to one of the following:

    0 - standard;
    1 - text;
    2 - buttons;
    3 - kits;

    NOTE: TO MAKE KITS WORK YOU NEED TO MODIFY THE KITS PLUGIN CODE MANUALLY... ADD THESE LINES: I'd recommend just putting them near the other HookMethods

    Code (C#):
    [HookMethod("KitCooldown")]
            public double KitCooldown(string kitname) => storedData.Kits[kitname].cooldown;

            [HookMethod("KitDescription")]
            public string KitDescription(string kitname) => storedData.Kits[kitname].description;

            [HookMethod("KitMax")]
            public int KitMax(string kitname) => storedData.Kits[kitname].max;

            [HookMethod("KitImage")]
            public string KitImage(string kitname) => storedData.Kits[kitname].image;
     
    Standard: Traditional layout with text and buttons.



    Delayed Commands:

    A delayed command is a command that is designed to allow the player to provide the final input. For example, you could make a command that is /env time ... on button press it will ask the player to provide the parameter. If they type 10 it will execute /env time 10. This logic works for console and chat commands. To enable a delayed command simply add delay in front of the button command in the config. Here are two examples:

    "command": "delay chat.say /zone_edit"

    "command": "delay env.time"



    PERMISSIONS:

    I have added custom permissions per button and per section. On load the plugin will check the config for permissions and register each that doesn't exist. For example, for a section you might make a permissions called "Section1". On reload the plugin will register UniversalUI.Section1 as a permissions. This section is now only accessible if the player has that permission or is an admin.


    AutoClose On Execution:

    Buttons now have a true/false option to auto-close on command execution. This simply closes the ui for you after you press a button. This works with all command types including chat, console, and delayed.


    Button Command Examples:

    1. To make a button with a chat command simply put: "command": "chat.say hi", à Will say hi

    2. To make a button with a delayed chat command simply put: "command": "delay chat.say hi", à Will wait for the user to input extra “stuff” then will say hi “stuff”

    3. To make a button with a console command simply put: "command": "hi", à Will print hi in console.

    4. To make a button with a delayed console command simply put: "command": "delay hi", à Will wait for the user to input extra “stuff” then will print hi “stuff” in console

    CONFIG "OPTIONS":

    MenuKeyBinding --- Sets Keyboard Binding for UI.
    UseInfoPanel --- Enables/Disables InfoPanel
    UseButtonPanel --- Enables/Disables ButtonPanel
    InfoInterval --- Sets in minutes Info for Chat Interval
    ForceOpenOnJoin --- Opens UI on Player Join.




    NEW VIDEO COMING SOON….

    Images

    1. UniversalUIImage1.PNG
    2. UniversalUIImage2.PNG
    3. ButtonPageInGame.PNG
    4. KitPageInGame.PNG
    5. NewAdminView.PNG
    6. TextPageInGame.PNG