Garry's Mod

Garry's Mod

1,302 hodnocení
Material URL Tool (Beta)
4
3
3
10
5
4
2
2
3
3
3
3
2
2
   
Ocenit
Přidat do oblíbených
Oblíbeno
Odebrat z oblíbených
Content Type: Addon
Addon Type: Tool
Addon Tags: Build, Fun
Velikost souboru
Přidáno
Aktualizováno
65.159 KB
28. čvc. 2021 v 4.00
5. zář. 2021 v 3.00
Poznámky ke změnám (17) – zobrazit

Klikněte na „Odebírat“ pro stažení položky
Material URL Tool (Beta)

Popis
Material URL is a tool that allows you to use images from the internet as materials! SubMaterial feature!
v0.8.3
Please be aware that the development of this addon is currently slowed/stopped because I'm studying.

If you enjoy the addon, consider supporting it by leaving a like and sharing it with your friends, and please let me know your thoughts in the comments!
You can use this tool whether it's for memeing with your friends or simply for building!

This addon is still a Beta, so there is room for improvement and there are maybe bugs. I'll gladly appreciate any feedback!

How to use it?
How to copy an image's URL: https://i.imgur.com/yUP2g7C.png
  1. Subscribe to the addon / Make sure the addon is in your server's collection
  2. Make sure it's enabled then start a game / Start your server (then connect to it)
  3. Go to the "Render" section of the tool menu and select "Material URL"
  4. Enter a URL leading to an image in the URL field, the URL must lead to a PNG/JPEG file (e.g. https://i.imgur.com/C5ilAHq.png)
  5. (Enter a name in the Material name field)
  6. Press the button named "Upload to the server"
  7. Wait for the material to upload, then select it in the list below
  8. Click on an entity with the tool to apply your material

In order to access the SubMaterial mode, select the tool and press E and R at once. The display on the toolgun should change to SubMaterial mode. You'll just have to use your scrollwheel to switch submaterials while looking at a prop.

When your material is uploaded, everyone can see it in the list and use it.
For practical reasons, materials will be named '!maturl_[given name]_[SteamID64 of the uploader]' (in the console).

By default, the URL whitelist[pastebin.com] is on. If you want to turn it off execute this command in the game host's/server's console: "sv_materialurl_whitelist 0"

Please keep in mind that all the materials uploaded on a server will be deleted when it shuts down/changes level. Ditto for single-player mode.

Features
This addon allows you to:
  • Check if a given URL leads to a valid material
  • Upload custom materials with a direct URL to a PNG/JPEG file and a custom name and material parameters
  • Apply custom materials/submaterials on entities
  • Delete your own uploaded materials from the list (admins can delete anyone's materials)
  • Copy the materials' URL from the list
  • Report materials to admins
  • Add materials you like to a favorite list
  • Duplicate and save entities that have custom materials

When pasting a duplication that contains custom materials, all the materials will be uploaded at once and the player's cooldown will be set to the server's multiplied by the number of materials the dupe uploaded.

Client Convars
  • cl_materialurl_enabled (def. 1): Enables/disables Material URL clientside
  • cl_materialurl_keepfiles (def. 0): This allows you to keep the downloaded materials upon disconnection (they won't stay uploaded, it's just the images that are kept, they're located in the garrysmod/data/materialurl_materials/ folder)
  • cl_materialurl_preview (def. 1): Enables/disables previews in the material list
  • cl_materialurl_showmine (def. 0): Only show the materials that you uploaded in the list

Server Convars
  • sv_materialurl_adminonly (def. 0): Prevents normal players from using Material URL
  • sv_materialurl_deletedisconnected (def. 1): Enables/disables the automatic deletion of disconnect players' materials
  • sv_materialurl_whitelist (def. 1): Enables/disables the URL whitelist[pastebin.com]
  • sv_materialurl_reportingenabled (def. 0): Enables/disables the reporting feature
  • sv_materialurl_limitedsize (def. 0): Enables/disables the material size limit
  • sv_materialurl_filesizelimit (def. 1000): Sets the material size limit in kilobytes
  • sv_materialurl_limitedmaterials (def. 1): Enables/disables the material limit
  • sv_materialurl_materiallimit (def. 5): Sets the material limit (each player has their own count)
  • sv_materialurl_cooldown (def. 10): Sets the cooldown in seconds between each time a player wants to upload a material

Current problems
Discord image links must not start with 'cdn.discordapp.com/attachments'. They have to start with 'media.discordapp.net/attachments' to work.

Animated pictures aren't supported. I might not add support for this, as it might be hard for people to actually upload functional animated pictures.

Please report bugs/problems in the appropriate discussion.

Future updates features
These are the features I intend to implement in future updates (suggest here):
  • Add PermaProps support
  • Add E2 support
  • Add a way to restrict a player from using Material URL (just ban 'em)
  • Quit the Beta (v1.0)

Last v0.x update changelog (Sep. 5th)
v0.8
- Added a SubMaterial feature with duplication support, with its own display on the toolgun
- Added a button to reset the material parameters in the menu

v0.8.1
- Fixed Lua errors when looking at map entities
- Fixed the toogun display not refreshing correctly in singleplayer
- Disabled the size limit by default and changed the default maximum file size to 1000 kb (see Server Convars)

v0.8.2
- Added Material X and Y offset parameters (texture translation)

v0.8.3
- Fixed a bug with the whitelist
- Added a website to the whitelist

Disclaimer
This addon allows players to upload materials from any link when the URL whitelist[pastebin.com] is off, people might use it for nefarious purposes.
Please refrain from complaining about people misbehaving with this addon on your server. If you believe something is missing, post a suggestion.
I will not be held responsible for any cases of illicit/illegal/dangerous content uploaded on your server. Use at your own risk! I highly recommend you keep the whitelist on if you're a server owner.

Please do not reupload/edit/improve this addon without my permission.

Thanks for your support!
Populární diskuze Zobrazit vše (5)
67
27. čvn. v 18.50
PŘILEPENO: Suggestions
Some1else{}
66
11. čvc. v 16.47
PŘILEPENO: Bug Reporting
Some1else{}
4
5. zář. 2021 v 16.23
I currently make a page on imgur.com for WAC Aircraft skins.
wolfy.hunter9111
Počet komentářů: 341
herron před 19 hodinami 
you've been studying for a while, everything alright?
-(TTP)- Demo 23. kvě. v 19.44 
Update: Turns out I had the addon disabled for whatever reason.
-(TTP)- Demo 23. kvě. v 19.19 
I can't find the addon and I downloaded it.
Zsombor99 23. kvě. v 5.33 
@蓝末影 This tool only provides materials to be used via other tools/addons, nothing else.
蓝末影 22. kvě. v 8.58 
So can this module work for the player's own model?🤔Can I choose a player model?In fact, I still very much hope that this can be done.😋
Bloopster1234 6. kvě. v 20.40 
It does what is advertised, but the lack of support for transparent textures kinda ruins it for me. Hopefully that will be added in a future update.
Raspberry 22. dub. v 20.41 
how to disable texture loops?
samboo 12. dub. v 13.36 
[Material URL Tool (Beta)] bad argument #4 to CreateConVar (string expected, got number)
1. unknown - lua/weapons/gmod_tool/stools/materialurl.lua:65
2. include - [C]:-1
3. unknown - gamemodes/sandbox/entities/weapons/gmod_tool/stool.lua:159
4. include - [C]:-1
5. unknown - gamemodes/sandbox/entities/weapons/gmod_tool/shared.lua:387
6. include - [C]:-1
7. unknown - gamemodes/sandbox/entities/weapons/gmod_tool/init.lua:10
cassaroll83 4. dub. v 21.23 
url not whitelisted
acampbell830 29. bře. v 13.37 
i've got an idea :steammocking: