Jump to content

Local images not loading

Pending 1.6.0

Rebel25
Rebel25

Posted

Hi i placed a local image in the map oxide/data/buttons/images/Skills.png

it is an icon with size 512 x 512

But the plugin is not loading the image

{
        "Image Url": "",
        "Local Image (oxide/data/Buttons/images - eg: image.png)": "Skills.png",
        "Command": "skills",
        "Permission (Empty = No Permission Required)": "",
        "Background Color": "0.65 0.65 0.65 0.3",
        "Always Show": false,
        "Display Types (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Overlay"
        ],
        "Show Overlay Only In (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Disabled)": [],
        "Enable Hybrid Display Types": false,
        "Hybrid Contexts (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Looting)": [
          "Looting"
        ],
        "Hybrid Fallback Display Types When No Context Is Active (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Hud"
        ],
        "Alignment": {
          "Anchor Min": "0 1",
          "Anchor Max": "0 1",
          "Offset Min": "350 -710",
          "Offset Max": "380 -680"
        }
      }

 

 

I also tried it with an external link doesn´t load that either

the link refers to my webserver .. most of my rust servers images are placed there and they work fine for other plugins and custom items

so nothing wrong with the link... but that doesn´t seem to work either ...

 

{
        "Image Url": "https://rebel25.com/server/Skills.png",
        "Local Image (oxide/data/Buttons/images - eg: image.png)": "Skills.png",
        "Command": "skills",
        "Permission (Empty = No Permission Required)": "",
        "Background Color": "0.65 0.65 0.65 0.3",
        "Always Show": false,
        "Display Types (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Overlay"
        ],
        "Show Overlay Only In (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Disabled)": [],
        "Enable Hybrid Display Types": false,
        "Hybrid Contexts (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Looting)": [
          "Looting"
        ],
        "Hybrid Fallback Display Types When No Context Is Active (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Hud"
        ],
        "Alignment": {
          "Anchor Min": "0 1",
          "Anchor Max": "0 1",
          "Offset Min": "350 -710",
          "Offset Max": "380 -680"
        }
      }

 

it´s just the image loading that is not working ... it is showing the default rust icon and when i click on it the Skills plugin opens,, so that´s fine

Already restarted the server .. no difference

I have 2 other icons .. that are working fine --- also placed on my server .. thay work as it should be

but the third icon doesn´t won´t to show .. so why are the other 2 icons working and the third not ? how do I fix this ?

 

here is my full config for the 3 buttons .. info and kits are working, but skills is not showing the image:

{
  "Settings": {
    "Buttons": [
      {
        "Image Url": "https://rebel25.com/server/newinfo.png",
        "Local Image (oxide/data/Buttons/images - eg: image.png)": "",
        "Command": "info",
        "Permission (Empty = No Permission Required)": "",
        "Background Color": "0.65 0.65 0.65 0.3",
        "Always Show": false,
        "Display Types (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Overlay"
        ],
        "Show Overlay Only In (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Disabled)": [],
        "Enable Hybrid Display Types": false,
        "Hybrid Contexts (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Looting)": [
          "Looting"
        ],
        "Hybrid Fallback Display Types When No Context Is Active (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Hud"
        ],
        "Alignment": {
          "Anchor Min": "0 1",
          "Anchor Max": "0 1",
          "Offset Min": "390 -710",
          "Offset Max": "420 -680"
        }
      },
      {
        "Image Url": "https://rebel25.com/server/newkits.png",
        "Local Image (oxide/data/Buttons/images - eg: image.png)": "",
        "Command": "kit",
        "Permission (Empty = No Permission Required)": "",
        "Background Color": "0.65 0.65 0.65 0.3",
        "Always Show": false,
        "Display Types (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Overlay"
        ],
        "Show Overlay Only In (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Disabled)": [],
        "Enable Hybrid Display Types": false,
        "Hybrid Contexts (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Looting)": [
          "Looting"
        ],
        "Hybrid Fallback Display Types When No Context Is Active (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Hud"
        ],
        "Alignment": {
          "Anchor Min": "0 1",
          "Anchor Max": "0 1",
          "Offset Min": "390 -675",
          "Offset Max": "420 -645"
        }
      },
      {
        "Image Url": "https://rebel25.com/server/Skills.png",
        "Local Image (oxide/data/Buttons/images - eg: image.png)": "Skills.png",
        "Command": "skills",
        "Permission (Empty = No Permission Required)": "",
        "Background Color": "0.65 0.65 0.65 0.3",
        "Always Show": false,
        "Display Types (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Overlay"
        ],
        "Show Overlay Only In (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Disabled)": [],
        "Enable Hybrid Display Types": false,
        "Hybrid Contexts (Looting/Vending/NpcConversation/Mounted/MLRS - Empty = Looting)": [
          "Looting"
        ],
        "Hybrid Fallback Display Types When No Context Is Active (Hud/Overlay/Under/Inventory/TechTree/Crafting/Contacts/Clans/Map)": [
          "Hud"
        ],
        "Alignment": {
          "Anchor Min": "0 1",
          "Anchor Max": "0 1",
          "Offset Min": "350 -710",
          "Offset Max": "380 -680"
        }
      }
    ],
    "Open By Default": true
  }
}

 

Skills.png is indeed a png image and the word Skills is written correctly ... sizes of all 3 icons are the same. 

Rebel25

Posted

forgot to send a screenshot

 

RustClient_zXOYFMI6v8.png

dFxPhoeniX

Posted (edited)

I checked it and the plugin itself looks fine.

The problem is with the image path.

This link:

https://rebel25.com/server/Skills.png

does not actually open an image. It opens your website, so Rust cannot load it as an icon.

Also make sure the local folder is exactly:

oxide/data/Buttons/images/Skills.png

with a capital B in Buttons.

On Linux, Buttons and buttons are not the same folder.

So try this:

1. Put Skills.png in oxide/data/Buttons/images/

2. Use "Skills.png" in the local image field

3. Leave the image URL empty for testRelod

4. Reload the Buttons plugin

If it still doesn't work after that, send me the exact file path from the server and any console message you get when reloading the plugin.

Edited by dFxPhoeniX
Rebel25

Posted

ah ..ok sorry ,, it´s working now .. don´t know why the url wasn´t working .. I uploaded it again to my weberver and now it works .. maybe something went wrong during the first upload 

no idea .. but anyway .. it works now ..

Thank you for the rspond .. I guess I should have checked the link first 🙂

 

About Us

Codefling is the largest marketplace for plugins, maps, tools, and more, making it easy for customers to discover new content and for creators to monetize their work.

Downloads
3.1m
Total downloads
Customers
12.1k
Customers served
Files Sold
172.2k
Total sales
Payments
3.7m
Processed total
×
×
  • 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.